diff --git a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/WarehouseLeasingClient.java b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/WarehouseLeasingClient.java index 534dfd44f..c16b9b238 100644 --- a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/WarehouseLeasingClient.java +++ b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/WarehouseLeasingClient.java @@ -45,8 +45,8 @@ public class WarehouseLeasingClient implements IWarehouseLeasingClient { public List findListByWarehouseIds(List ids, String contractDate) { List list = leasingService.list(Wrappers.lambdaQuery() .in(WarehouseLeasingEntity::getWarehouseId, ids) - .ge(WarehouseLeasingEntity::getLeaseCommencementDate, contractDate) .le(WarehouseLeasingEntity::getLeaseCommencementDate, contractDate) + .ge(WarehouseLeasingEntity::getLeaseTerminationDate, contractDate) ); if (CollUtil.isNotEmpty(list)) { return list; diff --git a/blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/controller/ExpenseWarehouseDayController.java b/blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/controller/ExpenseWarehouseDayController.java index 78793d6cc..8abe9e319 100644 --- a/blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/controller/ExpenseWarehouseDayController.java +++ b/blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/controller/ExpenseWarehouseDayController.java @@ -64,27 +64,6 @@ public class ExpenseWarehouseDayController extends BladeController { private final IExpenseWarehouseDayService expenseWarehouseDayService; - /** - * 日仓储成本统计表 详情 - */ - @GetMapping("/detail") - @ApiOperationSupport(order = 1) - @ApiOperation(value = "详情", notes = "传入expenseWarehouseDay") - public R detail(ExpenseWarehouseDayEntity expenseWarehouseDay) { - ExpenseWarehouseDayEntity detail = expenseWarehouseDayService.getOne(Condition.getQueryWrapper(expenseWarehouseDay)); - return R.data(ExpenseWarehouseDayWrapper.build().entityVO(detail)); - } - /** - * 日仓储成本统计表 分页 - */ - @GetMapping("/list") - @ApiOperationSupport(order = 2) - @ApiOperation(value = "分页", notes = "传入expenseWarehouseDay") - public R> list(@ApiIgnore @RequestParam Map expenseWarehouseDay, Query query) { - IPage pages = expenseWarehouseDayService.page(Condition.getPage(query), Condition.getQueryWrapper(expenseWarehouseDay, ExpenseWarehouseDayEntity.class)); - return R.data(ExpenseWarehouseDayWrapper.build().pageVO(pages)); - } - /** * 日仓储成本统计表 自定义分页 */ @@ -96,61 +75,4 @@ public class ExpenseWarehouseDayController extends BladeController { return R.data(pages); } - /** - * 日仓储成本统计表 新增 - */ - @PostMapping("/save") - @ApiOperationSupport(order = 4) - @ApiOperation(value = "新增", notes = "传入expenseWarehouseDay") - public R save(@Valid @RequestBody ExpenseWarehouseDayEntity expenseWarehouseDay) { - return R.status(expenseWarehouseDayService.save(expenseWarehouseDay)); - } - - /** - * 日仓储成本统计表 修改 - */ - @PostMapping("/update") - @ApiOperationSupport(order = 5) - @ApiOperation(value = "修改", notes = "传入expenseWarehouseDay") - public R update(@Valid @RequestBody ExpenseWarehouseDayEntity expenseWarehouseDay) { - return R.status(expenseWarehouseDayService.updateById(expenseWarehouseDay)); - } - - /** - * 日仓储成本统计表 新增或修改 - */ - @PostMapping("/submit") - @ApiOperationSupport(order = 6) - @ApiOperation(value = "新增或修改", notes = "传入expenseWarehouseDay") - public R submit(@Valid @RequestBody ExpenseWarehouseDayEntity expenseWarehouseDay) { - return R.status(expenseWarehouseDayService.saveOrUpdate(expenseWarehouseDay)); - } - - /** - * 日仓储成本统计表 删除 - */ - @PostMapping("/remove") - @ApiOperationSupport(order = 7) - @ApiOperation(value = "逻辑删除", notes = "传入ids") - public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { - return R.status(expenseWarehouseDayService.deleteLogic(Func.toLongList(ids))); - } - - - /** - * 导出数据 - */ - @GetMapping("/export-expenseWarehouseDay") - @ApiOperationSupport(order = 9) - @ApiOperation(value = "导出数据", notes = "传入expenseWarehouseDay") - public void exportExpenseWarehouseDay(@ApiIgnore @RequestParam Map expenseWarehouseDay, BladeUser bladeUser, HttpServletResponse response) { - QueryWrapper queryWrapper = Condition.getQueryWrapper(expenseWarehouseDay, ExpenseWarehouseDayEntity.class); - //if (!AuthUtil.isAdministrator()) { - // queryWrapper.lambda().eq(ExpenseWarehouseDay::getTenantId, bladeUser.getTenantId()); - //} - queryWrapper.lambda().eq(ExpenseWarehouseDayEntity::getIsDeleted, BladeConstant.DB_NOT_DELETED); - List list = expenseWarehouseDayService.exportExpenseWarehouseDay(queryWrapper); - ExcelUtil.export(response, "日仓储成本统计表数据" + DateUtil.time(), "日仓储成本统计表数据表", list, ExpenseWarehouseDayExcel.class); - } - } diff --git a/blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/job/ExpenseJob.java b/blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/job/ExpenseJob.java index 117584012..043d78b88 100644 --- a/blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/job/ExpenseJob.java +++ b/blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/job/ExpenseJob.java @@ -266,7 +266,7 @@ public class ExpenseJob { private void initWarehouseBasicInfo(ExpenseWarehouseDayEntity entity, BasicdataWarehouseEntity warehouse, DateTime statisticsTime) { entity.setCostSettlementYear(Convert.toStr(DateUtil.year(statisticsTime))); - entity.setCostSettlementMonth(Convert.toStr(DateUtil.month(statisticsTime))); + entity.setCostSettlementMonth(Convert.toStr(DateUtil.month(statisticsTime)) + 1); entity.setCostSettlementDay(Convert.toStr(DateUtil.dayOfMonth(statisticsTime))); entity.setCostSettlement(DateUtil.formatDate(statisticsTime)); entity.setWarehouseName(warehouse.getName());