| | |
| | | import com.vincent.rsf.server.common.domain.BaseParam; |
| | | import com.vincent.rsf.server.common.domain.KeyValVo; |
| | | import com.vincent.rsf.server.common.domain.PageParam; |
| | | import com.vincent.rsf.server.manager.controller.params.BatchUpdateParam; |
| | | import com.vincent.rsf.server.manager.entity.AsnOrder; |
| | | import com.vincent.rsf.server.manager.entity.AsnOrderItem; |
| | | import com.vincent.rsf.server.manager.entity.excel.AsnOrderTemplate; |
| | |
| | | return R.error("Save Fail"); |
| | | } |
| | | return R.ok("Save Success"); |
| | | |
| | | } |
| | | |
| | | |
| | | @PreAuthorize("hasAuthority('manager:asnOrderItem:update')") |
| | | @OperationLog("Update ASN单据") |
| | |
| | | return asnOrderItemService.generateBarcode(orders); |
| | | } |
| | | |
| | | @PreAuthorize("hasAuthority('manager:asnOrderItem:list')") |
| | | @ApiOperation("获取订单物料明细") |
| | | @GetMapping("/asnOrderItem/trackCode/{code}") |
| | | public R getItemByTrackCode(@PathVariable String code) { |
| | | return R.ok(asnOrderItemService.getOne(new LambdaQueryWrapper<AsnOrderItem>().eq(AsnOrderItem::getTrackCode, code))); |
| | | } |
| | | /** |
| | | * ASN单据明细导入 |
| | | * @param file |
| | |
| | | @PreAuthorize("hasAuthority('manager:asnOrderItem:update')") |
| | | public R importExcel(@RequestParam(value = "file") MultipartFile file, @RequestParam String asnId) throws Exception { |
| | | if (Objects.isNull(file)) { |
| | | throw new CoolException("文件不能为空!!"); |
| | | R.error("文件不能为空!!"); |
| | | } |
| | | HashMap<String, Object> hashMap = new HashMap<>(); |
| | | if (!Objects.isNull(asnId)) { |
| | | hashMap.put("asnId", asnId); |
| | | } |
| | | |
| | | return asnOrderItemService.excelImport(file, hashMap); |
| | | } |
| | | |
| | | |
| | | } |