<div id="noticelist" class="weui-flex__item" style="height: 35px;overflow: hidden">
<ul id="noticemessages" >
</ul>
</div>
for(var i=0;i<NoticeMessage.length;i++){
$("#noticemessages").append(""+
"<li class='notice' style='display: flex;margin-left: 10px;margin-right: 10px;height: 35px;line-height: 35px'>"+
"<div style='color: orange;width: 15%'><h4 >通知</h4></div> " +
"<div style='width: 65%;overflow: hidden; text-overflow:ellipsis;white-space:nowrap' class='notice-title-"+i+"' ></div>"+
"<div style='width: 30%' class='notice-time-"+i+" weui-cell__ft' '></div>" +
"</li> ");
$(".notice-title-"+i+"").html(NoticeMessage[i].title);
$(".notice-time-"+i+"").html(convertToTime_MinuteNoYear(NoticeMessage[i].timeMs));
}
$(function() {
setInterval('timer("#noticelist")', 4000);
});
function timer(opj) {
$(opj).find('ul').animate({
marginTop: "-35px"
}, 1000, function() {
$(this).css({
marginTop: "0px"
}).find("li:first").appendTo(this);
})
}