angular——話題精選(動態更換顯示一條)

 

<!-------------------- 話題精選 ----------------------->
        <section class="white_bg topics ">
            <header class="fix_container ">
                <div class="fix_top_left" id="topics_mark"><i class="icon-topic"></i></div>
                <ul id="topic_title" >
                    <li ng-repeat="topic in data.topics" class="font_16_14 black_title one_line_text" ng-click="action.toPage('tab.home-recommend-topic-detail')">
                        #{{topic}}#
                    </li>
                </ul>
                <button class="btn blue_text_btn fix_top_right" ng-click="">更多</button>
            </header>
        </section>
// 話題更新
        $scope.data.topics = [
            "爲何政府忽然不讓你買房了啊啊啊啊啊",
            "A股趨勢何去何從",
            "誰纔是中國股市最大贏家"
        ];

        function NewsTickerAutoPlay() {
            $("#topic_title li:first-child").remove().appendTo("#topic_title");
        }

        setInterval(function () {
            NewsTickerAutoPlay()
        }, 5000);
相關文章
相關標籤/搜索