Compare commits
11 Commits
merge&mdm0
...
master_mer
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
af46f52351 | ||
|
|
73ec6042d5 | ||
|
|
a814c82387 | ||
|
|
6a8c77f922 | ||
|
|
e609e86eaa | ||
|
|
4e8bea3577 | ||
|
|
343c5c64bc | ||
|
|
8e2b2cae76 | ||
|
|
6db702b5cf | ||
|
|
094d78ae45 | ||
|
|
bf1ee590fb |
@@ -193,10 +193,10 @@ public class BstIvtStockingivtServiceImpl extends ServiceImpl<BstIvtStockingivtM
|
|||||||
if (ObjectUtil.isEmpty(vehicle_code)) {
|
if (ObjectUtil.isEmpty(vehicle_code)) {
|
||||||
throw new BadRequestException("托盘信息不能为空!");
|
throw new BadRequestException("托盘信息不能为空!");
|
||||||
}
|
}
|
||||||
if(!vehicle_code.contains("GX")){
|
if (!vehicle_code.contains("GX")) {
|
||||||
throw new BadRequestException("请扫描或输入正确的托盘码!");
|
throw new BadRequestException("请扫描或输入正确的托盘码!");
|
||||||
}
|
}
|
||||||
if(now_qty<=0 || now_qty>5){
|
if (now_qty <= 0 || now_qty > 5) {
|
||||||
throw new BadRequestException("数量只允许输入1-5");
|
throw new BadRequestException("数量只允许输入1-5");
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
@@ -213,11 +213,12 @@ public class BstIvtStockingivtServiceImpl extends ServiceImpl<BstIvtStockingivtM
|
|||||||
//获取当前纸管的高度
|
//获取当前纸管的高度
|
||||||
// 解析描述数组
|
// 解析描述数组
|
||||||
|
|
||||||
// String[] tubeArray = material_name.replaceAll("\\|[\\u4e00-\\u9fa5]+$", "").split("\\|");
|
// String[] tubeArray = material_name.replaceAll("\\|[\\u4e00-\\u9fa5]+$", "").split("\\|");
|
||||||
// int currLength = Integer.parseInt(tubeArray[tubeArray.length - 1]);
|
// int currLength = Integer.parseInt(tubeArray[tubeArray.length - 1]);
|
||||||
// todo 88549333 2026年5月19日19:55:53 这个地方获取纸管高度,会不会有FRP 管相关操作 需要进一步确认,因为两个类型的物料描述差异导致获取高度的方法不一致
|
// todo 88549333/zhouz 2026年5月19日19:55:53 这个地方获取纸管高度,会不会有FRP 管相关操作 需要进一步确认,因为两个类型的物料描述差异导致获取高度的方法不一致
|
||||||
String[] tubeArray = MdmDescriptionParseUtils.extractPaperTubeSpecs(material_name);
|
// String[] tubeArray = MdmDescriptionParseUtils.extractPaperTubeSpecs(material_name);
|
||||||
int currLength = Integer.parseInt(tubeArray[0]);
|
// int currLength = Integer.parseInt(tubeArray[1]);
|
||||||
|
int currLength = SlitterTaskUtil.getPaperLengthByCodeInt(material_name);
|
||||||
//校验高度差要大于50MM,否则不允许进行绑定
|
//校验高度差要大于50MM,否则不允许进行绑定
|
||||||
int num = Integer.parseInt(row_num);
|
int num = Integer.parseInt(row_num);
|
||||||
if (num == 1) {
|
if (num == 1) {
|
||||||
@@ -230,9 +231,8 @@ public class BstIvtStockingivtServiceImpl extends ServiceImpl<BstIvtStockingivtM
|
|||||||
String nextMaterialName = nextPaper.getMaterial_name();
|
String nextMaterialName = nextPaper.getMaterial_name();
|
||||||
// String[] nextArray = nextMaterialName.replaceAll("\\|[\\u4e00-\\u9fa5]+$", "").split("\\|");
|
// String[] nextArray = nextMaterialName.replaceAll("\\|[\\u4e00-\\u9fa5]+$", "").split("\\|");
|
||||||
// int nextLength = Integer.parseInt(nextArray[nextArray.length - 1]);
|
// int nextLength = Integer.parseInt(nextArray[nextArray.length - 1]);
|
||||||
// todo 88549333 2026年5月19日19:55:53 这个地方获取纸管高度,会不会有FRP 管相关操作 需要进一步确认,因为两个类型的物料描述差异导致获取高度的方法不一致
|
// todo 88549333/zhouz 2026年5月19日19:55:53 这个地方获取纸管高度,会不会有FRP 管相关操作 需要进一步确认,因为两个类型的物料描述差异导致获取高度的方法不一致
|
||||||
String[] nextArray = MdmDescriptionParseUtils.extractPaperTubeSpecs(nextMaterialName);
|
int nextLength = SlitterTaskUtil.getPaperLengthByCodeInt(nextMaterialName);
|
||||||
int nextLength = Integer.parseInt(nextArray[0]);
|
|
||||||
if (Math.abs(nextLength - currLength) <= 50 && !material_code.equals(nextPaper.getMaterial_code())) {
|
if (Math.abs(nextLength - currLength) <= 50 && !material_code.equals(nextPaper.getMaterial_code())) {
|
||||||
throw new BadRequestException("相邻排的纸管高度差要大于等于50MM!");
|
throw new BadRequestException("相邻排的纸管高度差要大于等于50MM!");
|
||||||
}
|
}
|
||||||
@@ -247,9 +247,9 @@ public class BstIvtStockingivtServiceImpl extends ServiceImpl<BstIvtStockingivtM
|
|||||||
String nextMaterialName = nextPaper.getMaterial_name();
|
String nextMaterialName = nextPaper.getMaterial_name();
|
||||||
// String[] nextArray = nextMaterialName.replaceAll("\\|[\\u4e00-\\u9fa5]+$", "").split("\\|");
|
// String[] nextArray = nextMaterialName.replaceAll("\\|[\\u4e00-\\u9fa5]+$", "").split("\\|");
|
||||||
// int nextLength = Integer.parseInt(nextArray[nextArray.length - 1]);
|
// int nextLength = Integer.parseInt(nextArray[nextArray.length - 1]);
|
||||||
// todo 88549333 2026年5月19日19:55:53 这个地方获取纸管高度,会不会有FRP 管相关操作 需要进一步确认,因为两个类型的物料描述差异导致获取高度的方法不一致
|
// todo 88549333/zhouz 2026年5月19日19:55:53 这个地方获取纸管高度,会不会有FRP 管相关操作 需要进一步确认,因为两个类型的物料描述差异导致获取高度的方法不一致
|
||||||
String[] nextArray = MdmDescriptionParseUtils.extractPaperTubeSpecs(nextMaterialName);
|
//String[] nextArray = MdmDescriptionParseUtils.extractPaperTubeSpecs(nextMaterialName);
|
||||||
int nextLength = Integer.parseInt(nextArray[0]);
|
int nextLength = SlitterTaskUtil.getPaperLengthByCodeInt(nextMaterialName);
|
||||||
if (Math.abs(nextLength - currLength) <= 50 && !material_code.equals(nextPaper.getMaterial_code())) {
|
if (Math.abs(nextLength - currLength) <= 50 && !material_code.equals(nextPaper.getMaterial_code())) {
|
||||||
throw new BadRequestException("相邻排的纸管高度差要大于等于50MM!");
|
throw new BadRequestException("相邻排的纸管高度差要大于等于50MM!");
|
||||||
}
|
}
|
||||||
@@ -265,8 +265,8 @@ public class BstIvtStockingivtServiceImpl extends ServiceImpl<BstIvtStockingivtM
|
|||||||
// String[] preArray = preMaterialName.replaceAll("\\|[\\u4e00-\\u9fa5]+$", "").split("\\|");
|
// String[] preArray = preMaterialName.replaceAll("\\|[\\u4e00-\\u9fa5]+$", "").split("\\|");
|
||||||
// int preLength = Integer.parseInt(preArray[preArray.length - 1]);
|
// int preLength = Integer.parseInt(preArray[preArray.length - 1]);
|
||||||
// todo 88549333 2026年5月19日19:55:53 这个地方获取纸管高度,会不会有FRP 管相关操作 需要进一步确认,因为两个类型的物料描述差异导致获取高度的方法不一致
|
// todo 88549333 2026年5月19日19:55:53 这个地方获取纸管高度,会不会有FRP 管相关操作 需要进一步确认,因为两个类型的物料描述差异导致获取高度的方法不一致
|
||||||
String[] preArray = MdmDescriptionParseUtils.extractPaperTubeSpecs(preMaterialName);
|
//String[] preArray = MdmDescriptionParseUtils.extractPaperTubeSpecs(preMaterialName);
|
||||||
int preLength = Integer.parseInt(preArray[0]);
|
int preLength = SlitterTaskUtil.getPaperLengthByCodeInt(preMaterialName);
|
||||||
if (Math.abs(preLength - currLength) <= 50 && !material_code.equals(prePaper.getMaterial_code())) {
|
if (Math.abs(preLength - currLength) <= 50 && !material_code.equals(prePaper.getMaterial_code())) {
|
||||||
throw new BadRequestException("相邻排的纸管高度差要大于等于50MM!");
|
throw new BadRequestException("相邻排的纸管高度差要大于等于50MM!");
|
||||||
}
|
}
|
||||||
@@ -389,6 +389,7 @@ public class BstIvtStockingivtServiceImpl extends ServiceImpl<BstIvtStockingivtM
|
|||||||
public List<BhTubePointDto> getNeedPaperTubePoint(String pointType, String tube, String location) {
|
public List<BhTubePointDto> getNeedPaperTubePoint(String pointType, String tube, String location) {
|
||||||
return bstIvtStockingivtMapper.getNeedPaperTubePoint(pointType, tube, location);
|
return bstIvtStockingivtMapper.getNeedPaperTubePoint(pointType, tube, location);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<BhTubePointDto> getNeedPaperTubesPoint(String pointType, List<String> tubes, String location) {
|
public List<BhTubePointDto> getNeedPaperTubesPoint(String pointType, List<String> tubes, String location) {
|
||||||
return bstIvtStockingivtMapper.getNeedPaperTubesPoint(pointType, tubes, location);
|
return bstIvtStockingivtMapper.getNeedPaperTubesPoint(pointType, tubes, location);
|
||||||
@@ -458,11 +459,12 @@ public class BstIvtStockingivtServiceImpl extends ServiceImpl<BstIvtStockingivtM
|
|||||||
.orderByAsc(MdPbPapervehicle::getRow_num));
|
.orderByAsc(MdPbPapervehicle::getRow_num));
|
||||||
return papers;
|
return papers;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public PdmBiOrderbominfo showBom2(Map param){
|
public PdmBiOrderbominfo showBom2(Map param) {
|
||||||
String mfg_order_name = String.valueOf(param.get("mfg_order_name"));
|
String mfg_order_name = String.valueOf(param.get("mfg_order_name"));
|
||||||
LambdaQueryWrapper<PdmBiOrderbominfo> lam = new LambdaQueryWrapper<>();
|
LambdaQueryWrapper<PdmBiOrderbominfo> lam = new LambdaQueryWrapper<>();
|
||||||
lam.eq(PdmBiOrderbominfo::getMfgOrder,mfg_order_name);
|
lam.eq(PdmBiOrderbominfo::getMfgOrder, mfg_order_name);
|
||||||
PdmBiOrderbominfo order = pdmBiOrderbominfoService.getOne(lam);
|
PdmBiOrderbominfo order = pdmBiOrderbominfoService.getOne(lam);
|
||||||
return order;
|
return order;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -112,7 +112,7 @@ public class PdmBiSlittingproductionplan implements Serializable {
|
|||||||
/** 修改时间 */
|
/** 修改时间 */
|
||||||
private String update_time;
|
private String update_time;
|
||||||
|
|
||||||
/** 部门ID */
|
/** 部门ID(用于判断是否搬运过到穿拔轴区) */
|
||||||
private String sysdeptid;
|
private String sysdeptid;
|
||||||
|
|
||||||
/** 公司ID */
|
/** 公司ID */
|
||||||
|
|||||||
@@ -153,7 +153,7 @@ public class ZxDjwTask extends AbstractAcsTask {
|
|||||||
PdmBiSubpackagerelation pdmBiSubpackagerelation = subpackageRelationService
|
PdmBiSubpackagerelation pdmBiSubpackagerelation = subpackageRelationService
|
||||||
.getOne(new LambdaUpdateWrapper<PdmBiSubpackagerelation>().eq(PdmBiSubpackagerelation::getContainer_name, schBaseTask.getVehicle_code()), false);
|
.getOne(new LambdaUpdateWrapper<PdmBiSubpackagerelation>().eq(PdmBiSubpackagerelation::getContainer_name, schBaseTask.getVehicle_code()), false);
|
||||||
if (!pdmBiSubpackagerelation.getStatus().equals(IOSEnum.IS_NOTANDYES.code("否"))){
|
if (!pdmBiSubpackagerelation.getStatus().equals(IOSEnum.IS_NOTANDYES.code("否"))){
|
||||||
throw new BadRequestException("该子卷对应状态为["+pdmBiSubpackagerelation.getStatus()+"],不为生成状态!)");
|
throw new BadRequestException("该子卷对应状态为["+pdmBiSubpackagerelation.getStatus()+"],不为生成状态,不允许进行状态变更!)");
|
||||||
}
|
}
|
||||||
pdmBiSubpackagerelation.setStatus(IOSEnum.IS_NOTANDYES.code("是"));
|
pdmBiSubpackagerelation.setStatus(IOSEnum.IS_NOTANDYES.code("是"));
|
||||||
subpackageRelationService.updateById(pdmBiSubpackagerelation);
|
subpackageRelationService.updateById(pdmBiSubpackagerelation);
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ import java.util.stream.Collectors;
|
|||||||
@Slf4j
|
@Slf4j
|
||||||
@Component
|
@Component
|
||||||
@RequiredArgsConstructor
|
@RequiredArgsConstructor
|
||||||
public class AutoSendVehicleToKzj extends Prun{
|
public class AutoSendVehicleToKzj extends Prun {
|
||||||
|
|
||||||
private final String THIS_CLASS = AutoSendVehicleToKzj.class.getName();
|
private final String THIS_CLASS = AutoSendVehicleToKzj.class.getName();
|
||||||
@Resource
|
@Resource
|
||||||
@@ -63,7 +63,7 @@ public class AutoSendVehicleToKzj extends Prun{
|
|||||||
try {
|
try {
|
||||||
this.toKzjHcw();
|
this.toKzjHcw();
|
||||||
this.sendVehicleToDjqOrGzq(IOSEnum.IS_NOTANDYES.code("否"), null);
|
this.sendVehicleToDjqOrGzq(IOSEnum.IS_NOTANDYES.code("否"), null);
|
||||||
}catch (Exception ex){
|
} catch (Exception ex) {
|
||||||
log.error(ex.getMessage());
|
log.error(ex.getMessage());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -82,65 +82,63 @@ public class AutoSendVehicleToKzj extends Prun{
|
|||||||
log.info("待检区或管制区->空载具缓存位补空任务正在创建被锁住。");
|
log.info("待检区或管制区->空载具缓存位补空任务正在创建被锁住。");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
List<String> taskTypes = new ArrayList(Arrays.asList(PackageInfoIvtEnum.TASK_TYPE.code("补空(待检区->空载具缓存位)")));
|
List<String> taskTypes = new ArrayList(Arrays.asList(PackageInfoIvtEnum.TASK_TYPE.code("补空(待检区->空载具缓存位)")));
|
||||||
List<SchBaseTask> existTask = this.taskService.getExistTasks(taskTypes);
|
List<SchBaseTask> existTask = this.taskService.getExistTasks(taskTypes);
|
||||||
if (existTask.size() <= 1) {
|
if (existTask.size() <= 1) {
|
||||||
List<BstIvtPackageinfoivt> empPoints = this.packageinfoivtService.selectEmpPoints(PackageInfoIvtEnum.POINT_STATUS.code("空载具缓存位"), PackageInfoIvtEnum.IVT_STATUS.code("空"));
|
List<BstIvtPackageinfoivt> empPoints = this.packageinfoivtService.selectEmpPoints(PackageInfoIvtEnum.POINT_STATUS.code("空载具缓存位"), PackageInfoIvtEnum.IVT_STATUS.code("空"));
|
||||||
List<BstIvtPackageinfoivt> vehiclePoints = this.packageinfoivtService.selectEmpPoints(PackageInfoIvtEnum.POINT_STATUS.code("待检区"), PackageInfoIvtEnum.IVT_STATUS.code("空载具"));
|
List<BstIvtPackageinfoivt> vehiclePoints = this.packageinfoivtService.selectEmpPoints(PackageInfoIvtEnum.POINT_STATUS.code("装箱区"), PackageInfoIvtEnum.IVT_STATUS.code("空载具"));
|
||||||
//如果待检区没有可用的空载具
|
//如果待检区没有可用的空载具
|
||||||
if (CollectionUtils.isEmpty(vehiclePoints)){
|
if (CollectionUtils.isEmpty(vehiclePoints)) {
|
||||||
List<SchBaseTask> taskList = taskService.list(new LambdaQueryWrapper<SchBaseTask>()
|
/*List<SchBaseTask> taskList = taskService.list(new LambdaQueryWrapper<SchBaseTask>()
|
||||||
.lt(SchBaseTask::getTask_status, TaskStatusEnum.FINISHED.getCode())
|
.lt(SchBaseTask::getTask_status, TaskStatusEnum.FINISHED.getCode())
|
||||||
.eq(SchBaseTask::getIs_delete, IOSEnum.IS_NOTANDYES.code("否"))
|
.eq(SchBaseTask::getIs_delete, IOSEnum.IS_NOTANDYES.code("否"))
|
||||||
.eq(SchBaseTask::getTask_type, "010909"));
|
.eq(SchBaseTask::getTask_type, "010909"));*/
|
||||||
if (ObjectUtils.isEmpty(taskList)){
|
vehiclePoints = packageinfoivtService
|
||||||
vehiclePoints = packageinfoivtService
|
.selectEmpPoints(PackageInfoIvtEnum.POINT_STATUS.code("待检区"), PackageInfoIvtEnum.IVT_STATUS.code("空载具"));
|
||||||
.selectEmpPoints(PackageInfoIvtEnum.POINT_STATUS.code("装箱区"), PackageInfoIvtEnum.IVT_STATUS.code("空载具"));
|
}
|
||||||
}
|
if (!CollectionUtils.isEmpty(empPoints) && !CollectionUtils.isEmpty(vehiclePoints) && existTask.size() < empPoints.size()) {
|
||||||
}
|
//增加空洞判断
|
||||||
if (!CollectionUtils.isEmpty(empPoints) && !CollectionUtils.isEmpty(vehiclePoints) && existTask.size() < empPoints.size()) {
|
//车 04 05 06
|
||||||
//增加空洞判断
|
//☒☒口 ☒口☒ ☒口口:
|
||||||
//车 04 05 06
|
if (existTask.size() == 0 && empPoints.size() > 1 && vehiclePoints.size() > 1) {
|
||||||
//☒☒口 ☒口☒ ☒口口:
|
for (int i = 0; i < 2; i++) {
|
||||||
if (existTask.size()==0 && empPoints.size() > 1 && vehiclePoints.size() > 1) {
|
BstIvtPackageinfoivt disPoint = empPoints.get(i);
|
||||||
for (int i = 0; i < 2; i++) {
|
|
||||||
BstIvtPackageinfoivt disPoint = empPoints.get(i);
|
|
||||||
int count = packageinfoivtService.count(new QueryWrapper<BstIvtPackageinfoivt>()
|
|
||||||
.lt("sort_seq", disPoint.getSort_seq())
|
|
||||||
.eq("point_status", PackageInfoIvtEnum.POINT_STATUS.code("空载具缓存位"))
|
|
||||||
.eq("ivt_status", PackageInfoIvtEnum.IVT_STATUS.code("空载具")));
|
|
||||||
if (count>0){
|
|
||||||
log.warn("当前点位存在空洞的情况"+disPoint.getPoint_code());
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
JSONObject task = new JSONObject();
|
|
||||||
task.put("task_type", PackageInfoIvtEnum.TASK_TYPE.code("补空(待检区->空载具缓存位)"));
|
|
||||||
task.put("vehicle_code2", PackageInfoIvtEnum.AGV_ACTION_TYPE.code("放货二次分配"));
|
|
||||||
task.put("point_code1", vehiclePoints.get(i).getPoint_code());
|
|
||||||
task.put("point_code2", this.packageinfoivtService.getWaitPoint(disPoint.getBlock(), disPoint.getWait_point_type()));
|
|
||||||
task.put("point_code3", disPoint.getPoint_code());
|
|
||||||
this.djqToKzjhcwTask.createTask(task);
|
|
||||||
}
|
|
||||||
}else {
|
|
||||||
BstIvtPackageinfoivt disPoint = empPoints.get(0);
|
|
||||||
int count = packageinfoivtService.count(new QueryWrapper<BstIvtPackageinfoivt>()
|
int count = packageinfoivtService.count(new QueryWrapper<BstIvtPackageinfoivt>()
|
||||||
.lt("sort_seq", disPoint.getSort_seq())
|
.lt("sort_seq", disPoint.getSort_seq())
|
||||||
.eq("point_status", PackageInfoIvtEnum.POINT_STATUS.code("空载具缓存位"))
|
.eq("point_status", PackageInfoIvtEnum.POINT_STATUS.code("空载具缓存位"))
|
||||||
.eq("ivt_status", PackageInfoIvtEnum.IVT_STATUS.code("空载具")));
|
.eq("ivt_status", PackageInfoIvtEnum.IVT_STATUS.code("空载具")));
|
||||||
if (count>0){
|
if (count > 0) {
|
||||||
log.warn("当前点位存在空洞的情况"+disPoint.getPoint_code());
|
log.warn("当前点位存在空洞的情况" + disPoint.getPoint_code());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
JSONObject task = new JSONObject();
|
JSONObject task = new JSONObject();
|
||||||
task.put("task_type", PackageInfoIvtEnum.TASK_TYPE.code("补空(待检区->空载具缓存位)"));
|
task.put("task_type", PackageInfoIvtEnum.TASK_TYPE.code("补空(待检区->空载具缓存位)"));
|
||||||
task.put("vehicle_code2", PackageInfoIvtEnum.AGV_ACTION_TYPE.code("放货二次分配"));
|
task.put("vehicle_code2", PackageInfoIvtEnum.AGV_ACTION_TYPE.code("放货二次分配"));
|
||||||
task.put("point_code1", vehiclePoints.get(0).getPoint_code());
|
task.put("point_code1", vehiclePoints.get(i).getPoint_code());
|
||||||
task.put("point_code2", this.packageinfoivtService.getWaitPoint(disPoint.getBlock(), disPoint.getWait_point_type()));
|
task.put("point_code2", this.packageinfoivtService.getWaitPoint(disPoint.getBlock(), disPoint.getWait_point_type()));
|
||||||
task.put("point_code3", disPoint.getPoint_code());
|
task.put("point_code3", disPoint.getPoint_code());
|
||||||
this.djqToKzjhcwTask.createTask(task);
|
this.djqToKzjhcwTask.createTask(task);
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
BstIvtPackageinfoivt disPoint = empPoints.get(0);
|
||||||
|
int count = packageinfoivtService.count(new QueryWrapper<BstIvtPackageinfoivt>()
|
||||||
|
.lt("sort_seq", disPoint.getSort_seq())
|
||||||
|
.eq("point_status", PackageInfoIvtEnum.POINT_STATUS.code("空载具缓存位"))
|
||||||
|
.eq("ivt_status", PackageInfoIvtEnum.IVT_STATUS.code("空载具")));
|
||||||
|
if (count > 0) {
|
||||||
|
log.warn("当前点位存在空洞的情况" + disPoint.getPoint_code());
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
JSONObject task = new JSONObject();
|
||||||
|
task.put("task_type", PackageInfoIvtEnum.TASK_TYPE.code("补空(待检区->空载具缓存位)"));
|
||||||
|
task.put("vehicle_code2", PackageInfoIvtEnum.AGV_ACTION_TYPE.code("放货二次分配"));
|
||||||
|
task.put("point_code1", vehiclePoints.get(0).getPoint_code());
|
||||||
|
task.put("point_code2", this.packageinfoivtService.getWaitPoint(disPoint.getBlock(), disPoint.getWait_point_type()));
|
||||||
|
task.put("point_code3", disPoint.getPoint_code());
|
||||||
|
this.djqToKzjhcwTask.createTask(task);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
} finally {
|
} finally {
|
||||||
if (lock.isLocked() && lock.isHeldByCurrentThread()) {
|
if (lock.isLocked() && lock.isHeldByCurrentThread()) {
|
||||||
lock.unlock();
|
lock.unlock();
|
||||||
@@ -196,8 +194,8 @@ public class AutoSendVehicleToKzj extends Prun{
|
|||||||
task.put("point_code2", djqEmpList.get(0).getPoint_code());
|
task.put("point_code2", djqEmpList.get(0).getPoint_code());
|
||||||
try {
|
try {
|
||||||
sendDjqKzjTask.createTask(task);
|
sendDjqKzjTask.createTask(task);
|
||||||
}catch (Exception ex){
|
} catch (Exception ex) {
|
||||||
log.error(THIS_CLASS+"任务创建失败"+ex.getMessage());
|
log.error(THIS_CLASS + "任务创建失败" + ex.getMessage());
|
||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
@@ -211,8 +209,6 @@ public class AutoSendVehicleToKzj extends Prun{
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private void getPointCode(JSONObject task, String taskType) {
|
private void getPointCode(JSONObject task, String taskType) {
|
||||||
List<BstIvtPackageinfoivt> packageList;
|
List<BstIvtPackageinfoivt> packageList;
|
||||||
if (taskType.equals(PackageInfoIvtEnum.TASK_TYPE.code("补空(待检区->空载具缓存位)"))) {
|
if (taskType.equals(PackageInfoIvtEnum.TASK_TYPE.code("补空(待检区->空载具缓存位)"))) {
|
||||||
|
|||||||
@@ -1,6 +1,8 @@
|
|||||||
package org.nl.b_lms.sch.tasks.slitter;
|
package org.nl.b_lms.sch.tasks.slitter;
|
||||||
|
|
||||||
import cn.hutool.core.date.DateUtil;
|
import cn.hutool.core.date.DateUtil;
|
||||||
|
import org.nl.b_lms.pdm.bi.slittingproductionplan.service.IPdmBiSlittingproductionplanService;
|
||||||
|
import org.nl.b_lms.pdm.bi.slittingproductionplan.service.dao.PdmBiSlittingproductionplan;
|
||||||
import org.nl.common.utils.IdUtil;
|
import org.nl.common.utils.IdUtil;
|
||||||
import cn.hutool.core.util.ObjectUtil;
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
import cn.hutool.core.util.StrUtil;
|
import cn.hutool.core.util.StrUtil;
|
||||||
@@ -25,6 +27,8 @@ import org.springframework.transaction.annotation.Transactional;
|
|||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
import java.util.stream.Stream;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Author: lyd
|
* @Author: lyd
|
||||||
@@ -39,6 +43,9 @@ public class SlitterDownAgvTask extends AbstractAcsTask {
|
|||||||
private IschBaseTaskService taskService;
|
private IschBaseTaskService taskService;
|
||||||
@Autowired
|
@Autowired
|
||||||
private IBstIvtCutpointivtService bcutpointivtService;
|
private IBstIvtCutpointivtService bcutpointivtService;
|
||||||
|
@Autowired
|
||||||
|
private IPdmBiSlittingproductionplanService slittingproductionplanService;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<AcsTaskDto> addTask() {
|
public List<AcsTaskDto> addTask() {
|
||||||
/*
|
/*
|
||||||
@@ -113,6 +120,15 @@ public class SlitterDownAgvTask extends AbstractAcsTask {
|
|||||||
BstIvtCutpointivt endPointObj = bcutpointivtService.getPintByAgvCode(endPoint, false);
|
BstIvtCutpointivt endPointObj = bcutpointivtService.getPintByAgvCode(endPoint, false);
|
||||||
TaskUtils.pointMaintenanceInventory(task, endPointObj, "3");
|
TaskUtils.pointMaintenanceInventory(task, endPointObj, "3");
|
||||||
bcutpointivtService.updateById(endPointObj);
|
bcutpointivtService.updateById(endPointObj);
|
||||||
|
//更新子卷已经搬运至拔轴区
|
||||||
|
// 将子卷信息存到任务中
|
||||||
|
List<String> qzzNos = Stream.of(task.getVehicle_code(), task.getVehicle_code2()).filter(ObjectUtil::isNotEmpty).collect(Collectors.toList());
|
||||||
|
List<PdmBiSlittingproductionplan> plans = slittingproductionplanService.getByQzzNos(qzzNos);
|
||||||
|
plans.forEach(plan -> {
|
||||||
|
plan.setSysdeptid("1");
|
||||||
|
slittingproductionplanService.update(plan);
|
||||||
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
// 取消
|
// 取消
|
||||||
if (status.equals(IOSEnum.IS_NOTANDYES.code("否"))) {
|
if (status.equals(IOSEnum.IS_NOTANDYES.code("否"))) {
|
||||||
@@ -174,6 +190,7 @@ public class SlitterDownAgvTask extends AbstractAcsTask {
|
|||||||
JSONObject taskObj = WQLObject.getWQLObject("SCH_BASE_Task").query("task_id = '" + task_id + "'").uniqueResult(0);
|
JSONObject taskObj = WQLObject.getWQLObject("SCH_BASE_Task").query("task_id = '" + task_id + "'").uniqueResult(0);
|
||||||
this.updateTaskStatus(taskObj, "0");
|
this.updateTaskStatus(taskObj, "0");
|
||||||
}
|
}
|
||||||
|
|
||||||
//判断该点位是否存在未完成的任务
|
//判断该点位是否存在未完成的任务
|
||||||
public boolean isSingleTask(String point_code) {
|
public boolean isSingleTask(String point_code) {
|
||||||
JSONObject task1 = WQLObject.getWQLObject("SCH_BASE_Task").query("point_code1 = '" + point_code + "' AND task_status < '07' AND is_delete = '0'").uniqueResult(0);
|
JSONObject task1 = WQLObject.getWQLObject("SCH_BASE_Task").query("point_code1 = '" + point_code + "' AND task_status < '07' AND is_delete = '0'").uniqueResult(0);
|
||||||
|
|||||||
@@ -159,7 +159,11 @@ public class SlitterDownTrussTask extends AbstractAcsTask {
|
|||||||
+ TaskUtils.getDateTime("yyMMddHHmmss") + "-"
|
+ TaskUtils.getDateTime("yyMMddHHmmss") + "-"
|
||||||
+ upDemoPlan.getUp_or_down();
|
+ upDemoPlan.getUp_or_down();
|
||||||
for (PdmBiSlittingproductionplan deviceUpPlan : deviceUpPlans) {
|
for (PdmBiSlittingproductionplan deviceUpPlan : deviceUpPlans) {
|
||||||
deviceUpPlan.setQzzno(qzzNO);
|
if (StrUtil.isEmpty(deviceUpPlan.getQzzno())){
|
||||||
|
deviceUpPlan.setQzzno(qzzNO);
|
||||||
|
}else {
|
||||||
|
log.info("当前子卷已经绑定了气胀轴:{}",deviceUpPlan.getQzzno());
|
||||||
|
}
|
||||||
deviceUpPlan.setStatus("09");
|
deviceUpPlan.setStatus("09");
|
||||||
deviceUpPlan.setEnd_time(DateUtil.now());
|
deviceUpPlan.setEnd_time(DateUtil.now());
|
||||||
TaskUtils.updateOptMessageBySlitterPlan(deviceUpPlan);
|
TaskUtils.updateOptMessageBySlitterPlan(deviceUpPlan);
|
||||||
@@ -175,7 +179,11 @@ public class SlitterDownTrussTask extends AbstractAcsTask {
|
|||||||
+ TaskUtils.getDateTime("yyMMddHHmmss") + "-"
|
+ TaskUtils.getDateTime("yyMMddHHmmss") + "-"
|
||||||
+ downDemoPlan.getUp_or_down();
|
+ downDemoPlan.getUp_or_down();
|
||||||
for (PdmBiSlittingproductionplan deviceDownPlan : deviceDownPlans) {
|
for (PdmBiSlittingproductionplan deviceDownPlan : deviceDownPlans) {
|
||||||
deviceDownPlan.setQzzno(qzzNO);
|
if (StrUtil.isEmpty(deviceDownPlan.getQzzno())){
|
||||||
|
deviceDownPlan.setQzzno(qzzNO);
|
||||||
|
}else {
|
||||||
|
log.info("当前子卷已经绑定了气胀轴:{}",deviceDownPlan.getQzzno());
|
||||||
|
}
|
||||||
deviceDownPlan.setStatus("09");
|
deviceDownPlan.setStatus("09");
|
||||||
deviceDownPlan.setEnd_time(DateUtil.now());
|
deviceDownPlan.setEnd_time(DateUtil.now());
|
||||||
TaskUtils.updateOptMessageBySlitterPlan(deviceDownPlan);
|
TaskUtils.updateOptMessageBySlitterPlan(deviceDownPlan);
|
||||||
|
|||||||
@@ -1363,6 +1363,12 @@ public class SlitterServiceImpl implements SlitterService {
|
|||||||
if (collect.size() == 0) {
|
if (collect.size() == 0) {
|
||||||
throw new BadRequestException("操作失败,点位[" + pointCode + "]未查到子卷分切计划,请先绑定子卷库存!");
|
throw new BadRequestException("操作失败,点位[" + pointCode + "]未查到子卷分切计划,请先绑定子卷库存!");
|
||||||
}
|
}
|
||||||
|
//校验对应分切计划是否已经创建过任务搬运到拔轴区进行拔轴
|
||||||
|
List<PdmBiSlittingproductionplan> error_plans = plans.stream().filter(plan -> "1".equals(plan.getSysdeptid())).collect(Collectors.toList());
|
||||||
|
if (error_plans.size() > 0){
|
||||||
|
throw new BadRequestException("操作失败,子卷【"+error_plans.get(0).getContainer_name()+"】已经创建过任务搬运至拔轴区,请核对子卷号是否正确!");
|
||||||
|
}
|
||||||
|
|
||||||
taskParam.put("containers", collect);
|
taskParam.put("containers", collect);
|
||||||
} else {
|
} else {
|
||||||
throw new BadRequestException("操作失败,点位[" + pointCode + "]无气胀轴信息,请先绑定子卷库存!");
|
throw new BadRequestException("操作失败,点位[" + pointCode + "]无气胀轴信息,请先绑定子卷库存!");
|
||||||
@@ -3153,9 +3159,15 @@ public class SlitterServiceImpl implements SlitterService {
|
|||||||
throw new BadRequestException("计划未找到,请确保MES已推送。");
|
throw new BadRequestException("计划未找到,请确保MES已推送。");
|
||||||
}
|
}
|
||||||
JSONObject tube = new JSONObject();
|
JSONObject tube = new JSONObject();
|
||||||
String[] split = SlitterTaskUtil.getTubeConvertInfo(plan).split("\\*");
|
String paper_model = "";
|
||||||
tube.put("bh", split[3]);
|
if (plan.getPaper_tube_or_FRP().equals(SlitterConstant.SLITTER_TYPE_PAPER)) {
|
||||||
tube.put("length", SlitterTaskUtil.getPaperLength(plan));
|
paper_model = plan.getPaper_tube_model();
|
||||||
|
} else {
|
||||||
|
paper_model = plan.getFRP_model();
|
||||||
|
}
|
||||||
|
String[] split = MdmDescriptionParseUtils.extractCommonTubeInfo(paper_model);
|
||||||
|
tube.put("bh", split[1]);
|
||||||
|
tube.put("length", split[0]);
|
||||||
JSONObject res = new JSONObject();
|
JSONObject res = new JSONObject();
|
||||||
res.put("status", HttpStatus.HTTP_OK);
|
res.put("status", HttpStatus.HTTP_OK);
|
||||||
res.put("data", tube);
|
res.put("data", tube);
|
||||||
|
|||||||
@@ -4,6 +4,9 @@ package org.nl.b_lms.sch.tasks.slitter.util;
|
|||||||
import cn.hutool.core.util.NumberUtil;
|
import cn.hutool.core.util.NumberUtil;
|
||||||
import cn.hutool.core.util.ObjectUtil;
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.nl.modules.common.exception.BadRequestException;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author ManMan.Yang
|
* @author ManMan.Yang
|
||||||
@@ -27,14 +30,16 @@ public class MdmDescriptionParseUtils {
|
|||||||
// ==================================================
|
// ==================================================
|
||||||
//====通用公共方法 用来解析纸管或者frp管尺寸 ==============
|
//====通用公共方法 用来解析纸管或者frp管尺寸 ==============
|
||||||
//===================================================
|
//===================================================
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 智能提取管件尺寸(自动识别纸管或FRP管)
|
* 智能提取管件尺寸(自动识别纸管或FRP管)
|
||||||
|
*
|
||||||
* @param tubeModel 管件型号描述
|
* @param tubeModel 管件型号描述
|
||||||
* - 纸管示例: 平包树脂管\3''\500mm*15mm\
|
* - 纸管示例: 平包树脂管\3''\500mm*15mm\
|
||||||
* - FRP管示例: FRP管\玻璃纤维+环氧树脂\Φ152.4mm*1100mm*15/20mm\
|
* - FRP管示例: FRP管\玻璃纤维+环氧树脂\Φ152.4mm*1100mm*15/20mm\
|
||||||
* @return 尺寸字符串(英寸)
|
* @return 尺寸字符串(英寸)
|
||||||
* - 纸管返回: "3.0"
|
* - 纸管返回: "3.0"
|
||||||
* - FRP管返回: "6.0" (152.4mm / 25.4)
|
* - FRP管返回: "6.0" (152.4mm / 25.4)
|
||||||
*/
|
*/
|
||||||
public static String extractCommonTubeSize(String tubeModel) {
|
public static String extractCommonTubeSize(String tubeModel) {
|
||||||
if (ObjectUtil.isEmpty(tubeModel)) {
|
if (ObjectUtil.isEmpty(tubeModel)) {
|
||||||
@@ -56,12 +61,49 @@ public class MdmDescriptionParseUtils {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 智能提取管件壁厚*长度(自动识别纸管或FRP管)
|
||||||
|
*
|
||||||
|
* @param tubeModel 管件型号描述
|
||||||
|
* - 纸管示例: 平包树脂管\3''\500mm*15mm\
|
||||||
|
* - FRP管示例: FRP管\玻璃纤维+环氧树脂\Φ152.4mm*1100mm*15/20mm\
|
||||||
|
* @return 尺寸字符串(英寸)
|
||||||
|
* - 纸管返回: "3.0"
|
||||||
|
* - FRP管返回: "6.0" (152.4mm / 25.4)
|
||||||
|
*/
|
||||||
|
public static String[] extractCommonTubeInfo(String tubeModel) {
|
||||||
|
if (ObjectUtil.isEmpty(tubeModel)) {
|
||||||
|
return new String[]{};
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
// 判断是纸管还是FRP管
|
||||||
|
if (tubeModel.contains("FRP")) {
|
||||||
|
// FRP管:转换为英寸
|
||||||
|
String[] a = Arrays.stream(parseFRPSizeInfo(tubeModel)).skip(1).toArray(String[]::new);
|
||||||
|
return a;
|
||||||
|
} else {
|
||||||
|
// 纸管:直接提取英寸值
|
||||||
|
String[] a = extractPaperTubeSpecs(tubeModel);
|
||||||
|
return a;
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.warn("智能提取管件尺寸失败: {}", tubeModel, e);
|
||||||
|
return new String[]{};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void main(String[] args) {
|
||||||
|
System.out.println(extractCommonTubeInfo("平包树脂管\\6''\\610mm*15mm\\"));
|
||||||
|
}
|
||||||
|
|
||||||
// ==================================================
|
// ==================================================
|
||||||
//==================== FRP管解析方法 ===================
|
//==================== FRP管解析方法 ===================
|
||||||
//===================================================
|
//===================================================
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 解析尺寸字符串,提取外径、长度、壁厚
|
* 解析尺寸字符串,提取外径、长度、壁厚
|
||||||
|
*
|
||||||
* @param sizeInfo 尺寸信息,如 Φ152.4mm*1100mm*15/20mm
|
* @param sizeInfo 尺寸信息,如 Φ152.4mm*1100mm*15/20mm
|
||||||
* @return String数组 [外径, 长度, 壁厚],如 ["152.4", "1100", "15/20"]
|
* @return String数组 [外径, 长度, 壁厚],如 ["152.4", "1100", "15/20"]
|
||||||
*/
|
*/
|
||||||
@@ -91,6 +133,7 @@ public class MdmDescriptionParseUtils {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 清理尺寸值中的特殊字符
|
* 清理尺寸值中的特殊字符
|
||||||
|
*
|
||||||
* @param value 原始值,如 Φ152.4mm、1100mm、15/20mm
|
* @param value 原始值,如 Φ152.4mm、1100mm、15/20mm
|
||||||
* @return 清理后的纯数值,如 152.4、1100、15/20
|
* @return 清理后的纯数值,如 152.4、1100、15/20
|
||||||
*/
|
*/
|
||||||
@@ -105,10 +148,13 @@ public class MdmDescriptionParseUtils {
|
|||||||
.replace("mm", "")
|
.replace("mm", "")
|
||||||
.replace("MM", "")
|
.replace("MM", "")
|
||||||
.replace("''", "")
|
.replace("''", "")
|
||||||
|
.replace("\\","")
|
||||||
.trim();
|
.trim();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 从 FRP 管型号中提取长度(mm)
|
* 从 FRP 管型号中提取长度(mm)
|
||||||
|
*
|
||||||
* @param frpModel FRP管型号描述,如 FRP管\玻璃纤维+环氧树脂\Φ152.4mm*1100mm*15/20mm\
|
* @param frpModel FRP管型号描述,如 FRP管\玻璃纤维+环氧树脂\Φ152.4mm*1100mm*15/20mm\
|
||||||
* @return 长度字符串,如 "1100"
|
* @return 长度字符串,如 "1100"
|
||||||
*/
|
*/
|
||||||
@@ -126,8 +172,29 @@ public class MdmDescriptionParseUtils {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 从纸管管型号中提取长度(mm)
|
||||||
|
*
|
||||||
|
* @param frpModel FRP管型号描述,如 FRP管\玻璃纤维+环氧树脂\Φ152.4mm*1100mm*15/20mm\
|
||||||
|
* @return 长度字符串,如 "1100"
|
||||||
|
*/
|
||||||
|
public static String extractPaperLength(String frpModel) {
|
||||||
|
if (ObjectUtil.isEmpty(frpModel)) {
|
||||||
|
return "0";
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
String[] sizeParams = extractPaperTubeSpecs(frpModel);
|
||||||
|
return sizeParams[0]; // 返回长度
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.warn("提取FRP管长度失败: {}", frpModel, e);
|
||||||
|
return "0";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 从 FRP 管型号中提取壁厚
|
* 从 FRP 管型号中提取壁厚
|
||||||
|
*
|
||||||
* @param frpModel FRP管型号描述,如 FRP管\玻璃纤维+环氧树脂\Φ152.4mm*1100mm*15/20mm\
|
* @param frpModel FRP管型号描述,如 FRP管\玻璃纤维+环氧树脂\Φ152.4mm*1100mm*15/20mm\
|
||||||
* @return 壁厚字符串,单壁厚如 "15",双壁厚如 "15/20"
|
* @return 壁厚字符串,单壁厚如 "15",双壁厚如 "15/20"
|
||||||
*/
|
*/
|
||||||
@@ -147,6 +214,7 @@ public class MdmDescriptionParseUtils {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 从 FRP 管型号中提取外径(mm)
|
* 从 FRP 管型号中提取外径(mm)
|
||||||
|
*
|
||||||
* @param frpModel FRP管型号描述,如 FRP管\玻璃纤维+环氧树脂\Φ152.4mm*1100mm*15/20mm\
|
* @param frpModel FRP管型号描述,如 FRP管\玻璃纤维+环氧树脂\Φ152.4mm*1100mm*15/20mm\
|
||||||
* @return 外径字符串,如 "152.4"
|
* @return 外径字符串,如 "152.4"
|
||||||
*/
|
*/
|
||||||
@@ -166,6 +234,7 @@ public class MdmDescriptionParseUtils {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 从 FRP 管型号中提取外径(mm)
|
* 从 FRP 管型号中提取外径(mm)
|
||||||
|
*
|
||||||
* @param tubeModel FRP管型号描述,如 FRP管\玻璃纤维+环氧树脂\Φ152.4mm*1100mm*15/20mm\
|
* @param tubeModel FRP管型号描述,如 FRP管\玻璃纤维+环氧树脂\Φ152.4mm*1100mm*15/20mm\
|
||||||
* @return 外径字符串,如 "152.4 / 25.4 = 6"
|
* @return 外径字符串,如 "152.4 / 25.4 = 6"
|
||||||
*/
|
*/
|
||||||
@@ -189,7 +258,7 @@ public class MdmDescriptionParseUtils {
|
|||||||
double diameterMm = Double.parseDouble(externalDiameter);
|
double diameterMm = Double.parseDouble(externalDiameter);
|
||||||
double diameterInch = diameterMm / 25.4;
|
double diameterInch = diameterMm / 25.4;
|
||||||
// 保留整数或一位小数
|
// 保留整数或一位小数
|
||||||
return String.valueOf(NumberUtil.round(diameterInch, 1).doubleValue());
|
return String.valueOf(NumberUtil.round(diameterInch, 0));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
@@ -202,8 +271,10 @@ public class MdmDescriptionParseUtils {
|
|||||||
// ==================================================
|
// ==================================================
|
||||||
//==================== 纸管解析方法 ===================
|
//==================== 纸管解析方法 ===================
|
||||||
//===================================================
|
//===================================================
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 从纸管型号中提取尺寸(英寸)
|
* 从纸管型号中提取尺寸(英寸)
|
||||||
|
*
|
||||||
* @param paperTubeModel 纸管型号描述,如 平包树脂管\3''\500mm*15mm\
|
* @param paperTubeModel 纸管型号描述,如 平包树脂管\3''\500mm*15mm\
|
||||||
* @return 英寸数值字符串,如 "3"
|
* @return 英寸数值字符串,如 "3"
|
||||||
*/
|
*/
|
||||||
@@ -221,11 +292,12 @@ public class MdmDescriptionParseUtils {
|
|||||||
// 第二部分是尺寸:3''
|
// 第二部分是尺寸:3''
|
||||||
String sizePart = parts[1];
|
String sizePart = parts[1];
|
||||||
// 移除 '' 符号
|
// 移除 '' 符号
|
||||||
String cleaned =cleanSizeValue(sizePart);
|
String cleaned = cleanSizeValue(sizePart);
|
||||||
double num = Double.parseDouble(cleaned);
|
double num = Double.parseDouble(cleaned);
|
||||||
// 四舍五入取整数
|
// 四舍五入取整数
|
||||||
long rounded = Math.round(num);
|
long rounded = Math.round(num);
|
||||||
return rounded + ".0";
|
return rounded + "";
|
||||||
|
//return rounded + ".0";
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
log.warn("提取纸管尺寸失败: {}", paperTubeModel, e);
|
log.warn("提取纸管尺寸失败: {}", paperTubeModel, e);
|
||||||
@@ -236,6 +308,7 @@ public class MdmDescriptionParseUtils {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 从纸管型号中提取长度和壁厚
|
* 从纸管型号中提取长度和壁厚
|
||||||
|
*
|
||||||
* @param paperTubeModel 纸管型号描述,如 平包树脂管\3''\500mm*15mm\
|
* @param paperTubeModel 纸管型号描述,如 平包树脂管\3''\500mm*15mm\
|
||||||
* @return String数组 [长度, 壁厚],如 ["500", "15"]
|
* @return String数组 [长度, 壁厚],如 ["500", "15"]
|
||||||
*/
|
*/
|
||||||
@@ -270,11 +343,26 @@ public class MdmDescriptionParseUtils {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static Integer getPaperLength(String paperName) {
|
||||||
|
//判断物料属于FPR管还是纸管
|
||||||
|
try {
|
||||||
|
if (paperName.contains("FRP")) {
|
||||||
|
return Integer.parseInt(extractFRPLength(paperName));
|
||||||
|
} else {
|
||||||
|
return Integer.parseInt(extractPaperLength(paperName));
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
throw new BadRequestException("物料描述转换有问题!【" + paperName + "】");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// ==================================================
|
// ==================================================
|
||||||
//==================== 木箱解析方法 ===================
|
//==================== 木箱解析方法 ===================
|
||||||
//===================================================
|
//===================================================
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 从木箱型号中提取关键信息
|
* 从木箱型号中提取关键信息
|
||||||
|
*
|
||||||
* @param woodenBoxModel 木箱型号描述,如 铜箔木箱\1100/1/6\1148mm*636mm*690mm\非熏蒸\U60
|
* @param woodenBoxModel 木箱型号描述,如 铜箔木箱\1100/1/6\1148mm*636mm*690mm\非熏蒸\U60
|
||||||
* @return String数组 [数量/层数/其他],如 ["1100", "1", "6"]
|
* @return String数组 [数量/层数/其他],如 ["1100", "1", "6"]
|
||||||
*/
|
*/
|
||||||
@@ -317,4 +405,4 @@ public class MdmDescriptionParseUtils {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -181,6 +181,10 @@ public class SlitterTaskUtil {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static void main(String[] args) {
|
||||||
|
System.out.println(getComposePaperTubeInformation("FRP管玻璃纤维+环氧树脂Φ153mm*1700mm*15/20mm"));
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取组成信息
|
* 获取组成信息
|
||||||
* @param tubeDescription 纸管信息
|
* @param tubeDescription 纸管信息
|
||||||
@@ -249,20 +253,6 @@ public class SlitterTaskUtil {
|
|||||||
return sb.toString();
|
return sb.toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void main(String[] args) {
|
|
||||||
System.out.println("【测试1】单壁厚:");
|
|
||||||
System.out.println("old: "+getComposePaperTubeInformationOld("纸制筒管|纸管|3.15英寸|1500", "1"));
|
|
||||||
System.out.println("new: "+getComposePaperTubeInformation("平包树脂管\\3.15''\\1500mm*15mm\\", "1"));
|
|
||||||
System.out.println("【测试2】阶梯1:");
|
|
||||||
System.out.println("old: "+getComposePaperTubeInformationOld("玻璃纤维及其制品|FRP管|6英寸|15-20|1100|阶梯", "1"));
|
|
||||||
System.out.println("new: "+getComposePaperTubeInformation("FRP管\\玻璃纤维+环氧树脂\\Φ152.4mm*1100mm*15/20mm\\", "1"));
|
|
||||||
// System.out.println(isNumeric(",3000"));
|
|
||||||
// System.out.println(isNumeric("3000"));
|
|
||||||
// System.out.println(isNumeric("3000.32"));
|
|
||||||
// System.out.println(isNumeric("-3000.32"));
|
|
||||||
// boolean b = checkComplete("1", "2", null);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 设置所需的套管纸管信息
|
* 设置所需的套管纸管信息
|
||||||
* @param param 任务参数
|
* @param param 任务参数
|
||||||
@@ -535,6 +525,8 @@ public class SlitterTaskUtil {
|
|||||||
// String name = "玻璃纤维及其制品|FRP管|6英寸|15|1700";
|
// String name = "玻璃纤维及其制品|FRP管|6英寸|15|1700";
|
||||||
return Integer.valueOf(getPaperLengthByCode(name));
|
return Integer.valueOf(getPaperLengthByCode(name));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public static String getPaperSize(PdmBiSlittingproductionplan plan) {
|
public static String getPaperSize(PdmBiSlittingproductionplan plan) {
|
||||||
// String s = "玻璃纤维及其制品|FRP管|6英寸|15|1700";
|
// String s = "玻璃纤维及其制品|FRP管|6英寸|15|1700";
|
||||||
// todo 88549333 因为新物料描述 纸管和 frp管的尺寸位置不一致,所以之前的取数组第三位的写法就存在问题,现修改为根据不同的类型分别获取。 2026年05月19日 21:26
|
// todo 88549333 因为新物料描述 纸管和 frp管的尺寸位置不一致,所以之前的取数组第三位的写法就存在问题,现修改为根据不同的类型分别获取。 2026年05月19日 21:26
|
||||||
|
|||||||
@@ -102,9 +102,7 @@ public class BstIvtBoxinfoServiceImpl extends ServiceImpl<BstIvtBoxinfoMapper, B
|
|||||||
// 截取子卷号
|
// 截取子卷号
|
||||||
String description = whereJson.getString("Description");
|
String description = whereJson.getString("Description");
|
||||||
try {
|
try {
|
||||||
String one = description.substring(description.indexOf("|") + 1);
|
String num = getTargetNumber(description);
|
||||||
String two = one.substring(one.indexOf("|") + 1);
|
|
||||||
String num = two.substring(two.indexOf("|") + 1, two.indexOf("|") + 2);
|
|
||||||
boxDao.setNum(num);
|
boxDao.setNum(num);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw new BadRequestException("截取失败,请检查mes数据!");
|
throw new BadRequestException("截取失败,请检查mes数据!");
|
||||||
@@ -137,6 +135,27 @@ public class BstIvtBoxinfoServiceImpl extends ServiceImpl<BstIvtBoxinfoMapper, B
|
|||||||
|
|
||||||
return boxDao;
|
return boxDao;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static String getTargetNumber(String line) {
|
||||||
|
// 1. 先按 \ 分割,拿到第二段:1200/1/6
|
||||||
|
String[] splitByBackslash = line.split("\\\\");
|
||||||
|
if (splitByBackslash.length < 2) {
|
||||||
|
throw new BadRequestException("物料描述有问题!");
|
||||||
|
}
|
||||||
|
|
||||||
|
// 2. 再按 / 分割,拿到第二个值(索引1)
|
||||||
|
String[] splitBySlash = splitByBackslash[1].split("/");
|
||||||
|
if (splitBySlash.length >= 2) {
|
||||||
|
return splitBySlash[1]; // 第二个位置,就是你要的数字
|
||||||
|
}
|
||||||
|
|
||||||
|
throw new BadRequestException("物料描述有问题!");
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void main(String[] args) {
|
||||||
|
System.out.println(getTargetNumber("铜箔木箱\\810/3/3\\1294mm*880mm*530mm\\非熏蒸\\U30"));
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public JSONObject saveBoxInfo(JSONObject jsonObject) {
|
public JSONObject saveBoxInfo(JSONObject jsonObject) {
|
||||||
//从MES获取包装关系
|
//从MES获取包装关系
|
||||||
|
|||||||
@@ -1674,7 +1674,7 @@ public class StIvtIostorinvOutServiceImpl extends ServiceImpl<StIvtIostorinvOutM
|
|||||||
jsonTaskParam.put("vehicle_code2", jsonVeExt.getString("storagevehicle_code"));
|
jsonTaskParam.put("vehicle_code2", jsonVeExt.getString("storagevehicle_code"));
|
||||||
jsonTaskParam.put("table_fk", iostorinv_id);
|
jsonTaskParam.put("table_fk", iostorinv_id);
|
||||||
|
|
||||||
TwoOutExceptionalTask taskBean = new TwoOutExceptionalTask();
|
TwoOutExceptionalTask taskBean = SpringContextHolder.getBean(TwoOutExceptionalTask.class);
|
||||||
String task_id = taskBean.createTask(jsonTaskParam);
|
String task_id = taskBean.createTask(jsonTaskParam);
|
||||||
taskBean.immediateNotifyAcs(task_id);
|
taskBean.immediateNotifyAcs(task_id);
|
||||||
|
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ package org.nl.b_lms.storage_manage.ios.service.iostorInv.util.impl;
|
|||||||
import cn.hutool.core.date.DateUtil;
|
import cn.hutool.core.date.DateUtil;
|
||||||
import cn.hutool.core.util.NumberUtil;
|
import cn.hutool.core.util.NumberUtil;
|
||||||
import cn.hutool.core.util.ObjectUtil;
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
import com.alibaba.fastjson.JSONArray;
|
import com.alibaba.fastjson.JSONArray;
|
||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
@@ -43,6 +44,7 @@ import java.util.List;
|
|||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.concurrent.TimeUnit;
|
import java.util.concurrent.TimeUnit;
|
||||||
import java.util.function.Consumer;
|
import java.util.function.Consumer;
|
||||||
|
import java.util.function.Predicate;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -143,10 +145,14 @@ public class OutBussManageServiceImpl implements OutBussManageService {
|
|||||||
double unassign_qty = dtlDao.getUnassign_qty().doubleValue();
|
double unassign_qty = dtlDao.getUnassign_qty().doubleValue();
|
||||||
|
|
||||||
if (ObjectUtil.isNotEmpty(dtlDao.getSource_bill_code())) {
|
if (ObjectUtil.isNotEmpty(dtlDao.getSource_bill_code())) {
|
||||||
|
Predicate<JSONObject> condition = row ->
|
||||||
|
row.getString("material_id").equals(dtlDao.getMaterial_id().toString())
|
||||||
|
&& row.getString("sale_order_name").equals(dtlDao.getSource_bill_code())
|
||||||
|
&& (ObjectUtil.isEmpty(dtlDao.getPcsn())
|
||||||
|
|| row.getString("pcsn").equals(dtlDao.getPcsn()));
|
||||||
// 有订单号: 找相同物料、订单号的库存,并根据仓位分组、即木箱分组
|
// 有订单号: 找相同物料、订单号的库存,并根据仓位分组、即木箱分组
|
||||||
Map<String, List<JSONObject>> likeMaterOrderMap = ivtList.stream()
|
Map<String, List<JSONObject>> likeMaterOrderMap = ivtList.stream()
|
||||||
.filter(row -> row.getString("material_id").equals(dtlDao.getMaterial_id().toString()) &&
|
.filter(condition)
|
||||||
row.getString("sale_order_name").equals(dtlDao.getSource_bill_code()))
|
|
||||||
.collect(Collectors.groupingBy(row -> row.getString("struct_code")));
|
.collect(Collectors.groupingBy(row -> row.getString("struct_code")));
|
||||||
|
|
||||||
if (ObjectUtil.isEmpty(likeMaterOrderMap)) {
|
if (ObjectUtil.isEmpty(likeMaterOrderMap)) {
|
||||||
|
|||||||
@@ -39,17 +39,17 @@ public class JobRunner implements ApplicationRunner {
|
|||||||
System.out.println("本机ip:"+localIp);
|
System.out.println("本机ip:"+localIp);
|
||||||
|
|
||||||
log.info("--------------------注入定时任务---------------------");
|
log.info("--------------------注入定时任务---------------------");
|
||||||
// List<SysQuartzJob> quartzJobs = quartzJobService.findByIsPauseIsFalse();
|
List<SysQuartzJob> quartzJobs = quartzJobService.findByIsPauseIsFalse();
|
||||||
// quartzJobs.forEach(job -> {
|
quartzJobs.forEach(job -> {
|
||||||
// if (judgmentIp(job.getJob_ip())) {
|
if (judgmentIp(job.getJob_ip())) {
|
||||||
// log.info("定时任务:{}, 执行ip: {}, 定时任务开启", job.getJob_name(), localIp);
|
log.info("定时任务:{}, 执行ip: {}, 定时任务开启", job.getJob_name(), localIp);
|
||||||
// System.out.println("定时任务: " + job.getJob_name() + ", 执行ip: " + localIp + ", 定时任务开启");
|
System.out.println("定时任务: " + job.getJob_name() + ", 执行ip: " + localIp + ", 定时任务开启");
|
||||||
// quartzManage.addJob(job);
|
quartzManage.addJob(job);
|
||||||
// } else {
|
} else {
|
||||||
// log.info("定时任务 {} 未开启, 本机ip{} 与 调度ip{} 不同", job.getJob_name(), localIp, job.getJob_ip());
|
log.info("定时任务 {} 未开启, 本机ip{} 与 调度ip{} 不同", job.getJob_name(), localIp, job.getJob_ip());
|
||||||
// System.out.println("定时任务 " + job.getJob_name() + " 未开启, 本机ip: " + localIp + " 与 调度ip: " + job.getJob_ip() + " 不同");
|
System.out.println("定时任务 " + job.getJob_name() + " 未开启, 本机ip: " + localIp + " 与 调度ip: " + job.getJob_ip() + " 不同");
|
||||||
// }
|
}
|
||||||
// });
|
});
|
||||||
|
|
||||||
log.info("--------------------定时任务注入完成---------------------");
|
log.info("--------------------定时任务注入完成---------------------");
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -943,9 +943,9 @@
|
|||||||
FROM
|
FROM
|
||||||
md_me_materialbase
|
md_me_materialbase
|
||||||
WHERE
|
WHERE
|
||||||
(material_code like '48221%'
|
(material_name like 'FRP%'
|
||||||
OR
|
OR
|
||||||
material_code like '701990999%')
|
material_name like '平包树脂管%')
|
||||||
OPTION 输入.material_code <> ""
|
OPTION 输入.material_code <> ""
|
||||||
material_code like 输入.material_code
|
material_code like 输入.material_code
|
||||||
ENDOPTION
|
ENDOPTION
|
||||||
|
|||||||
@@ -104,7 +104,7 @@ public class PaperTubeTask extends AbstractAcsTask {
|
|||||||
String paper_tube_or_FRP = plan_jo.getString("paper_tube_or_frp");
|
String paper_tube_or_FRP = plan_jo.getString("paper_tube_or_frp");
|
||||||
String paper_name;
|
String paper_name;
|
||||||
String need_size;
|
String need_size;
|
||||||
// todo 88549333 因为新物料描述 纸管和 frp管的尺寸位置不一致,所以之前的取数组第三位的写法就存在问题,现修改为根据不同的类型分别获取。 2026年05月05日 19:10
|
// todo 88549333/zhouz 因为新物料描述 纸管和 frp管的尺寸位置不一致,所以之前的取数组第三位的写法就存在问题,现修改为根据不同的类型分别获取。 2026年05月05日 19:10
|
||||||
if ("1".equals(paper_tube_or_FRP)) {
|
if ("1".equals(paper_tube_or_FRP)) {
|
||||||
paper_name = plan_jo.getString("paper_tube_description");
|
paper_name = plan_jo.getString("paper_tube_description");
|
||||||
need_size = MdmDescriptionParseUtils.extractPaperTubeSize(paper_name);
|
need_size = MdmDescriptionParseUtils.extractPaperTubeSize(paper_name);
|
||||||
|
|||||||
@@ -65,10 +65,6 @@
|
|||||||
ivt.pcsn = 输入.pcsn
|
ivt.pcsn = 输入.pcsn
|
||||||
ENDOPTION
|
ENDOPTION
|
||||||
|
|
||||||
OPTION 输入.quality_scode <> ""
|
|
||||||
ivt.quality_scode = 输入.quality_scode
|
|
||||||
ENDOPTION
|
|
||||||
|
|
||||||
OPTION 输入.storagevehicle_code <> ""
|
OPTION 输入.storagevehicle_code <> ""
|
||||||
attr.storagevehicle_code = 输入.storagevehicle_code
|
attr.storagevehicle_code = 输入.storagevehicle_code
|
||||||
ENDOPTION
|
ENDOPTION
|
||||||
|
|||||||
@@ -988,7 +988,8 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
|||||||
|
|
||||||
JSONObject jsonMst = mstTab.query("iostorinv_id = '" + whereJson.getString("iostorinv_id") + "'").uniqueResult(0);
|
JSONObject jsonMst = mstTab.query("iostorinv_id = '" + whereJson.getString("iostorinv_id") + "'").uniqueResult(0);
|
||||||
|
|
||||||
if (!StrUtil.equals(jsonMst.getString("bill_type"), "1001")) {
|
String bill_type = jsonMst.getString("bill_type");
|
||||||
|
if (!"1001,1011,1013,1014,1015".contains(bill_type)) {
|
||||||
throw new BadRequestException("请选择发货出库单据!");
|
throw new BadRequestException("请选择发货出库单据!");
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1622,12 +1623,18 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
|||||||
if (ObjectUtil.isEmpty(dtls)) {
|
if (ObjectUtil.isEmpty(dtls)) {
|
||||||
throw new BadRequestException("当前订单无可分配出库明细");
|
throw new BadRequestException("当前订单无可分配出库明细");
|
||||||
}
|
}
|
||||||
|
boolean add_pcsn = false;
|
||||||
//定义需要更新的仓位集合
|
//定义需要更新的仓位集合
|
||||||
HashMap<String, JSONObject> Struct_map = new HashMap<String, JSONObject>();
|
HashMap<String, JSONObject> Struct_map = new HashMap<String, JSONObject>();
|
||||||
for (int i = 0; i < dtls.size(); i++) {
|
for (int i = 0; i < dtls.size(); i++) {
|
||||||
JSONObject dtl = dtls.getJSONObject(i);
|
JSONObject dtl = dtls.getJSONObject(i);
|
||||||
double unassign_qty = dtl.getDoubleValue("unassign_qty");
|
double unassign_qty = dtl.getDoubleValue("unassign_qty");
|
||||||
double plan_qty = dtl.getDoubleValue("plan_qty");
|
double plan_qty = dtl.getDoubleValue("plan_qty");
|
||||||
|
String dtl_pcsn = "";
|
||||||
|
if (StrUtil.isNotEmpty(dtl.getString("pcsn"))) {
|
||||||
|
add_pcsn = true;
|
||||||
|
dtl_pcsn = dtl.getString("pcsn");
|
||||||
|
}
|
||||||
/*
|
/*
|
||||||
* 分配规则:
|
* 分配规则:
|
||||||
* top1.有销售订单号:用销售订单号、物料去找这批物料最早入库的所在的巷道
|
* top1.有销售订单号:用销售订单号、物料去找这批物料最早入库的所在的巷道
|
||||||
@@ -1650,6 +1657,9 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
|||||||
jsonMap.put("sale_order_name", dtl.getString("source_bill_code"));
|
jsonMap.put("sale_order_name", dtl.getString("source_bill_code"));
|
||||||
jsonMap.put("sect_id", whereJson.getString("sect_id"));
|
jsonMap.put("sect_id", whereJson.getString("sect_id"));
|
||||||
jsonMap.put("stor_id", whereJson.getString("stor_id"));
|
jsonMap.put("stor_id", whereJson.getString("stor_id"));
|
||||||
|
if (add_pcsn) {
|
||||||
|
jsonMap.put("pcsn", dtl_pcsn);
|
||||||
|
}
|
||||||
|
|
||||||
JSONObject jsonOneIvt = WQL.getWO("ST_OUTIVT01").addParamMap(jsonMap).process().uniqueResult(0);
|
JSONObject jsonOneIvt = WQL.getWO("ST_OUTIVT01").addParamMap(jsonMap).process().uniqueResult(0);
|
||||||
if (ObjectUtil.isEmpty(jsonOneIvt)) {
|
if (ObjectUtil.isEmpty(jsonOneIvt)) {
|
||||||
@@ -1676,6 +1686,9 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
|||||||
// 查询此木箱下的所有子卷
|
// 查询此木箱下的所有子卷
|
||||||
jsonMap.put("flag", "3");
|
jsonMap.put("flag", "3");
|
||||||
jsonMap.put("storagevehicle_code", ivt.getString("storagevehicle_code"));
|
jsonMap.put("storagevehicle_code", ivt.getString("storagevehicle_code"));
|
||||||
|
if (add_pcsn){
|
||||||
|
jsonMap.put("pcsn", dtl_pcsn);
|
||||||
|
}
|
||||||
JSONArray ivtAllArr2 = WQL.getWO("ST_OUTIVT01").addParamMap(jsonMap).process().getResultJSONArray(0);
|
JSONArray ivtAllArr2 = WQL.getWO("ST_OUTIVT01").addParamMap(jsonMap).process().getResultJSONArray(0);
|
||||||
|
|
||||||
for (int k = 0; k < ivtAllArr2.size(); k++) {
|
for (int k = 0; k < ivtAllArr2.size(); k++) {
|
||||||
@@ -1688,6 +1701,28 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
|||||||
ivt2.put("bill_table", "ST_IVT_IOStorInv");
|
ivt2.put("bill_table", "ST_IVT_IOStorInv");
|
||||||
storPublicService.IOStor(ivt2, "11");
|
storPublicService.IOStor(ivt2, "11");
|
||||||
|
|
||||||
|
/*if (!dtl.getString("pcsn").equals(ivt2.getString("pcsn"))) {
|
||||||
|
//判断该库存的PCSN是否存在对应的DTL明细,如果存在则直接对应到该DTL明细
|
||||||
|
JSONObject pcsn_dtl = wo_dtl.query("iostorinv_id = '" + dtl.getString("iostorinv_id") + "' AND pcsn = '" + ivt2.getString("pcsn") + "'").uniqueResult(0);
|
||||||
|
if (ObjectUtil.isNotEmpty(pcsn_dtl)) {
|
||||||
|
dtl = pcsn_dtl;
|
||||||
|
double can_qty = ivt2.getDoubleValue("canuse_qty");
|
||||||
|
double dtl_assign_qty = pcsn_dtl.getDoubleValue("assign_qty");
|
||||||
|
double dtl_unassign_qty = pcsn_dtl.getDoubleValue("unassign_qty");
|
||||||
|
assign_qty = NumberUtil.add(dtl_assign_qty, can_qty);
|
||||||
|
|
||||||
|
if (dtl_unassign_qty >= can_qty) {
|
||||||
|
dtl_unassign_qty = NumberUtil.sub(dtl_unassign_qty, can_qty);
|
||||||
|
} else {
|
||||||
|
dtl_unassign_qty = 0;
|
||||||
|
}
|
||||||
|
pcsn_dtl.put("assign_qty", dtl_assign_qty);
|
||||||
|
pcsn_dtl.put("unassign_qty", dtl_unassign_qty);
|
||||||
|
wo_dtl.update(pcsn_dtl);
|
||||||
|
}
|
||||||
|
}*/
|
||||||
|
|
||||||
|
|
||||||
//生成分配明细
|
//生成分配明细
|
||||||
dtl.put("iostorinvdis_id", IdUtil.getLongId());
|
dtl.put("iostorinvdis_id", IdUtil.getLongId());
|
||||||
dtl.put("sect_id", ivt2.getString("sect_id"));
|
dtl.put("sect_id", ivt2.getString("sect_id"));
|
||||||
@@ -1825,19 +1860,19 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
|||||||
//更新主表状态
|
//更新主表状态
|
||||||
this.updateMststatus(iostorinv_id);
|
this.updateMststatus(iostorinv_id);
|
||||||
|
|
||||||
//锁定起点点位、仓位
|
}
|
||||||
Collection<JSONObject> c = Struct_map.values();
|
//锁定起点点位、仓位
|
||||||
Iterator<JSONObject> it = c.iterator();
|
Collection<JSONObject> c = Struct_map.values();
|
||||||
JSONObject from_start = new JSONObject();
|
Iterator<JSONObject> it = c.iterator();
|
||||||
from_start.put("lock_type", "3");
|
JSONObject from_start = new JSONObject();
|
||||||
for (; it.hasNext(); ) {
|
from_start.put("lock_type", "3");
|
||||||
JSONObject Struct = it.next();
|
for (; it.hasNext(); ) {
|
||||||
from_start.put("struct_id", Struct.getString("struct_id"));
|
JSONObject Struct = it.next();
|
||||||
from_start.put("inv_type", jo_mst.getString("bill_type"));
|
from_start.put("struct_id", Struct.getString("struct_id"));
|
||||||
from_start.put("inv_id", jo_mst.getString("iostorinv_id"));
|
from_start.put("inv_type", jo_mst.getString("bill_type"));
|
||||||
from_start.put("inv_code", jo_mst.getString("bill_code"));
|
from_start.put("inv_id", jo_mst.getString("iostorinv_id"));
|
||||||
storPublicService.updateStructAndPoint(from_start);
|
from_start.put("inv_code", jo_mst.getString("bill_code"));
|
||||||
}
|
storPublicService.updateStructAndPoint(from_start);
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
}, "all_divOne", whereJson);
|
}, "all_divOne", whereJson);
|
||||||
|
|||||||
@@ -128,6 +128,10 @@
|
|||||||
ivt.material_id = 输入.material_id
|
ivt.material_id = 输入.material_id
|
||||||
ENDOPTION
|
ENDOPTION
|
||||||
|
|
||||||
|
OPTION 输入.pcsn <> ""
|
||||||
|
ivt.pcsn = 输入.pcsn
|
||||||
|
ENDOPTION
|
||||||
|
|
||||||
OPTION 输入.sale_order_name <> ""
|
OPTION 输入.sale_order_name <> ""
|
||||||
sub.sale_order_name = 输入.sale_order_name
|
sub.sale_order_name = 输入.sale_order_name
|
||||||
ENDOPTION
|
ENDOPTION
|
||||||
@@ -187,6 +191,10 @@
|
|||||||
attr.storagevehicle_code = 输入.storagevehicle_code
|
attr.storagevehicle_code = 输入.storagevehicle_code
|
||||||
ENDOPTION
|
ENDOPTION
|
||||||
|
|
||||||
|
OPTION 输入.pcsn <> ""
|
||||||
|
ivt.pcsn = 输入.pcsn
|
||||||
|
ENDOPTION
|
||||||
|
|
||||||
order by ivt.instorage_time ASC
|
order by ivt.instorage_time ASC
|
||||||
|
|
||||||
ENDSELECT
|
ENDSELECT
|
||||||
|
|||||||
@@ -308,7 +308,7 @@ public class InAndOutRetrunServiceImpl implements InAndOutReturnService {
|
|||||||
|
|
||||||
// 销售出库
|
// 销售出库
|
||||||
// if (StrUtil.equals(bill_type, "1001") && is_productstore.equals("1")) {
|
// if (StrUtil.equals(bill_type, "1001") && is_productstore.equals("1")) {
|
||||||
if (StrUtil.equals(bill_type, "1001")) {
|
if (StrUtil.equals(bill_type, "1001")|| StrUtil.equals(bill_type, "1011") || StrUtil.equals(bill_type, "1013") || StrUtil.equals(bill_type, "1014") || StrUtil.equals(bill_type, "1015")) {
|
||||||
// 2.回传mes
|
// 2.回传mes
|
||||||
JSONObject paramMesMst = new JSONObject();
|
JSONObject paramMesMst = new JSONObject();
|
||||||
String userName = SpringContextHolder.getBean(SysParamServiceImpl.class).findByCode("MES_USERNAME").getValue();
|
String userName = SpringContextHolder.getBean(SysParamServiceImpl.class).findByCode("MES_USERNAME").getValue();
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import request from '@/utils/request'
|
import request from '@/utils/request'
|
||||||
|
|
||||||
export function getBizCodeList(systemFlag,direction) {
|
export function getBizCodeList(systemFlag, direction) {
|
||||||
return request({
|
return request({
|
||||||
url: 'api/sysApiLog/bizCodeList',
|
url: 'api/sysApiLog/bizCodeList',
|
||||||
method: 'get',
|
method: 'get',
|
||||||
@@ -14,4 +14,4 @@ export function archiveLogs() {
|
|||||||
method: 'post'
|
method: 'post'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
export default { getBizCodeList,archiveLogs }
|
export default { getBizCodeList, archiveLogs }
|
||||||
|
|||||||
@@ -1,9 +1,9 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="login" :style="'background-image:url('+ Background +');'">
|
<div class="login" :style="'background-image:url('+ Background +');'">
|
||||||
<img v-if="logo" :src="logo" class="sidebar-logo2" />
|
<img v-if="logo" :src="logo" class="sidebar-logo2">
|
||||||
<el-form ref="loginForm" :model="loginForm" :rules="loginRules" label-position="left" label-width="0px" class="login-form">
|
<el-form ref="loginForm" :model="loginForm" :rules="loginRules" label-position="left" label-width="0px" class="login-form">
|
||||||
<h3 class="title">
|
<h3 class="title">
|
||||||
{{title}}</h3>
|
{{ title }}</h3>
|
||||||
<el-form-item prop="username">
|
<el-form-item prop="username">
|
||||||
<el-input v-model="loginForm.username" type="text" auto-complete="off" placeholder="账号">
|
<el-input v-model="loginForm.username" type="text" auto-complete="off" placeholder="账号">
|
||||||
<svg-icon slot="prefix" icon-class="user" class="el-input__icon input-icon" />
|
<svg-icon slot="prefix" icon-class="user" class="el-input__icon input-icon" />
|
||||||
|
|||||||
@@ -113,8 +113,8 @@
|
|||||||
>
|
>
|
||||||
<el-table-column prop="direction" label="接口走向" width="100">
|
<el-table-column prop="direction" label="接口走向" width="100">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-tag v-if="scope.row.direction === 0" type="success"><i class="el-icon-upload2"></i>出站</el-tag>
|
<el-tag v-if="scope.row.direction === 0" type="success"><i class="el-icon-upload2" />出站</el-tag>
|
||||||
<el-tag v-else-if="scope.row.direction === 1" type="primary"><i class="el-icon-download"></i>入站</el-tag>
|
<el-tag v-else-if="scope.row.direction === 1" type="primary"><i class="el-icon-download" />入站</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="systemFlag" label="系统标识" width="100" />
|
<el-table-column prop="systemFlag" label="系统标识" width="100" />
|
||||||
@@ -162,8 +162,8 @@
|
|||||||
<el-descriptions-item label="日志ID">{{ currentRow.logId }}</el-descriptions-item>
|
<el-descriptions-item label="日志ID">{{ currentRow.logId }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="链路追踪ID">{{ currentRow.traceId }}</el-descriptions-item>
|
<el-descriptions-item label="链路追踪ID">{{ currentRow.traceId }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="接口走向">
|
<el-descriptions-item label="接口走向">
|
||||||
<el-tag v-if="currentRow.direction === 0" type="success" size="small"><i class="el-icon-upload2"></i>出站</el-tag>
|
<el-tag v-if="currentRow.direction === 0" type="success" size="small"><i class="el-icon-upload2" />出站</el-tag>
|
||||||
<el-tag v-else-if="currentRow.direction === 1" type="primary" size="small"><i class="el-icon-download"></i>入站</el-tag>
|
<el-tag v-else-if="currentRow.direction === 1" type="primary" size="small"><i class="el-icon-download" />入站</el-tag>
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item label="系统标识">{{ currentRow.systemFlag }}</el-descriptions-item>
|
<el-descriptions-item label="系统标识">{{ currentRow.systemFlag }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="业务类型">{{ currentRow.bizCode }}</el-descriptions-item>
|
<el-descriptions-item label="业务类型">{{ currentRow.bizCode }}</el-descriptions-item>
|
||||||
@@ -178,7 +178,7 @@
|
|||||||
<el-descriptions-item label="响应状态码">{{ currentRow.responseStatus }}</el-descriptions-item>
|
<el-descriptions-item label="响应状态码">{{ currentRow.responseStatus }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="耗时">{{ currentRow.costTime }}ms</el-descriptions-item>
|
<el-descriptions-item label="耗时">{{ currentRow.costTime }}ms</el-descriptions-item>
|
||||||
<el-descriptions-item label="请求时间">{{ parseTime(currentRow.createTime) }}</el-descriptions-item>
|
<el-descriptions-item label="请求时间">{{ parseTime(currentRow.createTime) }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="错误信息" :span="2" v-if="currentRow.errorMsg">
|
<el-descriptions-item v-if="currentRow.errorMsg" label="错误信息" :span="2">
|
||||||
<span style="color: #f56c6c;">{{ currentRow.errorMsg }}</span>
|
<span style="color: #f56c6c;">{{ currentRow.errorMsg }}</span>
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
</el-descriptions>
|
</el-descriptions>
|
||||||
|
|||||||
@@ -263,7 +263,7 @@ const defaultForm = {
|
|||||||
stor_id: '',
|
stor_id: '',
|
||||||
stor_code: '',
|
stor_code: '',
|
||||||
stor_name: '',
|
stor_name: '',
|
||||||
scrap_type:'',
|
scrap_type: '',
|
||||||
bill_status: '10',
|
bill_status: '10',
|
||||||
total_qty: '0',
|
total_qty: '0',
|
||||||
detail_count: '0',
|
detail_count: '0',
|
||||||
@@ -283,7 +283,7 @@ export default {
|
|||||||
default: false
|
default: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
dicts: ['SCRAP_STATUS', 'FAIL_SOURCE','ST_INV_OUT_TYPE'],
|
dicts: ['SCRAP_STATUS', 'FAIL_SOURCE', 'ST_INV_OUT_TYPE'],
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
dialogVisible: false,
|
dialogVisible: false,
|
||||||
@@ -308,7 +308,7 @@ export default {
|
|||||||
biz_date: [
|
biz_date: [
|
||||||
{ required: true, message: '业务日期不能为空', trigger: 'blur' }
|
{ required: true, message: '业务日期不能为空', trigger: 'blur' }
|
||||||
],
|
],
|
||||||
scrap_type:[
|
scrap_type: [
|
||||||
{ required: true, message: '报废类型不能为空', trigger: 'blur' }
|
{ required: true, message: '报废类型不能为空', trigger: 'blur' }
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -57,8 +57,8 @@
|
|||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in dict.ST_INV_OUT_TYPE"
|
v-for="item in dict.ST_INV_OUT_TYPE"
|
||||||
:disabled="item.value === '1099'"
|
|
||||||
:key="item.value"
|
:key="item.value"
|
||||||
|
:disabled="item.value === '1099'"
|
||||||
:label="item.label"
|
:label="item.label"
|
||||||
:value="item.value"
|
:value="item.value"
|
||||||
/>
|
/>
|
||||||
@@ -99,7 +99,7 @@
|
|||||||
<el-form-item label="业务日期" prop="biz_date">
|
<el-form-item label="业务日期" prop="biz_date">
|
||||||
<el-date-picker v-model="form.biz_date" type="date" placeholder="选择日期" style="width: 210px" value-format="yyyy-MM-dd" :disabled="crud.status.view > 0" />
|
<el-date-picker v-model="form.biz_date" type="date" placeholder="选择日期" style="width: 210px" value-format="yyyy-MM-dd" :disabled="crud.status.view > 0" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="移入仓库" prop="out_stor_id" v-if="form.bill_type === '1004'" required="true">
|
<el-form-item v-if="form.bill_type === '1004'" label="移入仓库" prop="out_stor_id" required="true">
|
||||||
<label slot="label">移入仓库:</label>
|
<label slot="label">移入仓库:</label>
|
||||||
<el-select
|
<el-select
|
||||||
v-model="form.out_stor_id"
|
v-model="form.out_stor_id"
|
||||||
@@ -236,7 +236,7 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-table-column>-->
|
</el-table-column>-->
|
||||||
|
|
||||||
<!-- <el-table-column prop="source_bill_type" label="源单类型" align="center" width="130px" :formatter="invtypeFormat" show-overflow-tooltip />-->
|
<!-- <el-table-column prop="source_bill_type" label="源单类型" align="center" width="130px" :formatter="invtypeFormat" show-overflow-tooltip />-->
|
||||||
<el-table-column prop="source_bill_code" label="源单号" align="center" width="130px" show-overflow-tooltip />
|
<el-table-column prop="source_bill_code" label="源单号" align="center" width="130px" show-overflow-tooltip />
|
||||||
<el-table-column show-overflow-tooltip prop="remark" label="明细备注" align="center">
|
<el-table-column show-overflow-tooltip prop="remark" label="明细备注" align="center">
|
||||||
<template scope="scope">
|
<template scope="scope">
|
||||||
@@ -251,7 +251,7 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
|
|
||||||
<AddDtl :dialog-show.sync="dtlShow" :stor-id="storId" @tableChanged="tableChanged5" />
|
<AddDtl :dialog-show.sync="dtlShow" :stor-id="storId" :lock-type="1" @tableChanged="tableChanged5" />
|
||||||
<MaterDialog :dialog-show.sync="materShow" :mater-opt-code.sync="materType" @setMaterValue="setMaterValue" />
|
<MaterDialog :dialog-show.sync="materShow" :mater-opt-code.sync="materType" @setMaterValue="setMaterValue" />
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
@@ -349,7 +349,7 @@ export default {
|
|||||||
this.crud.notify('移入仓库不能为空!', CRUD.NOTIFICATION_TYPE.INFO)
|
this.crud.notify('移入仓库不能为空!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
/*if (this.form.out_stor_id === this.form.stor_id) {
|
/* if (this.form.out_stor_id === this.form.stor_id) {
|
||||||
this.crud.notify('移出仓库和移入仓库不能一致!', CRUD.NOTIFICATION_TYPE.INFO)
|
this.crud.notify('移出仓库和移入仓库不能一致!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||||
return false
|
return false
|
||||||
}*/
|
}*/
|
||||||
@@ -441,7 +441,7 @@ export default {
|
|||||||
const data = {
|
const data = {
|
||||||
'data': rows
|
'data': rows
|
||||||
}
|
}
|
||||||
if(this.form.bill_type === '1011') {
|
if (this.form.bill_type === '1011') {
|
||||||
debugger
|
debugger
|
||||||
rows.forEach((item) => {
|
rows.forEach((item) => {
|
||||||
debugger
|
debugger
|
||||||
|
|||||||
@@ -80,10 +80,10 @@
|
|||||||
v-for="item in dict.ST_INV_OUT_TYPE"
|
v-for="item in dict.ST_INV_OUT_TYPE"
|
||||||
:key="item.value"
|
:key="item.value"
|
||||||
:disabled="item.value !== '1001'
|
:disabled="item.value !== '1001'
|
||||||
&& item.value !== '1009'
|
&& item.value !== '1009'
|
||||||
&& item.value !== '1013'
|
&& item.value !== '1013'
|
||||||
&& item.value !== '1014'
|
&& item.value !== '1014'
|
||||||
&& item.value !== '1015'"
|
&& item.value !== '1015'"
|
||||||
:label="item.label"
|
:label="item.label"
|
||||||
:value="item.value"
|
:value="item.value"
|
||||||
/>
|
/>
|
||||||
|
|||||||
Reference in New Issue
Block a user