Browse Source

Merge branch 'pre-production'

chenglong
pref_mail@163.com 1 year ago
parent
commit
8031129227
  1. 2
      blade-service-api/logpm-supervise-api/src/main/java/com/logpm/supervise/vo/ClassifyVO.java
  2. 3
      blade-service-api/logpm-supervise-api/src/main/java/com/logpm/supervise/vo/api/ClassifyApiVO.java
  3. 12
      blade-service/logpm-supervise/src/main/java/com/logpm/supervise/api/ClassifyApi.java
  4. 2
      blade-service/logpm-supervise/src/main/java/com/logpm/supervise/mapper/ClassifyMapper.xml
  5. 4
      blade-service/logpm-supervise/src/main/java/com/logpm/supervise/mapper/IndicatorsAnnexMapper.xml
  6. 2
      blade-service/logpm-supervise/src/main/java/com/logpm/supervise/mapper/IndicatorsMapper.java
  7. 27
      blade-service/logpm-supervise/src/main/java/com/logpm/supervise/service/impl/ClassifyServiceImpl.java
  8. 47
      blade-service/logpm-supervise/src/main/java/com/logpm/supervise/wrapper/PointsWrapper.java
  9. 41
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/api/WarehouseUpdownTypeApiController.java
  10. 2
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseUpdownGoodsMapper.java
  11. 12
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseUpdownGoodsMapper.xml
  12. 1
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseUpdownGoodsService.java
  13. 2
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseUpdownTypeService.java
  14. 5
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseUpdownGoodsServiceImpl.java
  15. 8
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseUpdownTypeServiceImpl.java

2
blade-service-api/logpm-supervise-api/src/main/java/com/logpm/supervise/vo/ClassifyVO.java

@ -37,5 +37,7 @@ public class ClassifyVO extends ClassifyEntity {
private List<PointsEntity> pointsEntities = new ArrayList<>();
private List<PointsVO> pointsVOS ;
}

3
blade-service-api/logpm-supervise-api/src/main/java/com/logpm/supervise/vo/api/ClassifyApiVO.java

@ -2,6 +2,7 @@ package com.logpm.supervise.vo.api;
import com.logpm.supervise.entity.ClassifyEntity;
import com.logpm.supervise.vo.PointsVO;
import lombok.Data;
import lombok.EqualsAndHashCode;
@ -12,4 +13,6 @@ import java.util.List;
public class ClassifyApiVO extends ClassifyEntity {
private List<ClassifyApiVO> children;
private List<PointsVO> pointsVOS;
}

12
blade-service/logpm-supervise/src/main/java/com/logpm/supervise/api/ClassifyApi.java

