Commit e4ec0bad2edb0af11118e73a21f5e79f3acf21e4

Authored by 谭毅彬
1 parent 5fc7fb15

出入库单据缺失权限添加

Signed-off-by: TanYibin <5491541@qq.com>
ant-design-vue-jeecg/src/views/system/receipt/ReceiptContainerHeaderList.vue
... ... @@ -106,8 +106,8 @@
106 106 </a-button>
107 107 </template>
108 108 <span slot="action" slot-scope="text, record">
109   - <a v-if="record.status == 0 && record.taskType == 200" @click="selectPort(record)">生成任务<a-divider type="vertical"/></a>
110   - <a v-else-if="record.status == 0" @click="createTask(record)">生成任务<a-divider type="vertical"/></a>
  109 + <a v-if="record.status == 0 && record.taskType == 200" @click="selectPort(record)" v-has="'receiptContainerHeader:createTask'">生成任务<a-divider type="vertical"/></a>
  110 + <a v-else-if="record.status == 0" @click="createTask(record)" v-has="'receiptContainerHeader:createTask'">生成任务<a-divider type="vertical"/></a>
111 111 <a-popconfirm v-if="record.status == 0" v-has="'receiptContainerHeader:delete'" title="确定取消配盘吗?" @confirm="() => handleDelete(record.id)">
112 112 <a>取消配盘<a-divider type="vertical"/></a>
113 113 </a-popconfirm>
... ...
ant-design-vue-jeecg/src/views/system/receipt/ReceiptHeaderList.vue
... ... @@ -166,7 +166,7 @@
166 166 <a-popconfirm v-has="'receiptHeader:back'" v-if="record.lastStatus == 800" title="确定回传吗?" @confirm="() => hanleBack(record)">
167 167 <a>回传<a-divider type="vertical"/></a>
168 168 </a-popconfirm>
169   - <a v-if="record.lastStatus < 800" @click="receive(record)">组盘<a-divider type="vertical"/></a>
  169 + <a v-if="record.lastStatus < 800" @click="receive(record)" v-has="'receiptHeader:receive'">组盘<a-divider type="vertical"/></a>
170 170 <a v-if="record.lastStatus == 850" @click="viewReason(record)">原因<a-divider type="vertical"/></a>
171 171 <a-dropdown>
172 172 <a class="ant-dropdown-link">更多 <a-icon type="down"/></a>
... ...
ant-design-vue-jeecg/src/views/system/shipment/ShipmentHeaderList.vue
... ... @@ -176,17 +176,14 @@
176 176 type="primary"
177 177 icon="download"
178 178 size="small"
179   - @click="downloadFile(text)">
180   - 下载
  179 + @click="downloadFile(text)">下载
181 180 </a-button>
182 181 </template>
183   -
184 182 <span slot="action" slot-scope="text, record">
185   - <a-popconfirm v-has="'shipmentHeader:back'" v-if="record.lastStatus == 800" title="确定回传吗?"
186   - @confirm="() => hanleBack(record)">
  183 + <a-popconfirm v-has="'shipmentHeader:back'" v-if="record.lastStatus == 800" title="确定回传吗?" @confirm="() => hanleBack(record)">
187 184 <a>回传</a>
188 185 </a-popconfirm>
189   - <a v-if="record.lastStatus < 800" @click="autoShipmentCombine(record)">自动配盘<a-divider type="vertical"/></a>
  186 + <a v-if="record.lastStatus < 800" @click="autoShipmentCombine(record)" v-has="'shipmentHeader:autoShipmentCombine'">自动配盘<a-divider type="vertical"/></a>
