|
@@ -36,6 +36,8 @@ import org.jeecg.modules.billet.rollOutShipp.service.IRollOutShippDetailsService
|
|
|
import org.jeecg.modules.billet.storageBill.entity.StorageBill;
|
|
|
import org.jeecg.modules.billet.storageBill.entity.StorageBillPrint;
|
|
|
import org.jeecg.modules.billet.storageBill.service.IStorageBillPrintService;
|
|
|
+import org.jeecg.modules.billet.storageBill.service.IStorageBillService;
|
|
|
+import org.jeecg.modules.billet.storageBill.vo.StorageBillPrintVO;
|
|
|
import org.jeecg.modules.billet.storageBill.vo.StorageCenterExportRow;
|
|
|
import org.jeecg.modules.carUnit.entity.SysDict;
|
|
|
import org.jeecg.modules.carUnit.entity.SysDictItem;
|
|
@@ -86,6 +88,9 @@ public class StorageBillPrintController extends JeecgController<StorageBillPrint
|
|
|
@Autowired
|
|
|
private IRollDeputyCrossDetailsService rollDeputyCrossDetailsService;
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private IStorageBillService storageBillService;
|
|
|
+
|
|
|
@Autowired
|
|
|
BilletRulerConfigMapper billetRulerConfigMapper;
|
|
|
/**
|
|
@@ -102,10 +107,28 @@ public class StorageBillPrintController extends JeecgController<StorageBillPrint
|
|
|
@GetMapping(value = "/list")
|
|
|
public Result<IPage<StorageBillPrint>> queryPageList(StorageBillPrint storageBillPrint,
|
|
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
|
|
- @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
|
|
|
+ @RequestParam(name = "pageSize", defaultValue = "50") Integer pageSize,
|
|
|
HttpServletRequest req) {
|
|
|
- QueryWrapper<StorageBillPrint> queryWrapper = QueryGenerator.initQueryWrapper(storageBillPrint, req.getParameterMap());
|
|
|
+// QueryWrapper<StorageBillPrint> queryWrapper = QueryGenerator.initQueryWrapper(storageBillPrint, req.getParameterMap());
|
|
|
+ QueryWrapper<StorageBillPrint> queryWrapper = new QueryWrapper<StorageBillPrint>();
|
|
|
Page<StorageBillPrint> page = new Page<StorageBillPrint>(pageNo, pageSize);
|
|
|
+ // 铸机号查询条件
|
|
|
+ queryWrapper.eq("ccm_no", storageBillPrint.getCcmNo());
|
|
|
+ // 时间查询
|
|
|
+ if(oConvertUtils.isNotEmpty(storageBillPrint.getArrivalTime())){
|
|
|
+ // 开始时间
|
|
|
+ Date startTime = storageBillPrint.getArrivalTime();
|
|
|
+ // 结束时间+1天
|
|
|
+ Date endTime = DateUtils.addDays(startTime, 1);
|
|
|
+ log.info("查询时间范围:startTime={}, endTime={}", startTime, endTime);
|
|
|
+ // 修改时间范围查询条件为 >= startTime 且 <= endTime
|
|
|
+ queryWrapper.ge("arrival_time", startTime) // 大于等于开始时间
|
|
|
+ .le("arrival_time", endTime); // 小于等于结束时间
|
|
|
+ }
|
|
|
+ // 班次信息like 查询条件
|
|
|
+ if (storageBillPrint.getClasses() != null && !storageBillPrint.getClasses().isEmpty() && storageBillPrint.getClasses() != null && !storageBillPrint.getClasses().isEmpty()) {
|
|
|
+ queryWrapper.like("classes", storageBillPrint.getClasses());
|
|
|
+ }
|
|
|
IPage<StorageBillPrint> pageList = storageBillPrintService.page(page, queryWrapper);
|
|
|
return Result.OK(pageList);
|
|
|
}
|
|
@@ -133,9 +156,23 @@ public class StorageBillPrintController extends JeecgController<StorageBillPrint
|
|
|
*/
|
|
|
@AutoLog(value = "装运单打印表-编辑")
|
|
|
@ApiOperation(value = "装运单打印表-编辑", notes = "装运单打印表-编辑")
|
|
|
- @RequiresPermissions("storageBillPrint:storage_bill_print:edit")
|
|
|
+// @RequiresPermissions("storageBillPrint:storage_bill_print:edit")
|
|
|
@RequestMapping(value = "/edit", method = {RequestMethod.PUT, RequestMethod.POST})
|
|
|
public Result<String> edit(@RequestBody StorageBillPrint storageBillPrint) {
|
|
|
+ LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
|
|
+ if(oConvertUtils.isNotEmpty(storageBillPrint.getConfirmTime())){
|
|
|
+ storageBillPrint.setConfirmBy(sysUser.getRealname());
|
|
|
+ // 修改确认时间
|
|
|
+ storageBillPrint.setConfirmTime(new Date());
|
|
|
+ // 同步修改装运单storageBill 确认时间
|
|
|
+ StorageBill storageBillInfo = storageBillService.getById(storageBillPrint.getStorageBillId());
|
|
|
+ if(oConvertUtils.isNotEmpty(storageBillInfo)){
|
|
|
+ storageBillInfo.setConfirmTime(storageBillPrint.getConfirmTime());
|
|
|
+ storageBillInfo.setConfirmBy(sysUser.getRealname());
|
|
|
+ storageBillInfo.setRemark(storageBillPrint.getRemark());
|
|
|
+ storageBillService.updateById(storageBillInfo);
|
|
|
+ }
|
|
|
+ }
|
|
|
storageBillPrintService.updateById(storageBillPrint);
|
|
|
return Result.OK("编辑成功!");
|
|
|
}
|