|
|
|
@ -50,6 +50,38 @@ public class InvProductController {
|
|
|
|
|
@Resource
|
|
|
|
|
private CustomerService customerService;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 库存列表查询接口
|
|
|
|
|
*
|
|
|
|
|
* @param filterInvProductRequest
|
|
|
|
|
* @return
|
|
|
|
|
*/
|
|
|
|
|
@GetMapping("/spms/inv/product/filterProduct")
|
|
|
|
|
public BaseResponse filterProduct(FilterInvProductRequest filterInvProductRequest) {
|
|
|
|
|
boolean showSup = false; //前端控制表格显示列字段
|
|
|
|
|
if (StrUtil.isNotBlank(filterInvProductRequest.getUdiCode())) {
|
|
|
|
|
filterInvProductRequest.setNameCode(FilterUdiUtils.getDiStr(filterInvProductRequest.getUdiCode()));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (StrUtil.isBlank(filterInvProductRequest.getInvCode())) {
|
|
|
|
|
List<String> invCodes = warehouseUserService.selectCodeByUser(customerService.getUserIdStr());
|
|
|
|
|
if (CollUtil.isNotEmpty(invCodes)) {
|
|
|
|
|
filterInvProductRequest.setInvCodes(invCodes);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
List<InvProductResponse> list = invProductService.filterListProduct(filterInvProductRequest);
|
|
|
|
|
PageInfo<InvProductResponse> pageInfo = new PageInfo<>(list);
|
|
|
|
|
InvProductPageResponse<InvProductResponse> pageResponse = new InvProductPageResponse();
|
|
|
|
|
pageResponse.setList(pageInfo.getList());
|
|
|
|
|
pageResponse.setTotal(pageInfo.getTotal());
|
|
|
|
|
pageResponse.setShowSup(showSup);
|
|
|
|
|
return ResultVOUtils.success(pageResponse);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 库存列表查询接口
|
|
|
|
|
*
|
|
|
|
|