| | |
| | | import com.sinata.common.core.domain.entity.SysUser; |
| | | import com.sinata.common.entity.PageDTO; |
| | | import com.sinata.common.utils.SecurityUtils; |
| | | import com.sinata.system.domain.MwCheckoutRecord; |
| | | import com.sinata.system.domain.MwDisposalHandleRecord; |
| | | import com.sinata.system.domain.MwDisposalRecord; |
| | | import com.sinata.system.domain.MwTransitCar; |
| | | import com.sinata.system.domain.*; |
| | | import com.sinata.system.domain.dto.CheckOutDto; |
| | | import com.sinata.system.domain.dto.CollectTotalUpDto; |
| | | import com.sinata.system.domain.query.CheckoutRecordQuery; |
| | |
| | | |
| | | @ApiOperation(value = "出库统计下") |
| | | @PostMapping("/record") |
| | | public R<List<CheckOutDto>> record() { |
| | | public R<List<CheckOutDto>> record(@DateTimeFormat(iso = DateTimeFormat.ISO.DATE)LocalDate date) { |
| | | SysUser sysUser = SecurityUtils.getLoginUser().getUser(); |
| | | SysUser byId2 = userService.getById(sysUser.getUserId()); |
| | | LocalDate now = LocalDate.now(); |
| | | List<MwCheckoutRecord> list = mwCheckoutRecordService.lambdaQuery().eq(MwCheckoutRecord::getDepartmentId, byId2.getDepartmentId()).orderByDesc(MwCheckoutRecord::getCheckoutTime).list(); |
| | | List<MwCheckoutRecord> list = mwCheckoutRecordService.lambdaQuery().ge(MwCheckoutRecord::getCreateTime, date.atStartOfDay()) |
| | | .le(MwCheckoutRecord::getCreateTime, date.atTime(23,59,59)).eq(MwCheckoutRecord::getDepartmentId, byId2.getDepartmentId()).orderByDesc(MwCheckoutRecord::getCheckoutTime).list(); |
| | | List<CheckOutDto> backList = new ArrayList<>(); |
| | | for (MwCheckoutRecord mwCheckoutRecord : list) { |
| | | CheckOutDto checkOutDto = new CheckOutDto(); |