dataTable在meteor

时间:2016-05-28 17:31:25

标签: jquery html meteor datatable

我正在使用dataTables来设计和分页动态加载数据的表...我在javascript中创建了tr和td

html = '<tr>'+
        '<td>'+req.product+'</td>'+
        '<td>'+createdAt+'</td>'+
        '<td>'+req.quantity+'</td>'+
        '<td>'+companyName+'</td>'+
        '<td>'+totQuot+'</td>'+
        '<td>'+totAppQuot+'</td>'+
        '<td><a class="imQuotCount" id="'+req._id+'_totQuot" href="">'+totImQuot+'</a></td>'+
        '<td><a class="imQuotCount" id="'+req._id+'_appQuot" href="">'+appImQuotCount+'</a></td>'+
        '<td><a class="imQuotCount" id="'+req._id+'_unappQuot" href="">'+unappImQuotCount+'</a></td>'+
        '<td><a class="imQuotCount" id="'+req._id+'_rejQuot" href="">'+rejImQuotCount+'</a></td>'+
    '</tr>'

1 个答案:

答案 0 :(得分:-1)

所以我猜这个问题是来自数据库的数据becoz,我很幸运,我的猜测是正确的,我所做的只是在lib而不是直接写Meteor.subscribe我返回了所有的Meteor。订阅为数组...并且它有效