| | |
| | | |
| | | @RequestMapping(value = "/configType/add/auth") |
| | | @ManagerAuth |
| | | public R list(ConfigType configType){ |
| | | public R add(ConfigType configType){ |
| | | if (Cools.isEmpty(configType)){ |
| | | return R.error(); |
| | | } |
| | |
| | | |
| | | } |
| | | |
| | | @RequestMapping(value = "/configType/delete/auth") |
| | | @ManagerAuth |
| | | public R delete(Long id){ |
| | | configTypeService.deleteById(id); |
| | | return R.ok(); |
| | | |
| | | } |
| | | |
| | | @RequestMapping(value = "/configTypeQuery/auth") |
| | | @ManagerAuth |
| | | public R query(String condition) { |
| | |
| | | }); |
| | | |
| | | // 监听行工具事件 |
| | | table.on('tool(role)', function(obj){ |
| | | table.on('tool(configType)', function(obj){ |
| | | var data = obj.data; |
| | | switch (obj.event) { |
| | | // 详情 |
| | |
| | | }); |
| | | } |
| | | break; |
| | | case 'power': |
| | | roleId = data.id; |
| | | layer.open({ |
| | | type: 2, |
| | | title: data.name + ' 权限分配', |
| | | maxmin: true, |
| | | area: [top.detailWidth/2, '85%'], |
| | | shadeClose: false, |
| | | content: 'role_power_detail.html', |
| | | success: function(layero, index){ |
| | | } |
| | | case 'delete': |
| | | id = data.id; |
| | | layer.confirm('确定删除吗', function(){ |
| | | $.ajax({ |
| | | url: baseUrl+"/configType/delete/auth", |
| | | headers: {'token': localStorage.getItem('token')}, |
| | | data: {id: id}, |
| | | method: 'POST', |
| | | traditional:true, |
| | | success: function (res) { |
| | | if (res.code === 200){ |
| | | layer.closeAll(); |
| | | tableReload(false); |
| | | } else if (res.code === 403){ |
| | | top.location.href = baseUrl+"/"; |
| | | } else { |
| | | layer.msg(res.msg) |
| | | } |
| | | } |
| | | }) |
| | | }); |
| | | break; |
| | | } |
| | |
| | | var cols = [ |
| | | {field: 'id', title: 'id', align: 'center',hide:true} |
| | | ,{type: 'checkbox'} |
| | | ,{field: 'pakinTime$', title: '入库时间', align: 'center'} |
| | | ,{field: 'pakinTime$', title: '入库时间', align: 'center' , sort:true} |
| | | ,{field: 'owner', align: 'center',title: '主体',edit:true} |
| | | ,{field: 'type', align: 'center',title: '物资类别',hide:true,edit:true} |
| | | ,{field: 'proOrderNo', align: 'center',title: '生产订单编号',hide:true,edit:true} |
| | |
| | | ,{field: 'line', align: 'center',title: '生产线',hide:true,edit:true} |
| | | ,{field: 'matnr', align: 'center',title: '存货编码',hide:true,edit:true} |
| | | ,{field: 'brand', align: 'center',title: '牌号',edit:true} |
| | | ,{field: 'batch', align: 'center',title: '批号',edit:true} |
| | | ,{field: 'packageNo', align: 'center',title: '包装号',edit:true} |
| | | ,{field: 'proDate', align: 'center',title: '生产日期',edit:true} |
| | | ,{field: 'batch', align: 'center',title: '批号',edit:true, width: 150, sort:true} |
| | | ,{field: 'packageNo', align: 'center',title: '包装号',edit:true, sort:true} |
| | | ,{field: 'proDate', align: 'center',title: '生产日期',edit:true, width: 100} |
| | | ,{field: 'weight', align: 'center',title: '重量KG',edit:true} |
| | | ,{field: 'packageType', align: 'center',title: '包装类型',edit:true} |
| | | ,{field: 'zpalletType', align: 'center',title: '托盘类型',edit:true} |
| | |
| | | </script> |
| | | |
| | | <script type="text/html" id="operate"> |
| | | <a class="layui-btn layui-btn-xs layui-btn-warm" lay-event="power">删除</a> |
| | | <a class="layui-btn layui-btn-xs layui-btn-warm" lay-event="delete">删除</a> |
| | | <a class="layui-btn layui-btn-xs btn-edit" lay-event="edit">编辑</a> |
| | | </script> |
| | | |