|  |  |  | 
|---|
|  |  |  | {type: 'numbers'}, | 
|---|
|  |  |  | {field: 'orderNo', title: '单据编号', templet: '#orderNoTpl'}, | 
|---|
|  |  |  | {field: 'docType$', align: 'center', title: '类型',  minWidth: 160, width: 160}, | 
|---|
|  |  |  | {field: 'cstmrName', align: 'center', title: '客户'}, | 
|---|
|  |  |  | {align: 'center', title: '明细', toolbar: '#tbLook', minWidth: 160, width: 160}, | 
|---|
|  |  |  | {field: 'createTime$', title: '创建时间', minWidth: 200, width: 200}, | 
|---|
|  |  |  | {field: 'settle$', align: 'center', title: '状态', templet: '#settleTpl',  minWidth: 160, width: 160}, | 
|---|
|  |  |  | {field: 'memo', align: 'center',title: '备注', hide: true}, | 
|---|
|  |  |  | {field: 'remark', align: 'center',title: '备注'}, | 
|---|
|  |  |  | {align: 'center', title: '操作', toolbar: '#operate', width: 180} | 
|---|
|  |  |  | ]], | 
|---|
|  |  |  | request: { | 
|---|
|  |  |  | 
|---|
|  |  |  | // 搜索 | 
|---|
|  |  |  | form.on('submit(tbSearch)', function (data) { | 
|---|
|  |  |  | insTb.reload({where: data.field, page: {curr: 1}}); | 
|---|
|  |  |  | }); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | // 重置 | 
|---|
|  |  |  | form.on('submit(reset)', function (data) { | 
|---|
|  |  |  | pageCurr = 1; | 
|---|
|  |  |  | clearFormVal($('#search-box')); | 
|---|
|  |  |  | tableReload(false); | 
|---|
|  |  |  | }); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | // 添加 | 
|---|
|  |  |  | 
|---|
|  |  |  | {field: 'maktx', title: '商品名称', width: 160}, | 
|---|
|  |  |  | {field: 'specs', title: '规格'}, | 
|---|
|  |  |  | {field: 'batch', title: '批号'}, | 
|---|
|  |  |  | {field: 'weight', title: '辅数量'}, | 
|---|
|  |  |  | {field: 'anfme', title: '待完结数量'}, | 
|---|
|  |  |  | {field: 'qty', title: '待上报数量', style: 'font-weight: bold'}, | 
|---|
|  |  |  | {field: 'workQty', title: '已上报数量'}, | 
|---|
|  |  |  | 
|---|
|  |  |  | orderId: Number(data.field.id), | 
|---|
|  |  |  | docType: Number(data.field.docType), | 
|---|
|  |  |  | orderNo: data.field.orderNo, | 
|---|
|  |  |  | itemId: Number(data.field.itemId), | 
|---|
|  |  |  | itemName: data.field.itemName, | 
|---|
|  |  |  | defNumber: Number(data.field.defNumber), | 
|---|
|  |  |  | cstmr: data.field.cstmr, | 
|---|
|  |  |  | orderDetlList: nList | 
|---|
|  |  |  | }), | 
|---|
|  |  |  | contentType:'application/json;charset=UTF-8', | 
|---|
|  |  |  | 
|---|
|  |  |  | ,range: true | 
|---|
|  |  |  | }); | 
|---|
|  |  |  | }); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | function tableReload(child) { | 
|---|
|  |  |  | var searchData = {}; | 
|---|
|  |  |  | $.each($('#search-box [name]').serializeArray(), function() { | 
|---|
|  |  |  | searchData[this.name] = this.value; | 
|---|
|  |  |  | }); | 
|---|
|  |  |  | insTb.reload({ | 
|---|
|  |  |  | where: searchData, | 
|---|
|  |  |  | page: {curr: pageCurr} | 
|---|
|  |  |  | }); | 
|---|
|  |  |  | } | 
|---|