|  |  |  | 
|---|
|  |  |  | ,{field: 'typeNo$', align: 'center',title: '入出库类型'} | 
|---|
|  |  |  | // ,{field: 'typeDesc', align: 'center',title: '作业类型'} | 
|---|
|  |  |  | ,{field: 'stnNo$', align: 'center',title: '起始站点'} | 
|---|
|  |  |  | ,{field: 'stnDesc', align: 'center',title: '站点名称'} | 
|---|
|  |  |  | ,{field: 'stnDesc', align: 'center',title: '站点名称', edit:'text'} | 
|---|
|  |  |  | ,{field: 'crnNo$', align: 'center',title: '堆垛机号'} | 
|---|
|  |  |  | ,{field: 'crnStn$', align: 'center',title: '目标站点'} | 
|---|
|  |  |  | ,{field: 'memo', align: 'center',title: '备注'} | 
|---|
|  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | // 页面修改 | 
|---|
|  |  |  | table.on('edit(staDesc)', function (obj) { | 
|---|
|  |  |  | $('body').keydown(function () { | 
|---|
|  |  |  | if (event.keyCode === 13) { | 
|---|
|  |  |  | layer.confirm('保存修改?', function(){ | 
|---|
|  |  |  | $.ajax({ | 
|---|
|  |  |  | url: baseUrl+"/staDesc/update/auth", | 
|---|
|  |  |  | headers: {'token': localStorage.getItem('token')}, | 
|---|
|  |  |  | data: top.reObject({ | 
|---|
|  |  |  | typeId: obj.data.typeId, | 
|---|
|  |  |  | stnDesc: obj.value | 
|---|
|  |  |  | }), | 
|---|
|  |  |  | method: 'POST', | 
|---|
|  |  |  | async: false, | 
|---|
|  |  |  | success: function (res) { | 
|---|
|  |  |  | if (res.code === 200){ | 
|---|
|  |  |  | console.log(res); | 
|---|
|  |  |  | } else if (res.code === 403){ | 
|---|
|  |  |  | top.location.href = baseUrl+"/"; | 
|---|
|  |  |  | }else { | 
|---|
|  |  |  | layer.msg(res.msg) | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | console.log(obj); | 
|---|
|  |  |  | }); | 
|---|
|  |  |  | } | 
|---|
|  |  |  | layer.confirm('保存修改?', function(){ | 
|---|
|  |  |  | $.ajax({ | 
|---|
|  |  |  | url: baseUrl+"/staDesc/update/auth", | 
|---|
|  |  |  | headers: {'token': localStorage.getItem('token')}, | 
|---|
|  |  |  | data: top.reObject({ | 
|---|
|  |  |  | typeId: obj.data.typeId, | 
|---|
|  |  |  | stnDesc: obj.value, | 
|---|
|  |  |  | memo: obj.data.memo | 
|---|
|  |  |  | }), | 
|---|
|  |  |  | method: 'POST', | 
|---|
|  |  |  | async: false, | 
|---|
|  |  |  | success: function (res) { | 
|---|
|  |  |  | layer.closeAll(); | 
|---|
|  |  |  | if (res.code === 200){ | 
|---|
|  |  |  | tableReload(false); | 
|---|
|  |  |  | } else if (res.code === 403){ | 
|---|
|  |  |  | top.location.href = baseUrl+"/"; | 
|---|
|  |  |  | }else { | 
|---|
|  |  |  | layer.msg(res.msg) | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  | }) | 
|---|
|  |  |  | }); | 
|---|
|  |  |  | }); | 
|---|
|  |  |  |  | 
|---|