Browse Source

Merge remote-tracking branch 'origin/dev' into dev

training
caoyizhong 1 year ago
parent
commit
74eb94b9ac
  1. 2
      blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/feign/IDistributionStockListClient.java
  2. 12
      blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/controller/BasicdataDriverArteryController.java
  3. 1
      blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataCodeServiceImpl.java
  4. 20
      blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataGoodsShelfServiceImpl.java
  5. 6
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.xml
  6. 3
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java

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

@ -112,7 +112,7 @@ public interface IDistributionStockListClient {
@GetMapping(API_PREFIX+"/getListByMarketIdAndMaterialName")
List<DistributionStockListEntity> getListByMarketIdAndMaterialName(@RequestParam("marketId") Long marketId, @RequestParam("materialName") String materialName, @RequestParam("warehouseId") Long warehouseId);
@GetMapping(API_PREFIX+"/getListByMarketIdAndMaterialName")
@GetMapping(API_PREFIX+"/getStockListByWarehouseIdAndMarketAndStockListInfo")
List<DistributionStockListEntity> getStockListByWarehouseIdAndMarketAndStockListInfo(@RequestParam("incomingBatch") String incomingBatch,@RequestParam("marketNames") List<String> marketNames,@RequestParam("warehouseId") Long warehouseId);

12
blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/controller/BasicdataDriverArteryController.java

@ -44,7 +44,7 @@ import org.springblade.core.tool.utils.Func;
import org.springblade.system.entity.User;
import org.springblade.system.feign.IUserClient;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.servlet.handler.UserRoleAuthorizationInterceptor;
import springfox.documentation.annotations.ApiIgnore;
import javax.servlet.http.HttpServletResponse;
@ -130,11 +130,11 @@ public class BasicdataDriverArteryController extends BladeController {
}
String phone = basicdataDriverArtery.getPhone();
R<User> userR = userClient.userInfoByPhone(AuthUtil.getUser().getTenantId(), phone);
if (Func.isNotEmpty(userR.getData())){
User user = userR.getData();
basicdataDriverArtery.setUserId(user.getId());
}
// R<User> userR = userClient.userInfoByPhone(AuthUtil.getUser().getTenantId(), phone);
// if (Func.isNotEmpty(userR.getData())){
// User user = userR.getData();
// basicdataDriverArtery.setUserId(user.getId());
// }
boolean save = basicdataDriverArteryService.save(basicdataDriverArtery);
//加入关联表
if (null !=basicdataDriverArtery.getBindVehicles()&& save){

1
blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataCodeServiceImpl.java

@ -124,6 +124,7 @@ public class BasicdataCodeServiceImpl implements IBasicdataCodeService {
Long incr = bladeRedis.incr(key);
//托盘码查重
BasicdataTrayEntity basicdataTrayEntity = basicdataTrayMapper.selectOne(new QueryWrapper<BasicdataTrayEntity>().lambda()
.eq(BasicdataTrayEntity::getIsDeleted,0)
.like(BasicdataTrayEntity::getPalletCode,HTCD)
.orderByDesc(BasicdataTrayEntity::getCreateTime)
.last("limit 1"));

20
blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataGoodsShelfServiceImpl.java

@ -93,6 +93,8 @@ public class BasicdataGoodsShelfServiceImpl extends BaseServiceImpl<BasicdataGoo
private IBasicdataWarehouseService basicdataWarehouseService;
private static Long ids;
@ -331,7 +333,7 @@ public class BasicdataGoodsShelfServiceImpl extends BaseServiceImpl<BasicdataGoo
@Transactional(rollbackFor = Exception.class)
public R insertallocation(BasicdataGoodsShelfDTO basicdataGoodsShelfDTO) {
//这里需要根据货架的列数和层数进行货位信息的生成
Integer rowNum = basicdataGoodsShelfDTO.getRowNum();//列
Integer rowNum = basicdataGoodsShelfDTO.getRowNum();//列
log.info("列>>>>>>>>>>{}", rowNum);
Integer storeyNum = basicdataGoodsShelfDTO.getStoreyNum();//行
log.info("行>>>>>>>>>>{}", storeyNum);
@ -349,6 +351,7 @@ public class BasicdataGoodsShelfServiceImpl extends BaseServiceImpl<BasicdataGoo
.eq(BasicdataGoodsAllocationEntity::getIsDeleted, 0)
.eq(BasicdataGoodsAllocationEntity::getGoodsShelfId, basicdataGoodsShelfDTO.getId())
);
if (basicdataGoodsAllocationEntities.size() <= 0) {
ArrayList<BasicdataGoodsAllocationEntity> arrayList = new ArrayList<>();
for (Integer i = 0; i < rowNum; i++) {
@ -366,6 +369,9 @@ public class BasicdataGoodsShelfServiceImpl extends BaseServiceImpl<BasicdataGoo
basicdataGoodsAllocationEntity.setGoodsShelfId(basicdataGoodsShelfDTO.getId());
basicdataGoodsAllocationEntity.setGoodsAllocationName(layer + "-" + row);
basicdataGoodsAllocationEntity.setWarehouseId(ck);
String code = basicTenantCodeClient.shelfCode(AuthUtil.getTenantId(), "5");
String allocationCode = basicdataGoodsShelfDTO.getGoodsShelfName()+"-" + basicdataGoodsAllocationEntity.getColumnNum() + "-" + basicdataGoodsAllocationEntity.getLayerNum() ;
basicdataGoodsAllocationEntity.setQrCode(allocationCode);
// basicdataGoodsAllocationEntity.setAllocationStatuc("1");
// basicdataGoodsAllocationEntity.setEnableStatus("1");
arrayList.add(basicdataGoodsAllocationEntity);
@ -433,6 +439,9 @@ public class BasicdataGoodsShelfServiceImpl extends BaseServiceImpl<BasicdataGoo
basicdataGoodsAllocationEntity.setGoodsShelfId(basicdataGoodsShelfDTO.getId());
basicdataGoodsAllocationEntity.setGoodsAllocationName(z + "-" + k);
basicdataGoodsAllocationEntity.setWarehouseId(ck);
// String code = basicTenantCodeClient.shelfCode(AuthUtil.getTenantId(), "5");
String allocationCode = basicdataGoodsShelfDTO.getGoodsShelfName()+"-" + basicdataGoodsAllocationEntity.getColumnNum() + "-" + basicdataGoodsAllocationEntity.getLayerNum() ;
basicdataGoodsAllocationEntity.setQrCode(allocationCode);
arrayList.add(basicdataGoodsAllocationEntity);
}
}
@ -475,6 +484,9 @@ public class BasicdataGoodsShelfServiceImpl extends BaseServiceImpl<BasicdataGoo
basicdataGoodsAllocationEntity.setGoodsShelfId(basicdataGoodsShelfDTO.getId());
basicdataGoodsAllocationEntity.setGoodsAllocationName(i + "-" + k);
basicdataGoodsAllocationEntity.setWarehouseId(ck);
// String code = basicTenantCodeClient.shelfCode(AuthUtil.getTenantId(), "5");
String allocationCode = basicdataGoodsShelfDTO.getGoodsShelfName()+"-" + basicdataGoodsAllocationEntity.getColumnNum() + "-" + basicdataGoodsAllocationEntity.getLayerNum() ;
basicdataGoodsAllocationEntity.setQrCode(allocationCode);
arrayList.add(basicdataGoodsAllocationEntity);
}
}
@ -523,6 +535,9 @@ public class BasicdataGoodsShelfServiceImpl extends BaseServiceImpl<BasicdataGoo
basicdataGoodsAllocationEntity.setGoodsShelfId(basicdataGoodsShelfDTO.getId());
basicdataGoodsAllocationEntity.setGoodsAllocationName(z + "-" + i);
basicdataGoodsAllocationEntity.setWarehouseId(ck);
// String code = basicTenantCodeClient.shelfCode(AuthUtil.getTenantId(), "5");
String allocationCode = basicdataGoodsShelfDTO.getGoodsShelfName()+"-" + basicdataGoodsAllocationEntity.getColumnNum() + "-" + basicdataGoodsAllocationEntity.getLayerNum() ;
basicdataGoodsAllocationEntity.setQrCode(allocationCode);
arrayList.add(basicdataGoodsAllocationEntity);
}
}
@ -619,6 +634,9 @@ public class BasicdataGoodsShelfServiceImpl extends BaseServiceImpl<BasicdataGoo
basicdataGoodsAllocationEntity.setGoodsAreaId(basicdataGoodsShelfDTO.getGoodsAreaId());
basicdataGoodsAllocationEntity.setGoodsShelfId(basicdataGoodsShelfDTO.getId());
basicdataGoodsAllocationEntity.setGoodsAllocationName(z + "-" + i);
// String code = basicTenantCodeClient.shelfCode(AuthUtil.getTenantId(), "5");
String allocationCode = basicdataGoodsShelfDTO.getGoodsShelfName()+"-" + basicdataGoodsAllocationEntity.getColumnNum() + "-" + basicdataGoodsAllocationEntity.getLayerNum() ;
basicdataGoodsAllocationEntity.setQrCode(allocationCode);
basicdataGoodsAllocationEntity.setWarehouseId(ck);
arrayList.add(basicdataGoodsAllocationEntity);
}