190 187 <a-dropdown>
191 188 <a class="ant-dropdown-link">更多 <a-icon type="down"/></a>
192 189 <a-menu slot="overlay">
... ...
huaheng-wms-core/src/main/java/org/jeecg/modules/wms/config/address/controller/AddressController.java
... ... @@ -53,8 +53,7 @@ public class AddressController extends JeecgController&lt;Address, IAddressService&gt;
53 53 @GetMapping(value = "/list")
54 54 public Result<IPage<Address>> queryPageList(Address address, @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
55 55 @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, HttpServletRequest req) {
56   - String warehouseCode = HuahengJwtUtil.getWarehouseCodeByToken(req);
57   - address.setWarehouseCode(warehouseCode);
  56 + HuahengJwtUtil.setWarehouseCode(req, address);
58 57 QueryWrapper<Address> queryWrapper = QueryGenerator.initQueryWrapper(address, req.getParameterMap());
59 58 Page<Address> page = new Page<Address>(pageNo, pageSize);
60 59 IPage<Address> pageList = addressService.page(page, queryWrapper);
... ... @@ -71,10 +70,7 @@ public class AddressController extends JeecgController&lt;Address, IAddressService&gt;
71 70 @PostMapping(value = "/add")
72 71 @RequiresPermissions("address:add")
73 72 public Result<String> add(@RequestBody Address address, HttpServletRequest req) {
74   - String warehouseCode = HuahengJwtUtil.getWarehouseCodeByToken(req);
75   - if (StringUtils.isNotEmpty(warehouseCode)) {
76   - address.setWarehouseCode(warehouseCode);
77   - }
  73 + HuahengJwtUtil.setWarehouseCode(req, address);
78 74 addressService.save(address);
79 75 return Result.OK("添加成功!");
80 76 }
... ...
huaheng-wms-core/src/main/java/org/jeecg/modules/wms/receipt/receiptContainerHeader/controller/ReceiptContainerHeaderController.java
... ... @@ -68,11 +68,13 @@ public class ReceiptContainerHeaderController extends JeecgController&lt;ReceiptCon
68 68 @Autowired
69 69 private IReceiptContainerDetailService receiptContainerDetailService;
70 70  
71   - @Resource
  71 + @Autowired
72 72 private ILocationService locationService;
73   - @Resource
  73 +
  74 + @Autowired
74 75 private IZoneService zoneService;
75   - @Resource
  76 +
  77 + @Autowired
76 78 private IPortService portService;
77 79  
78 80 /*---------------------------------主表处理-begin-------------------------------------*/
... ... @@ -85,14 +87,12 @@ public class ReceiptContainerHeaderController extends JeecgController&lt;ReceiptCon
85 87 * @param req
86 88 * @return
87 89 */
88   - // @AutoLog(value = "入库组盘-分页列表查询")
89 90 @ApiOperation(value = "入库组盘-分页列表查询", notes = "入库组盘-分页列表查询")
90 91 @GetMapping(value = "/list")
91 92 public Result<IPage<ReceiptContainerHeader>> queryPageList(ReceiptContainerHeader receiptContainerHeader,
92 93 @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
93 94 HttpServletRequest req) {
94   - String warehouseCode = HuahengJwtUtil.getWarehouseCodeByToken(req);
95   - receiptContainerHeader.setWarehouseCode(warehouseCode);
  95 + HuahengJwtUtil.setWarehouseCode(req, receiptContainerHeader);
96 96 QueryWrapper<ReceiptContainerHeader> queryWrapper = QueryGenerator.initQueryWrapper(receiptContainerHeader, req.getParameterMap());
97 97 Page<ReceiptContainerHeader> page = new Page<ReceiptContainerHeader>(pageNo, pageSize);
98 98 IPage<ReceiptContainerHeader> pageList = receiptContainerHeaderService.page(page, queryWrapper);
... ... @@ -109,10 +109,7 @@ public class ReceiptContainerHeaderController extends JeecgController&lt;ReceiptCon
109 109 @RequiresPermissions("receiptContainerHeader:add")
110 110 @PostMapping(value = "/add")
111 111 public Result<String> add(@RequestBody ReceiptContainerHeader receiptContainerHeader, HttpServletRequest req) {
112   - String warehouseCode = HuahengJwtUtil.getWarehouseCodeByToken(req);
113   - if (StringUtils.isNotEmpty(warehouseCode)) {
114   - receiptContainerHeader.setWarehouseCode(warehouseCode);
115   - }
  112 + HuahengJwtUtil.setWarehouseCode(req, receiptContainerHeader);
116 113 receiptContainerHeaderService.save(receiptContainerHeader);
117 114 return Result.OK("添加成功!");
118 115 }
... ... @@ -141,7 +138,6 @@ public class ReceiptContainerHeaderController extends JeecgController&lt;ReceiptCon
141 138 @DeleteMapping(value = "/delete")
142 139 @RequiresPermissions("receiptContainerHeader:delete")
143 140 public Result<?> delete(@RequestParam(name = "id", required = true) String id) {
144   -// receiptContainerHeaderService.delMain(id);
145 141 return receiptContainerHeaderService.cancelReceiving(Integer.parseInt(id));
146 142 }
147 143  
... ...