master
夜笙歌 2 years ago
parent 5f99eb09b2
commit 8244ed5da6

@ -217,24 +217,6 @@ let dynamicTable = resource => {
}
}
//奇偶校验 --> 处理最后一行是奇数的问题
let oddORevenCheck = $(`${ele}>.table>.tbody>.tr`).length % 2 == 0 ? 'even' : 'odd';
//滚动动画
var animation = () => setInterval(function() {
$(ele + '>.table>.tbody>.tr:eq(0)').slideToggle(100, function() {
switch (oddORevenCheck) {
case 'even':
$(this).clone().css(trEvenCSS).appendTo(ele + '>.table>.tbody');
oddORevenCheck = 'odd';
break;
case 'odd':
$(this).clone().css(trOddCSS).appendTo(ele + '>.table>.tbody');
oddORevenCheck = 'even';
break;
}
$(this).remove();
});
}, timeout);
// 组件销毁钩子
$(`${ele}`).bind('DOMNodeRemoved', (e) => {

Loading…
Cancel
Save