6
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/TaskQuestMapper.xml

@ -69,17 +69,17 @@
FROM
logpm_quest_detail lqd
<where>
lqd.quest_type =2 and lqd.is_deleted =0 and (lqd.quest_status = 0 or lqd.quest_status = 1)
lqd.quest_type =2 and lqd.is_deleted =0 and (lqd.quest_status = 0 or lqd.quest_status = 1) and lqd.quest_id = #{param.questId}
<if test="collect != null and @org.apache.commons.collections4.CollectionUtils@isNotEmpty(collect)">
and lqd.warehouse_id in
<foreach collection="collect" item="item" open="(" close=")" separator=",">
#{item}
</foreach>
</if>
<if test="param.code != null and param.code != '' and param.type =1 ">
<if test="param.code != null and param.code != '' and param.type ==1 ">
and lqd.position_code like concat('%',#{param.code},'%')
</if>
<if test="param.code != null and param.code != '' and param.type =2 ">
<if test="param.code != null and param.code != '' and param.type ==2 ">
and lqd.allocation_id = #{param.code}
</if>
</where>

3
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java

@ -191,7 +191,7 @@ public class TaskQuestServiceImpl extends BaseServiceImpl<TaskQuestMapper, TaskQ
@Override
public IPage<TaskQuestApiVO> selectTaskQuestApiPage(IPage<TaskQuestApiVO> page, TaskQuestApiVO taskQuest) {
// baseMapper.setSqlMode();
List<Long> collect = this.getmyWarehouseList();
List<TaskQuestApiVO> taskQuestVOS = baseMapper.selectTaskQuestApiPage(page, taskQuest, collect);
for (TaskQuestApiVO taskQuestVO : taskQuestVOS) {
@ -213,6 +213,7 @@ public class TaskQuestServiceImpl extends BaseServiceImpl<TaskQuestMapper, TaskQ
@Override
public IPage<TaskallocationVO> selectallocationList(IPage<TaskallocationVO> page, TaskSearchDTO taskSearchDTO) {
List<Long> collect = this.getmyWarehouseList();
baseMapper.setSqlMode();
List<TaskallocationVO> list = baseMapper.selectallocationList(page, taskSearchDTO, collect);
if (!list.isEmpty()) {
for (TaskallocationVO taskallocationVO : list) {

Loading…
Cancel
Save