| | |
| | | <div class="layui-form layui-card-header layuiadmin-card-header-auto" style="border-bottom:1px solid #CCC" id="top"> |
| | | <div class="layui-form-item"> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label" style="width: 60px;">类别名称</label> |
| | | <label class="layui-form-label" style="width: 60px;">库区名称</label> |
| | | <div class="layui-input-inline"> |
| | | <input type="text" id="CategoryName" name="CategoryName" placeholder="请输入类别名称" autocomplete="off" class="layui-input"> |
| | | </div> |
| | |
| | | }); |
| | | if (res.code == 0) { //成功 |
| | | for (var k = 0; k < res.data.length; k++) { |
| | | if (res.data[k].MenuName == "新增类别") { |
| | | if (res.data[k].MenuName == "新增库区") { |
| | | $(function() { |
| | | $("#approvalBtn").show(); |
| | | }); |
| | | } |
| | | if (res.data[k].MenuName == "删除类别") { |
| | | if (res.data[k].MenuName == "删除库区") { |
| | | $(function() { |
| | | $(".approvalBtndel").show(); |
| | | }); |
| | | } |
| | | if (res.data[k].MenuName == "编辑类别") { |
| | | if (res.data[k].MenuName == "编辑库区") { |
| | | console.log(1) |
| | | $(function() { |
| | | $(".approvalBtnupt").show(); |
| | |
| | | title: '序号', type: 'numbers', fixed: 'left', width:65 |
| | | }, |
| | | { |
| | | field: 'CategoryNo', title: '类别编码', align: 'center', fixed: 'left',width:100 |
| | | field: 'CategoryNo', title: '库区编码', align: 'center', fixed: 'left',width:100 |
| | | }, |
| | | { |
| | | field: 'CategoryName', title: '类别名称', align: 'center',width:100 |
| | | field: 'CategoryName', title: '库区名称', align: 'center',width:100 |
| | | }, |
| | | { |
| | | field: 'AreaName', title: '绑定区域', align: 'center' |
| | |
| | | add: function() { |
| | | layer.open({ |
| | | type: 2, |
| | | title: '添加类别信息', |
| | | title: '添加库区信息', |
| | | content: 'CategoryForm.html', |
| | | maxmin: true, |
| | | area: ['530px', '530px'], |
| | |
| | | //删除 |
| | | if (obj.event === 'del') |
| | | { |
| | | layer.confirm('确定删除选中的类别?', function(index) { |
| | | layer.confirm('确定删除选中的库区?', function(index) { |
| | | |
| | | cusid = data.Id; |
| | | console.log(cusid); |
| | |
| | | cusId = data.Id; |
| | | layer.open({ |
| | | type: 2, |
| | | title: '编辑类别信息', |
| | | title: '编辑库区信息', |
| | | content: 'CategoryForm.html?id=' + cusId, |
| | | maxmin: true, |
| | | area: ['530px', '530px'], |