Browse Source

add:增加入库列表查询区间

dist.1.3.0
pref_mail@163.com 4 months ago
parent
commit
f3cced9eae
  1. 2
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/api/DistributionSignforAppController.java
  2. 25
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/controller/WarehouseWarehousingEntryController.java

2
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/api/DistributionSignforAppController.java

@ -65,7 +65,7 @@ public class DistributionSignforAppController {
}
/**
* 签收管理 列表
* 回库任务 列表
*/
@GetMapping("/newPage")
@ApiOperationSupport(order = 1)

25
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/controller/WarehouseWarehousingEntryController.java

@ -97,17 +97,36 @@ public class WarehouseWarehousingEntryController extends BladeController {
/**
* 仓库入库单 分页
*/
@GetMapping("/list")
@PostMapping("/list")
@ApiOperationSupport(order = 2)
@ApiOperation(value = "分页", notes = "传入warehouseWarehousingEntry")
public R<IPage<WarehouseWarehousingEntryEntity>> list(@ApiIgnore @RequestParam Map<String, Object> warehouseWarehousingEntry, Query query) {
public R<IPage<WarehouseWarehousingEntryEntity>> list(@ApiIgnore @RequestBody Map<String, Object> request) {
//获取当前登录人仓库
List<BasicdataWarehouseEntity> myWarehouseList = basicdataWarehouseClient.getMyWatchWarehouse();
List<Long> collect = myWarehouseList.stream()
.map(BasicdataWarehouseEntity::getId)
.collect(Collectors.toList());
Map<String, Object> warehouseWarehousingEntry = (Map<String, Object>) request.get("warehouseWarehousingEntry");
String receiptDateStart = (String) warehouseWarehousingEntry.get("receiptDateStart");
String receiptDateStartEnd = (String) warehouseWarehousingEntry.get("receiptDateStartEnd");
warehouseWarehousingEntry.remove("receiptDateStart");
warehouseWarehousingEntry.remove("receiptDateStartEnd");
Map<String, Object> queryMap = (Map) request.get("query");
Query query = new Query();
query.setSize((Integer) queryMap.get("size"));
query.setCurrent((Integer) queryMap.get("current"));
QueryWrapper<WarehouseWarehousingEntryEntity> queryWrapper = Condition.getQueryWrapper(warehouseWarehousingEntry, WarehouseWarehousingEntryEntity.class);
queryWrapper.lambda().in(collect.size()>0,WarehouseWarehousingEntryEntity::getWarehouseId,collect);
queryWrapper.lambda().in(!collect.isEmpty(),WarehouseWarehousingEntryEntity::getWarehouseId,collect);
if(receiptDateStart != null && receiptDateStartEnd != null){
queryWrapper.lambda().between(WarehouseWarehousingEntryEntity::getReceiptDate, receiptDateStart+" 00:00:00", receiptDateStartEnd+" 23:59:59");
}
IPage<WarehouseWarehousingEntryEntity> pages = warehouseWarehousingEntryService.page(Condition.getPage(query), queryWrapper);
return R.data(pages);
}

Loading…
Cancel
Save