因此,我得到了一個女巫的智能表,我重新加載了整個數據集(我需要一個圖表)。 但我不希望所有的數據一次渲染(得到太多)。所以在文檔中有一些叫做"Client Side Pagination"的東西,但是由於某些原因,這似乎不起作用。 objectDataArr[0]
包含整個數據集客戶端分頁不能在智能表中工作
我嘲笑起來就是:
<div class="container">
<div class="row">
<div class="col-md-4">
<h1><strong>Preview Data: {{objectTranslations[objectData.LangKey]}}</strong></h1>
</div>
<div class="col-md-8">
</div>
</div>
<div class="row">
<table st-table="objectDataArr[0]" class="table table-striped">
<thead>
<tr>
<th ng-repeat="col in objectData.Tables[0].Columns" st-sort="col.Code" ng-class="{'dd-vh-2':col.Length<=25 , 'dd-vh-5':col.Length>25 && col.Length<=50, 'dd-vh-10':col.Length>50 && col.Length<=100, 'dd-vh-15':col.Length>100 && col.Length<=150, 'dd-vh-20':col.Length>150 && col.Length<=250}">{{objectTranslations[col.LangKey]}}</th>
</tr>
<tr>
<th ng-repeat="col in objectData.Tables[0].Columns" ng-class="{'dd-vh-2':col.Length<=25 , 'dd-vh-5':col.Length>25 && col.Length<=50, 'dd-vh-10':col.Length>50 && col.Length<=100, 'dd-vh-15':col.Length>100 && col.Length<=150, 'dd-vh-20':col.Length>150 && col.Length<=250}">
<input placeholder="Search ..." st-search="col.Code" />
</th>
</tr>
</thead>
<tbody>
<tr ng-repeat="row in objectDataArr[0]">
<td ng-repeat="col in objectData.Tables[0].Columns" ng-class="{'dd-selected': row.showRowButtons == true, 'dd-vh-2':col.Length<=25 , 'dd-vh-5':col.Length>25 && col.Length<=50, 'dd-vh-10':col.Length>50 && col.Length<=100, 'dd-vh-15':col.Length>100 && col.Length<=150, 'dd-vh-20':col.Length>150 && col.Length<=250}">
<span class="dd-cell">{{row[col.Code]}}</span>
</td>
</tr>
</tbody>
<tfoot>
<tr>
<td colspan="5" class="text-center">
<div st-pagination="" st-items-by-page="20" st-displayed-pages="7"></div>
</td>
</tr>
</tfoot>
</table>
</div>
</div>