@ -62,11 +62,12 @@ public class ClassifyApi {
@GetMapping("/myApiIndicatorsDetail")
@ApiOperationSupport(order = 1)
@ApiOperation(value = "我的考核列表")
public R myApiIndicatorsDetail(@RequestParam Long Id) {
R r = classifyService.myApiIndicatorsDetail(Id);
public R myApiIndicatorsDetail(@RequestParam Long id) {
R r = classifyService.myApiIndicatorsDetail(id);
return r;
}
@PostMapping("/updateApiIndicators")
@ApiOperationSupport(order = 1)
@ApiOperation(value = "小程序保存考核内容", notes = "传入classify")
@ -75,11 +76,4 @@ public class ClassifyApi {
return r;
}
}

2
blade-service/logpm-supervise/src/main/java/com/logpm/supervise/mapper/ClassifyMapper.xml

@ -56,7 +56,7 @@
</select>
<select id="selectAllClassifyList" resultType="com.logpm.supervise.vo.api.ClassifyApiVO">
SELECT * FROM sup_classify WHERE is_deleted = 0
<if test="pid != null and pid = 0">
<if test="pid != null and pid == 0">
and p_id = 0
</if>
<if test="pid != null and pid != 0">

4
blade-service/logpm-supervise/src/main/java/com/logpm/supervise/mapper/IndicatorsAnnexMapper.xml

@ -8,8 +8,8 @@
<select id="findListByIndicatorsIdAndType" resultType="com.logpm.supervise.entity.IndicatorsAnnexEntity">
select *
from sup_indicators_annex
where indicators_id = #{id}
and `type` = #{type}
and indicators_id = #{id}
and type = #{type}
</select>
</mapper>

2
blade-service/logpm-supervise/src/main/java/com/logpm/supervise/mapper/IndicatorsMapper.java

@ -25,5 +25,5 @@ public interface IndicatorsMapper extends BaseMapper<IndicatorsEntity> {
* @param params
* @return
*/
Page<IndicatorsVO> selectMyApiIndicators(IPage<IndicatorsVO> page, Map<String, Object> params);
Page<IndicatorsVO> selectMyApiIndicators(IPage<IndicatorsVO> page,@Param("params") Map<String, Object> params);
}

27
blade-service/logpm-supervise/src/main/java/com/logpm/supervise/service/impl/ClassifyServiceImpl.java

@ -36,7 +36,9 @@ import com.logpm.supervise.service.IPointsService;
import com.logpm.supervise.vo.ClassifyVO;
import com.logpm.supervise.vo.IndicatorsVO;
import com.logpm.supervise.vo.api.ClassifyApiVO;
import com.logpm.supervise.wrapper.ClassifyWrapper;
import com.logpm.supervise.wrapper.IndicatorsWrapper;
import com.logpm.supervise.wrapper.PointsWrapper;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springblade.core.mp.base.BaseServiceImpl;
@ -47,6 +49,7 @@ import org.springblade.core.tool.utils.Func;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.Objects;
@ -195,9 +198,27 @@ public class ClassifyServiceImpl extends BaseServiceImpl<ClassifyMapper, Classif
Long pid = 0L;
List<ClassifyApiVO> classifyEntities = getClassifyList(pid);
for (ClassifyApiVO classifyEntity : classifyEntities) {
List<ClassifyApiVO> classifyList = getClassifyList(classifyEntity.getId());
if (!Objects.isNull(classifyList)){
classifyEntity.setChildren(classifyList);
if (classifyEntity.getPId().equals(0L)){
List<ClassifyApiVO> classifyList = new ArrayList<>();
List<ClassifyEntity> entityList = this.list(Wrappers.<ClassifyEntity>query().lambda()
.eq(ClassifyEntity::getPId, classifyEntity.getId())
.ne(ClassifyEntity::getPId, 0L)
);
for (ClassifyEntity entity : entityList) {
ClassifyVO classifyVO = ClassifyWrapper.build().entityVO(entity);
ClassifyApiVO classifyApiVO = Func.copy(classifyVO, ClassifyApiVO.class);
List<PointsEntity> list = pointsService.list(Wrappers.<PointsEntity>query().lambda()
.eq(PointsEntity::getClassifyId, classifyEntity.getId())
);
if(Func.isNotEmpty(list)){
classifyApiVO.setPointsVOS(PointsWrapper.build().listVO(list));
}
classifyList.add(classifyApiVO);
}
if (!Objects.isNull(classifyList)){
classifyEntity.setChildren(classifyList);
}
}
}
return classifyEntities;

47
blade-service/logpm-supervise/src/main/java/com/logpm/supervise/wrapper/PointsWrapper.java

@ -0,0 +1,47 @@
/*
* Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* Neither the name of the dreamlu.net developer nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
* Author: Chill 庄骞 (smallchill@163.com)
*/
package com.logpm.supervise.wrapper;
import com.logpm.supervise.entity.IndicatorsEntity;
import com.logpm.supervise.entity.PointsEntity;
import com.logpm.supervise.vo.IndicatorsVO;
import com.logpm.supervise.vo.PointsVO;
import org.springblade.core.mp.support.BaseEntityWrapper;
import org.springblade.core.tool.utils.BeanUtil;
import java.util.Objects;
/**
* 分类指标表 包装类,返回视图层所需的字段
*
* @author BladeX
* @since 2024-01-23
*/
public class PointsWrapper extends BaseEntityWrapper<PointsEntity, PointsVO> {
public static PointsWrapper build() {
return new PointsWrapper();
}
@Override
public PointsVO entityVO(PointsEntity pointsEntity) {
PointsVO pointsVO = Objects.requireNonNull(BeanUtil.copy(pointsEntity, PointsVO.class));
return pointsVO;
}
}

41
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/api/WarehouseUpdownTypeApiController.java

@ -143,6 +143,47 @@ public class WarehouseUpdownTypeApiController {
}
@ResponseBody
@PostMapping("/orderUpshelfDetailByAllocationId")
@ApiOperationSupport(order = 1)
@ApiOperation(value = "已上架订单详情", notes = "传入trayTypeDTO")
public R orderUpshelfDetailByAllocationId(@RequestBody UpdownTypeDTO updownTypeDTO ) {
String method = "###########orderUpshelfDetailByAllocationId: ";
log.info(method + "已上架订单详情 updownTypeDTO={}", updownTypeDTO);
String orderCode = updownTypeDTO.getOrderCode();
Long allocationId = updownTypeDTO.getAllocationId();
try{
BasicdataWarehouseEntity myCurrentWarehouse = warehouseClient.getMyCurrentWarehouse();
if(Objects.isNull(myCurrentWarehouse)){
log.warn(method+"仓库信息不能为空");
return R.fail(403,"仓库信息不能为空");
}
if(Objects.isNull(allocationId)){
log.warn(method+"库位id为空 allocationId={}",allocationId);
return R.fail(403,"库位id为空");
}
if(StringUtil.isBlank(orderCode)){
log.warn(method+"订单编码不能为空 orderCode={}",orderCode);
return R.fail(403,"订单编码不能为空");
}
//查询该库位的货物信息
List<String> orderPackageCodes = warehouseUpdownTypeService.orderUpshelfDetailByAllocationId(orderCode,allocationId,myCurrentWarehouse.getId());
return R.data(orderPackageCodes);
}catch (CustomerException e){
log.warn(e.message);
return R.fail(e.code,e.message);
}catch (Exception e){
log.error(method+"系统异常,联系管理员",e);
return R.fail(500,"系统异常,联系管理员");
}
}
@ResponseBody
@PostMapping("/upShelfOrder")
@ApiOperationSupport(order = 1)

2
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseUpdownGoodsMapper.java

@ -124,6 +124,8 @@ public interface WarehouseUpdownGoodsMapper extends BaseMapper<WarehouseUpdownGo
List<StockOrderListVO> findStockOrderDetailList(@Param("allocationId") Long allocationId, @Param("warehouseId") Long warehouseId);
List<String> orderUpshelfDetailByAllocationId(@Param("orderCode") String orderCode, @Param("allocationId") Long allocationId, @Param("warehouseId") Long warehouseId);
// /**
// * 根据货位查询货物

12
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseUpdownGoodsMapper.xml

@ -468,4 +468,16 @@
and lwug.association_type = '4'
</select>
<select id="orderUpshelfDetailByAllocationId" resultType="String">
select lwug.association_value
from logpm_warehouse_updown_goods lwug
left join logpm_distribution_parcel_list ldpl on ldpl.order_package_code = lwug.association_value
where lwug.warehouse_id = #{warehouseId}
and ldpl.warehouse_id = #{warehouseId}
and ldpl.order_code = #{orderCode}
and lwug.allocation_id = #{allocationId}
and lwug.association_type = '3'
</select>
</mapper>

1
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseUpdownGoodsService.java

@ -149,4 +149,5 @@ public interface IWarehouseUpdownGoodsService extends BaseService<WarehouseUpdow
List<StockOrderListVO> findStockOrderDetailList(Long allocationId, Long warehouseId);
List<String> orderUpshelfDetailByAllocationId(String orderCode, Long allocationId, Long warehouseId);
}

2
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseUpdownTypeService.java

@ -86,4 +86,6 @@ public interface IWarehouseUpdownTypeService extends BaseService<WarehouseUpdown
R downDeliveryPackage(List<UpShelfPackageDTO> upShelfPackageList, Long warehouseId);
R findAllocationData(Long allocationId, Long warehouseId);
List<String> orderUpshelfDetailByAllocationId(String orderCode, Long allocationId, Long warehouseId);
}

5
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseUpdownGoodsServiceImpl.java

@ -253,4 +253,9 @@ public class WarehouseUpdownGoodsServiceImpl extends BaseServiceImpl<WarehouseUp
return baseMapper.findStockOrderDetailList(allocationId,warehouseId);
}
@Override
public List<String> orderUpshelfDetailByAllocationId(String orderCode, Long allocationId, Long warehouseId) {
return baseMapper.orderUpshelfDetailByAllocationId(orderCode,allocationId,warehouseId);
}
}

8
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseUpdownTypeServiceImpl.java

@ -148,6 +148,14 @@ public class WarehouseUpdownTypeServiceImpl extends BaseServiceImpl<WarehouseUpd
return R.data(map);
}
@Override
public List<String> orderUpshelfDetailByAllocationId(String orderCode, Long allocationId, Long warehouseId) {
List<String> ls = warehouseUpdownGoodsService.orderUpshelfDetailByAllocationId(orderCode,allocationId,warehouseId);
return ls;
}
private void packageChangeStockByAllocaton(WarehouseUpdownGoodsEntity one) {
//当前登录人选择的仓库

Loading…
Cancel
Save