商品/耗材 记录接口
This commit is contained in:
parent
0447d240b2
commit
5be1876d3d
|
|
@ -86,9 +86,7 @@ public class TbConsInfoFlowServiceImpl implements TbConsInfoFlowService {
|
||||||
//入库stockInNumber; stockIn
|
//入库stockInNumber; stockIn
|
||||||
//出库stockOutNumber; stockout
|
//出库stockOutNumber; stockout
|
||||||
public Map<String,Object> queryPage(TbConsInfoFlowQueryCriteria criteria){
|
public Map<String,Object> queryPage(TbConsInfoFlowQueryCriteria criteria){
|
||||||
if(StringUtils.isBlank(criteria.getColumn())){
|
if(StringUtils.isNotBlank(criteria.getColumn())){
|
||||||
throw new BadRequestException("必填参数未填写");
|
|
||||||
}
|
|
||||||
switch (criteria.getColumn()){
|
switch (criteria.getColumn()){
|
||||||
case "addCountNumber":
|
case "addCountNumber":
|
||||||
criteria.setBizCode(Arrays.asList("stockIn","cancelCart","init","stockIn","checkStockIn"));
|
criteria.setBizCode(Arrays.asList("stockIn","cancelCart","init","stockIn","checkStockIn"));
|
||||||
|
|
@ -118,7 +116,7 @@ public class TbConsInfoFlowServiceImpl implements TbConsInfoFlowService {
|
||||||
criteria.setBizCode(Arrays.asList("stockout"));
|
criteria.setBizCode(Arrays.asList("stockout"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
Sort sort = Sort.by(Sort.Direction.DESC, "id");
|
Sort sort = Sort.by(Sort.Direction.DESC, "id");
|
||||||
Pageable pageable = PageRequest.of(criteria.getPage(), criteria.getSize(), sort);
|
Pageable pageable = PageRequest.of(criteria.getPage(), criteria.getSize(), sort);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -69,9 +69,7 @@ public class TbProductStockDetailServiceImpl implements TbProductStockDetailServ
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Map<String,Object> queryPage(TbProductStockDetailQueryCriteria criteria){
|
public Map<String,Object> queryPage(TbProductStockDetailQueryCriteria criteria){
|
||||||
if(StringUtils.isBlank(criteria.getColumn())){
|
if(StringUtils.isNotBlank(criteria.getColumn())){
|
||||||
throw new BadRequestException("必填参数未填写");
|
|
||||||
}
|
|
||||||
switch (criteria.getColumn()){
|
switch (criteria.getColumn()){
|
||||||
case "addCountNumber":
|
case "addCountNumber":
|
||||||
criteria.setType(Arrays.asList("供应商入库", "盘点入库", "其他入库", "退单"));
|
criteria.setType(Arrays.asList("供应商入库", "盘点入库", "其他入库", "退单"));
|
||||||
|
|
@ -95,6 +93,7 @@ public class TbProductStockDetailServiceImpl implements TbProductStockDetailServ
|
||||||
criteria.setType(Arrays.asList("报损"));
|
criteria.setType(Arrays.asList("报损"));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
Sort sort = Sort.by(Sort.Direction.DESC, "id");
|
Sort sort = Sort.by(Sort.Direction.DESC, "id");
|
||||||
Pageable pageable = PageRequest.of(criteria.getPage(), criteria.getSize(), sort);
|
Pageable pageable = PageRequest.of(criteria.getPage(), criteria.getSize(), sort);
|
||||||
|
|
@ -121,7 +120,7 @@ public class TbProductStockDetailServiceImpl implements TbProductStockDetailServ
|
||||||
@Override
|
@Override
|
||||||
public TbProductStockCountVo stockCount(TbProductStockCountQueryCriteria criteria) throws ParseException {
|
public TbProductStockCountVo stockCount(TbProductStockCountQueryCriteria criteria) throws ParseException {
|
||||||
if (criteria.getStartTime() == null || criteria.getEndTime() == null) {
|
if (criteria.getStartTime() == null || criteria.getEndTime() == null) {
|
||||||
criteria.setEndTime(new Date());//
|
criteria.setEndTime(new Date());
|
||||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
||||||
criteria.setStartTime(sdf.parse("2024-01-01"));//创建2024年1月1日的Date对象
|
criteria.setStartTime(sdf.parse("2024-01-01"));//创建2024年1月1日的Date对象
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue