d71dbfb6 by yangjianbin

init

1 parent 494a4fdd
......@@ -101,6 +101,7 @@
<?php $this->load->view('common/footer'); ?>
<script>
var draw = null;
var table = $('#table').dataTable({
aaSorting: [[1, "desc"]],
serverSide: true,
......@@ -119,10 +120,12 @@
// },
ajax: {
url: apiBaseUrl + '/order/into/getAllApplyOrder',
dataFilter: function (json,a,b) {
console.log(json, a, b)
dataFilter: function (json) {
var ret = {}, json = jQuery.parseJSON(json);
ret.data = json.data;
if(draw) {
ret.draw = draw;
}
// ret.draw = parseInt(json.page.currentPage);
ret.recordsTotal = parseInt(json.page.totalNumber);
ret.recordsFiltered = parseInt(json.page.totalNumber);
......@@ -131,6 +134,7 @@
data: function (data) {
data.pageSize = data.length;
data.currentPage = parseFloat(data.start / data.length) + 1;
draw = data.draw;
return data;
}
/*,
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!