add:增加近期的一些新增需求实现;
This commit is contained in:
@@ -13,6 +13,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.apache.commons.lang3.ObjectUtils;
|
||||
import org.nl.common.domain.query.PageQuery;
|
||||
import org.nl.common.exception.BadRequestException;
|
||||
import org.nl.common.utils.CodeUtil;
|
||||
@@ -967,6 +968,15 @@ public class InBillServiceImpl extends ServiceImpl<IOStorInvMapper, IOStorInv> i
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void taskFinish(SchBaseTask task) {
|
||||
List<GroupPlate> groupPlateList = mdPbGroupplateMapper.selectList(new LambdaQueryWrapper<GroupPlate>()
|
||||
.eq(GroupPlate::getStoragevehicle_code, task.getVehicle_code()).orderByDesc(GroupPlate::getCreate_name));
|
||||
if (ObjectUtils.isEmpty(groupPlateList)) {
|
||||
throw new BadRequestException("未找到该托盘的组盘信息,检查一下该托盘是否已出库或在操作日志中查询该托盘是否被删除组盘信息!");
|
||||
}
|
||||
List<MdMeMaterialbase> MdMeMaterialbaseList = mdMeMaterialbaseMapper.selectList(new LambdaQueryWrapper<MdMeMaterialbase>().eq(MdMeMaterialbase::getMaterial_id, groupPlateList.get(0).getMaterial_id()).orderByDesc(MdMeMaterialbase::getCreate_name));
|
||||
if (ObjectUtils.isEmpty(MdMeMaterialbaseList)) {
|
||||
throw new BadRequestException("未找到该托盘的物料信息,检查一下该托盘是否已出库或在操作日志中查询该物料是否被删除!");
|
||||
}
|
||||
String currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getCurrentNickName();
|
||||
String now = DateUtil.now();
|
||||
@@ -1056,14 +1066,9 @@ public class InBillServiceImpl extends ServiceImpl<IOStorInvMapper, IOStorInv> i
|
||||
jo.put("storagevehicle_code", task.getVehicle_code());
|
||||
jo.put("struct_name", task.getPoint_code2());
|
||||
jo.put("struct_code", task.getPoint_code2());
|
||||
GroupPlate groupPlate = mdPbGroupplateMapper.selectOne(new LambdaQueryWrapper<GroupPlate>()
|
||||
.eq(GroupPlate::getStatus, IOSEnum.GROUP_PLATE_STATUS.code("入库"))
|
||||
.eq(GroupPlate::getStoragevehicle_code, task.getVehicle_code()
|
||||
));
|
||||
MdMeMaterialbase mdMeMaterialbase = mdMeMaterialbaseMapper.selectOne(new LambdaQueryWrapper<MdMeMaterialbase>().eq(MdMeMaterialbase::getMaterial_code, groupPlate.getMaterial_id()));
|
||||
jo.put("material_name", mdMeMaterialbase.getMaterial_name());
|
||||
jo.put("material_code", mdMeMaterialbase.getMaterial_code());
|
||||
jo.put("qty", groupPlate.getQty());
|
||||
jo.put("material_name", MdMeMaterialbaseList.get(0).getMaterial_name());
|
||||
jo.put("material_code", MdMeMaterialbaseList.get(0).getMaterial_code());
|
||||
jo.put("qty", groupPlateList.get(0).getQty());
|
||||
List<JSONObject> tableData = new ArrayList<>();
|
||||
tableData.add(jo);
|
||||
towmsmsg.setTableData(tableData);
|
||||
|
||||
@@ -13,6 +13,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.lang3.ObjectUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.nl.common.domain.query.PageQuery;
|
||||
import org.nl.common.exception.BadRequestException;
|
||||
@@ -1417,6 +1418,15 @@ public class OutBillServiceImpl extends ServiceImpl<IOStorInvMapper, IOStorInv>
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void taskFinish(SchBaseTask task) {
|
||||
List<GroupPlate> groupPlateList = mdPbGroupplateMapper.selectList(new LambdaQueryWrapper<GroupPlate>()
|
||||
.eq(GroupPlate::getStoragevehicle_code, task.getVehicle_code()).orderByDesc(GroupPlate::getCreate_name));
|
||||
if (ObjectUtils.isEmpty(groupPlateList)) {
|
||||
throw new BadRequestException("未找到该托盘的组盘信息,检查一下该托盘是否已出库或在操作日志中查询该托盘是否被删除组盘信息!");
|
||||
}
|
||||
List<MdMeMaterialbase> MdMeMaterialbaseList = mdMeMaterialbaseMapper.selectList(new LambdaQueryWrapper<MdMeMaterialbase>().eq(MdMeMaterialbase::getMaterial_id, groupPlateList.get(0).getMaterial_id()).orderByDesc(MdMeMaterialbase::getCreate_name));
|
||||
if (ObjectUtils.isEmpty(MdMeMaterialbaseList)) {
|
||||
throw new BadRequestException("未找到该托盘的物料信息,检查一下该托盘是否已出库或在操作日志中查询该物料是否被删除!");
|
||||
}
|
||||
String currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getCurrentNickName();
|
||||
String now = DateUtil.now();
|
||||
@@ -1517,13 +1527,9 @@ public class OutBillServiceImpl extends ServiceImpl<IOStorInvMapper, IOStorInv>
|
||||
jo.put("storagevehicle_code", task.getVehicle_code());
|
||||
jo.put("struct_name", task.getPoint_code2());
|
||||
jo.put("struct_code", task.getPoint_code2());
|
||||
GroupPlate groupPlate = mdPbGroupplateMapper.selectOne(new LambdaQueryWrapper<GroupPlate>()
|
||||
.eq(GroupPlate::getStatus, IOSEnum.GROUP_PLATE_STATUS.code("出库"))
|
||||
.eq(GroupPlate::getStoragevehicle_code, task.getVehicle_code()));
|
||||
MdMeMaterialbase mdMeMaterialbase = mdMeMaterialbaseMapper.selectOne(new LambdaQueryWrapper<MdMeMaterialbase>().eq(MdMeMaterialbase::getMaterial_id, groupPlate.getMaterial_id()));
|
||||
jo.put("material_name", mdMeMaterialbase.getMaterial_name());
|
||||
jo.put("material_code", mdMeMaterialbase.getMaterial_code());
|
||||
jo.put("qty", groupPlate.getQty());
|
||||
jo.put("material_name", MdMeMaterialbaseList.get(0).getMaterial_name());
|
||||
jo.put("material_code", MdMeMaterialbaseList.get(0).getMaterial_code());
|
||||
jo.put("qty", groupPlateList.get(0).getQty());
|
||||
List<JSONObject> tableData = new ArrayList<>();
|
||||
tableData.add(jo);
|
||||
towmsmsg.setTableData(tableData);
|
||||
|
||||
@@ -11,7 +11,7 @@ spring:
|
||||
freemarker:
|
||||
check-template-location: false
|
||||
profiles:
|
||||
active: dev
|
||||
active: prod
|
||||
# active: dev
|
||||
# active: prod
|
||||
jackson:
|
||||
|
||||
Reference in New Issue
Block a user