opt:
1.子卷装箱增加子卷质检生成包装关系,去除临时包装关系; 2.修改最后一个子卷判断方式; 3.恢复装箱毛重推送,优化装箱页面;
This commit is contained in:
@@ -76,9 +76,10 @@ public class PdmBiSubpackagerelationController {
|
|||||||
*
|
*
|
||||||
* @param whereJson 查询条件
|
* @param whereJson 查询条件
|
||||||
*/
|
*/
|
||||||
@GetMapping("/queryContainerNameBySaleOrder")
|
@PostMapping ("/queryContainerNameBySaleOrder")
|
||||||
|
@SaIgnore
|
||||||
@Log("根据订单号查询子卷信息")
|
@Log("根据订单号查询子卷信息")
|
||||||
public ResponseEntity<Object> queryContainerNameBySaleOrder(@RequestParam Map whereJson) {
|
public ResponseEntity<Object> queryContainerNameBySaleOrder(@RequestBody Map whereJson) {
|
||||||
return new ResponseEntity<>(TableDataInfo.build(pdmBiSubpackagerelationService.queryContainerNameBySaleOrder(whereJson)), HttpStatus.OK);
|
return new ResponseEntity<>(TableDataInfo.build(pdmBiSubpackagerelationService.queryContainerNameBySaleOrder(whereJson)), HttpStatus.OK);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -112,6 +113,7 @@ public class PdmBiSubpackagerelationController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping("/updateEntityList")
|
@PostMapping("/updateEntityList")
|
||||||
|
@SaIgnore
|
||||||
@Log("子卷装箱")
|
@Log("子卷装箱")
|
||||||
//@SaCheckPermission("@el.check(updateEntityList)")
|
//@SaCheckPermission("@el.check(updateEntityList)")
|
||||||
public ResponseEntity<Object> updateEntityList(@RequestBody JSONObject whereJson) {
|
public ResponseEntity<Object> updateEntityList(@RequestBody JSONObject whereJson) {
|
||||||
|
|||||||
@@ -324,6 +324,20 @@ public class PdmBiSubpackagerelation extends Model<PdmBiSubpackagerelation> {
|
|||||||
private String paper_tube_description;
|
private String paper_tube_description;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 纸管重量
|
||||||
|
*/
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String paper_weight;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 子卷重量
|
||||||
|
*/
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String weight;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取主键值
|
* 获取主键值
|
||||||
|
|||||||
@@ -28,6 +28,6 @@ public interface PdmBiSubpackagerelationMapper extends BaseMapper<PdmBiSubpackag
|
|||||||
@Param("status") String status);
|
@Param("status") String status);
|
||||||
|
|
||||||
|
|
||||||
List<PdmBiSubpackagerelation> queryContainerNameBySaleOrder( @Param("sale_order_name") String sale_order_name);
|
List<PdmBiSubpackagerelation> queryContainerNameBySaleOrder( @Param("sale_order_name") String sale_order_name,@Param("container_name") String container_name);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -77,14 +77,22 @@
|
|||||||
b.*,
|
b.*,
|
||||||
(CASE
|
(CASE
|
||||||
WHEN c.paper_tube_or_FRP = '1' THEN c.paper_tube_description
|
WHEN c.paper_tube_or_FRP = '1' THEN c.paper_tube_description
|
||||||
WHEN c.paper_tube_or_FRP = '2' THEN c.FRP_description END) AS paper_tube_description
|
WHEN c.paper_tube_or_FRP = '2' THEN c.FRP_description END) AS paper_tube_description,
|
||||||
|
c.weight,
|
||||||
|
c.paper_weight
|
||||||
FROM `pdm_bi_subpackagerelation` a
|
FROM `pdm_bi_subpackagerelation` a
|
||||||
LEFT JOIN bst_ivt_packageinfoivt b ON a.container_name = b.container_name
|
LEFT JOIN bst_ivt_packageinfoivt b ON a.container_name = b.container_name
|
||||||
LEFT JOIN pdm_bi_slittingproductionplan c ON a.container_name = c.container_name
|
LEFT JOIN pdm_bi_slittingproductionplan c ON a.container_name = c.container_name
|
||||||
WHERE b.point_status = '3'
|
WHERE b.point_status = '3'
|
||||||
AND b.ivt_status = '3'
|
AND b.ivt_status = '3'
|
||||||
AND a.sale_order_name = #{sale_order_name}
|
AND b.is_used = '1'
|
||||||
AND c.is_delete = '0'
|
AND c.is_delete = '0'
|
||||||
|
<if test="sale_order_name != null and sale_order_name != ''">
|
||||||
|
AND a.sale_order_name = #{sale_order_name}
|
||||||
|
</if>
|
||||||
|
<if test="container_name != null and container_name != ''">
|
||||||
|
AND a.container_name = #{container_name}
|
||||||
|
</if>
|
||||||
ORDER BY box_group
|
ORDER BY box_group
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|||||||
@@ -32,9 +32,10 @@ import org.nl.b_lms.sch.point.service.IbstIvtPackageinfoivtService;
|
|||||||
import org.nl.b_lms.sch.task.dao.SchBaseTask;
|
import org.nl.b_lms.sch.task.dao.SchBaseTask;
|
||||||
import org.nl.b_lms.sch.task.service.IschBaseTaskService;
|
import org.nl.b_lms.sch.task.service.IschBaseTaskService;
|
||||||
import org.nl.b_lms.sch.tasks.first_floor_area.DjqTask;
|
import org.nl.b_lms.sch.tasks.first_floor_area.DjqTask;
|
||||||
import org.nl.b_lms.sch.tasks.first_floor_area.ZxDjwTask;
|
|
||||||
import org.nl.b_lms.sch.tasks.first_floor_area.ZxqTask;
|
import org.nl.b_lms.sch.tasks.first_floor_area.ZxqTask;
|
||||||
import org.nl.b_lms.sch.tasks.first_floor_area.auto.TaskQueue;
|
import org.nl.b_lms.sch.tasks.first_floor_area.auto.TaskQueue;
|
||||||
|
import org.nl.b_lms.storage_manage.database.service.IBstIvtBoxinfoService;
|
||||||
|
import org.nl.b_lms.storage_manage.database.service.dao.BstIvtBoxinfo;
|
||||||
import org.nl.b_lms.storage_manage.database.service.dao.mapper.BstIvtBoxinfoMapper;
|
import org.nl.b_lms.storage_manage.database.service.dao.mapper.BstIvtBoxinfoMapper;
|
||||||
import org.nl.b_lms.storage_manage.ios.enums.IOSEnum;
|
import org.nl.b_lms.storage_manage.ios.enums.IOSEnum;
|
||||||
import org.nl.b_lms.storage_manage.ios.service.iostorInv.util.service.OutBoxManageService;
|
import org.nl.b_lms.storage_manage.ios.service.iostorInv.util.service.OutBoxManageService;
|
||||||
@@ -43,7 +44,6 @@ import org.nl.common.domain.query.PageQuery;
|
|||||||
import org.nl.common.enums.PackageInfoIvtEnum;
|
import org.nl.common.enums.PackageInfoIvtEnum;
|
||||||
import org.nl.common.utils.SecurityUtils;
|
import org.nl.common.utils.SecurityUtils;
|
||||||
import org.nl.modules.common.exception.BadRequestException;
|
import org.nl.modules.common.exception.BadRequestException;
|
||||||
import org.nl.system.service.param.ISysParamService;
|
|
||||||
import org.nl.wms.ext.mes.service.impl.LmsToMesServiceImpl;
|
import org.nl.wms.ext.mes.service.impl.LmsToMesServiceImpl;
|
||||||
import org.nl.wms.sch.manage.TaskStatusEnum;
|
import org.nl.wms.sch.manage.TaskStatusEnum;
|
||||||
import org.redisson.api.RLock;
|
import org.redisson.api.RLock;
|
||||||
@@ -79,11 +79,9 @@ public class PdmBiSubpackagerelationServiceImpl extends ServiceImpl<PdmBiSubpack
|
|||||||
private IschBaseTaskService taskService;
|
private IschBaseTaskService taskService;
|
||||||
@Resource
|
@Resource
|
||||||
private ZxqTask zxqTask;
|
private ZxqTask zxqTask;
|
||||||
@Resource
|
|
||||||
private ZxDjwTask zxDjwTask;
|
|
||||||
|
|
||||||
@Resource
|
@Resource
|
||||||
private ISysParamService iSysParamService;
|
private IBstIvtBoxinfoService iBstIvtBoxinfoService;
|
||||||
|
|
||||||
@Resource
|
@Resource
|
||||||
private LmsToMesServiceImpl lmsToMesServiceImpl;
|
private LmsToMesServiceImpl lmsToMesServiceImpl;
|
||||||
@@ -145,7 +143,6 @@ public class PdmBiSubpackagerelationServiceImpl extends ServiceImpl<PdmBiSubpack
|
|||||||
TableDataInfo<Map> build = TableDataInfo.build(mst_detail);
|
TableDataInfo<Map> build = TableDataInfo.build(mst_detail);
|
||||||
build.setTotalElements(page.getTotal());
|
build.setTotalElements(page.getTotal());
|
||||||
return build;
|
return build;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -189,15 +186,28 @@ public class PdmBiSubpackagerelationServiceImpl extends ServiceImpl<PdmBiSubpack
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 根据订单号查询子卷信息
|
* 根据订单号查询子卷信息
|
||||||
*
|
|
||||||
* @param whereJson 查询条件
|
* @param whereJson 查询条件
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public List<PdmBiSubpackagerelation> queryContainerNameBySaleOrder(Map whereJson) {
|
public List<PdmBiSubpackagerelation> queryContainerNameBySaleOrder(Map whereJson) {
|
||||||
if (!whereJson.containsKey("sale_order_name")) {
|
List<PdmBiSubpackagerelation> pdmBiSubpackagerelationList;
|
||||||
|
//请求来源
|
||||||
|
if (!whereJson.containsKey("type")) {
|
||||||
return Collections.emptyList();
|
return Collections.emptyList();
|
||||||
}
|
}
|
||||||
List<PdmBiSubpackagerelation> pdmBiSubpackagerelationList = pdmBiSubpackagerelationMapper.queryContainerNameBySaleOrder(whereJson.get("sale_order_name").toString());
|
if (whereJson.get("type").toString().equals(PackageInfoIvtEnum.REQUEST_SOURCE.code("PC"))) {
|
||||||
|
//订单号
|
||||||
|
if (!whereJson.containsKey("sale_order_name")) {
|
||||||
|
return Collections.emptyList();
|
||||||
|
}
|
||||||
|
pdmBiSubpackagerelationList = pdmBiSubpackagerelationMapper.queryContainerNameBySaleOrder(whereJson.get("sale_order_name").toString(), null);
|
||||||
|
} else {
|
||||||
|
//子卷号
|
||||||
|
if (!whereJson.containsKey("container_name")) {
|
||||||
|
return Collections.emptyList();
|
||||||
|
}
|
||||||
|
pdmBiSubpackagerelationList = pdmBiSubpackagerelationMapper.queryContainerNameBySaleOrder(null, whereJson.get("container_name").toString());
|
||||||
|
}
|
||||||
Map<String, Long> countByGroup = pdmBiSubpackagerelationList.stream()
|
Map<String, Long> countByGroup = pdmBiSubpackagerelationList.stream()
|
||||||
.filter(item -> item.getBox_group() != null)
|
.filter(item -> item.getBox_group() != null)
|
||||||
.collect(Collectors.groupingBy(PdmBiSubpackagerelation::getBox_group, Collectors.counting()));
|
.collect(Collectors.groupingBy(PdmBiSubpackagerelation::getBox_group, Collectors.counting()));
|
||||||
@@ -205,19 +215,19 @@ public class PdmBiSubpackagerelationServiceImpl extends ServiceImpl<PdmBiSubpack
|
|||||||
//获取子卷长度
|
//获取子卷长度
|
||||||
// int containerLength = getMaxNum(null, r.getPaper_tube_description());
|
// int containerLength = getMaxNum(null, r.getPaper_tube_description());
|
||||||
// r.setUn_plan_product_property3(Integer.toString(containerLength));
|
// r.setUn_plan_product_property3(Integer.toString(containerLength));
|
||||||
if (r.getBox_group() != null) {
|
if (whereJson.get("type").toString().equals(PackageInfoIvtEnum.REQUEST_SOURCE.code("PC"))) {
|
||||||
r.setQuanlity_in_box(BigDecimal.valueOf(countByGroup.getOrDefault(r.getBox_group(), null)));
|
if (r.getBox_group() != null) {
|
||||||
} else {
|
r.setQuanlity_in_box(BigDecimal.valueOf(countByGroup.getOrDefault(r.getBox_group(), null)));
|
||||||
r.setQuanlity_in_box(BigDecimal.ZERO);
|
} else {
|
||||||
r.setBox_group("0");
|
r.setQuanlity_in_box(BigDecimal.ZERO);
|
||||||
|
r.setBox_group("0");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 调用方法获取木箱料号:输入:子卷号、输出:木箱信息
|
// 调用方法获取木箱料号:输入:子卷号、输出:木箱信息
|
||||||
PdmBiOrderbominfo bomInfoDao = iPdmBiOrderbominfoService.getBiOrderbominfoByContainer(r.getContainer_name());
|
PdmBiOrderbominfo bomInfoDao = iPdmBiOrderbominfoService.getBiOrderbominfoByContainer(r.getContainer_name());
|
||||||
if (ObjectUtil.isNotEmpty(bomInfoDao)) {
|
if (ObjectUtil.isNotEmpty(bomInfoDao)) {
|
||||||
r.setBox_type(bomInfoDao.getProductName());
|
r.setBox_type(bomInfoDao.getProductName());
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
return pdmBiSubpackagerelationList;
|
return pdmBiSubpackagerelationList;
|
||||||
}
|
}
|
||||||
@@ -253,28 +263,22 @@ public class PdmBiSubpackagerelationServiceImpl extends ServiceImpl<PdmBiSubpack
|
|||||||
*
|
*
|
||||||
* @param whereJson 分配信息
|
* @param whereJson 分配信息
|
||||||
*/
|
*/
|
||||||
//@Override
|
@Override
|
||||||
@Transactional(rollbackFor = Exception.class)
|
@Transactional(rollbackFor = Exception.class)
|
||||||
public void updateEntityList8(JSONObject whereJson) {
|
public void updateEntityList(JSONObject whereJson) {
|
||||||
//todo 正式环境代码,需恢复
|
|
||||||
StopWatch stopWatch = new StopWatch();
|
|
||||||
stopWatch.start();
|
|
||||||
List<PdmBiSubpackagerelation> packagerelationList = JSONObject.parseArray(whereJson.getJSONArray("tableMater").toJSONString(), PdmBiSubpackagerelation.class);
|
List<PdmBiSubpackagerelation> packagerelationList = JSONObject.parseArray(whereJson.getJSONArray("tableMater").toJSONString(), PdmBiSubpackagerelation.class);
|
||||||
if (CollectionUtils.isEmpty(packagerelationList)) {
|
if (CollectionUtils.isEmpty(packagerelationList)) {
|
||||||
throw new BadRequestException("无选中子卷信息");
|
throw new BadRequestException("无选中子卷信息");
|
||||||
}
|
}
|
||||||
if (packagerelationList.size() > 1) {
|
|
||||||
throw new BadRequestException("暂时只能选择一个子卷");
|
|
||||||
}
|
|
||||||
//检查是否存在已分配规格的子卷号
|
//检查是否存在已分配规格的子卷号
|
||||||
List<PdmBiSubpackagerelation> isOutBox = packagerelationList.stream().filter(r -> r.getStatus().equals("0")).collect(Collectors.toList());
|
List<PdmBiSubpackagerelation> isOutBox = packagerelationList.stream().filter(r -> r.getStatus().equals("0")).collect(Collectors.toList());
|
||||||
if (isOutBox.size() > 0) {
|
if (isOutBox.size() > 0) {
|
||||||
throw new BadRequestException("标记为黄色的子卷号已分配且对应的木箱已出库,请重新选择未分配木箱规格的子卷");
|
throw new BadRequestException("标记为黄色的子卷号已分配且对应的木箱已出库,请重新选择未分配木箱规格的子卷");
|
||||||
}
|
}
|
||||||
// JSONArray jsonArray = whereJson.getJSONArray("tableMater");
|
JSONArray jsonArray = whereJson.getJSONArray("tableMater");
|
||||||
// if (jsonArray == null || jsonArray.size() == 0) {
|
if (jsonArray == null || jsonArray.size() == 0) {
|
||||||
// throw new BadRequestException("无选中子卷信息");
|
throw new BadRequestException("无选中子卷信息");
|
||||||
// }
|
}
|
||||||
//均衡获取木箱出库装箱区对接位
|
//均衡获取木箱出库装箱区对接位
|
||||||
String deviceCode = getPointCode();
|
String deviceCode = getPointCode();
|
||||||
Integer taskCount = bstIvtPackageinfoivtMapper.getZxqTaskCount(deviceCode.substring(deviceCode.lastIndexOf("_") + 1));
|
Integer taskCount = bstIvtPackageinfoivtMapper.getZxqTaskCount(deviceCode.substring(deviceCode.lastIndexOf("_") + 1));
|
||||||
@@ -303,7 +307,7 @@ public class PdmBiSubpackagerelationServiceImpl extends ServiceImpl<PdmBiSubpack
|
|||||||
.collect(Collectors.toSet());
|
.collect(Collectors.toSet());
|
||||||
List<PdmBiSlittingproductionplan> planList = iPdmBiSlittingproductionplanService.list(new LambdaQueryWrapper<PdmBiSlittingproductionplan>().in(PdmBiSlittingproductionplan::getContainer_name, containerNameList));
|
List<PdmBiSlittingproductionplan> planList = iPdmBiSlittingproductionplanService.list(new LambdaQueryWrapper<PdmBiSlittingproductionplan>().in(PdmBiSlittingproductionplan::getContainer_name, containerNameList));
|
||||||
if (CollectionUtils.isEmpty(planList)) {
|
if (CollectionUtils.isEmpty(planList)) {
|
||||||
throw new BadRequestException("该箱号不存在分切计划");
|
throw new BadRequestException("需要装箱的子卷号不存在分切计划");
|
||||||
}
|
}
|
||||||
BigDecimal totalWeight;
|
BigDecimal totalWeight;
|
||||||
totalWeight = planList.stream()
|
totalWeight = planList.stream()
|
||||||
@@ -315,59 +319,101 @@ public class PdmBiSubpackagerelationServiceImpl extends ServiceImpl<PdmBiSubpack
|
|||||||
if (totalWeight.compareTo(new BigDecimal(0)) == 0) {
|
if (totalWeight.compareTo(new BigDecimal(0)) == 0) {
|
||||||
throw new BadRequestException("分切计划的子卷重量不能为0");
|
throw new BadRequestException("分切计划的子卷重量不能为0");
|
||||||
}
|
}
|
||||||
BigDecimal boxWeight = new BigDecimal(whereJson.getString("box_weight"));
|
outBox(workIdList, containerNameList, deviceCode, maxBoxGroup, whereJson.getString("checked"), totalWeight);
|
||||||
if (boxWeight.compareTo(new BigDecimal(0)) == 0) {
|
|
||||||
throw new BadRequestException("木箱的重量不能0");
|
|
||||||
}
|
|
||||||
totalWeight = totalWeight.add(boxWeight);
|
|
||||||
if (totalWeight.compareTo(new BigDecimal(0)) == 0) {
|
|
||||||
throw new BadRequestException("理论毛重不能为0");
|
|
||||||
}
|
|
||||||
stopWatch.stop();
|
|
||||||
System.out.println("子卷装箱代码1装箱信息查询执行花费时间------------------------------------------------------------------------------------------*************************************************************************************************= totalTime = " + stopWatch.getTotalTimeMillis());
|
|
||||||
log.info("子卷装箱代码1箱信息查询执行花费时间------------------------------------------------------------------------------------------*************************************************************************************************= totalTime = " + stopWatch.getTotalTimeMillis());
|
|
||||||
outBox8(workIdList, containerNameList, deviceCode, maxBoxGroup, whereJson.getString("checked"), totalWeight.toString());
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw new BadRequestException(e.getMessage());
|
throw new BadRequestException(e.getMessage());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 子卷装箱
|
||||||
|
*
|
||||||
|
* @param whereJson 分配信息
|
||||||
|
*/
|
||||||
|
// @Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void updateEntityList8(JSONObject whereJson) {
|
||||||
|
List<PdmBiSubpackagerelation> packagerelationList = JSONObject.parseArray(whereJson.getJSONArray("tableMater").toJSONString(), PdmBiSubpackagerelation.class);
|
||||||
|
if (CollectionUtils.isEmpty(packagerelationList)) {
|
||||||
|
throw new BadRequestException("无选中子卷信息");
|
||||||
|
}
|
||||||
|
//检查是否存在已分配规格的子卷号
|
||||||
|
List<PdmBiSubpackagerelation> isOutBox = packagerelationList.stream().filter(r -> r.getStatus().equals("0")).collect(Collectors.toList());
|
||||||
|
if (isOutBox.size() > 0) {
|
||||||
|
throw new BadRequestException("标记为黄色的子卷号已分配且对应的木箱已出库,请重新选择未分配木箱规格的子卷");
|
||||||
|
}
|
||||||
|
//均衡获取木箱出库装箱区对接位
|
||||||
|
String deviceCode = getPointCode();
|
||||||
|
Integer taskCount = bstIvtPackageinfoivtMapper.getZxqTaskCount(deviceCode.substring(deviceCode.lastIndexOf("_") + 1));
|
||||||
|
if (taskCount + packagerelationList.size() > 10) {
|
||||||
|
throw new BadRequestException("子卷搬运任务数已达上限!");
|
||||||
|
}
|
||||||
|
List<PdmBiSubpackagerelation> pdmBiSubpackagerelationList = pdmBiSubpackagerelationMapper
|
||||||
|
.selectList(new LambdaQueryWrapper<PdmBiSubpackagerelation>().eq(PdmBiSubpackagerelation::getSale_order_name, packagerelationList.get(0).getSale_order_name()));
|
||||||
|
Integer maxBoxGroup = pdmBiSubpackagerelationList.stream()
|
||||||
|
.map(PdmBiSubpackagerelation::getBox_group)
|
||||||
|
.filter(Objects::nonNull)
|
||||||
|
.map(Integer::parseInt)
|
||||||
|
.max(Integer::compareTo)
|
||||||
|
.orElse(0) + 1;
|
||||||
|
List<String> workIdList = JSONObject.parseArray(whereJson.getJSONArray("tableMater").toJSONString(), PdmBiSubpackagerelation.class).stream()
|
||||||
|
.map(PdmBiSubpackagerelation::getWorkorder_id)
|
||||||
|
.map(String::valueOf)
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
if (workIdList.isEmpty()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
//根据分切计划获取子卷重量计算理论毛重
|
||||||
|
Set<String> containerNameList = packagerelationList.stream()
|
||||||
|
.map(PdmBiSubpackagerelation::getContainer_name)
|
||||||
|
.collect(Collectors.toSet());
|
||||||
|
outBox8(workIdList, containerNameList, deviceCode, maxBoxGroup, whereJson.getString("checked"));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 空木箱出库
|
* 空木箱出库
|
||||||
*/
|
*/
|
||||||
private void outBox8(List<String> workIdList, Set<String> containerNameList, String deviceCode, Integer maxBoxGroup, String boxType, String totalWeight) {
|
private void outBox(List<String> workIdList, Set<String> containerNameList, String deviceCode, Integer maxBoxGroup, String boxType, BigDecimal totalWeight) {
|
||||||
//todo 正式环境代码,需恢复
|
|
||||||
//均衡获取装箱对接位
|
|
||||||
//String deviceCode = "ZXQ_1_1";
|
|
||||||
StopWatch stopWatch = new StopWatch();
|
|
||||||
stopWatch.start();
|
|
||||||
JSONObject boxInfo = new JSONObject();
|
JSONObject boxInfo = new JSONObject();
|
||||||
//确定装箱区终点
|
//确定装箱区终点
|
||||||
boxInfo.put("device_code", deviceCode);
|
boxInfo.put("device_code", deviceCode);
|
||||||
boxInfo.put("material_code", boxType);
|
boxInfo.put("material_code", boxType);
|
||||||
boxInfo.put("num", workIdList.size());
|
boxInfo.put("num", workIdList.size());
|
||||||
String boxSn = outBoxManageService.outBox(boxInfo);
|
String boxSn = outBoxManageService.outBox(boxInfo);
|
||||||
stopWatch.stop();
|
BstIvtBoxinfo boxDao = iBstIvtBoxinfoService.getOne(
|
||||||
System.out.println("木箱出库代码执行花费时间------------------------------------------------------------------------------------------*************************************************************************************************= totalTime = " + stopWatch.getTotalTimeMillis());
|
new QueryWrapper<BstIvtBoxinfo>().lambda()
|
||||||
log.info("木箱出库代码执行花费时间------------------------------------------------------------------------------------------*************************************************************************************************= totalTime = " + stopWatch.getTotalTimeMillis());
|
.eq(BstIvtBoxinfo::getBox_no, boxSn)
|
||||||
//String boxSn = "MX230118000013";
|
);
|
||||||
|
if (StringUtils.isBlank(boxDao.getBox_weight())) {
|
||||||
|
throw new BadRequestException("木箱的重量不能为空!");
|
||||||
|
}
|
||||||
|
//木箱重量
|
||||||
|
BigDecimal boxWeight = new BigDecimal(boxDao.getBox_weight());
|
||||||
|
if (boxWeight.compareTo(new BigDecimal(0)) == 0) {
|
||||||
|
throw new BadRequestException("木箱的重量不能0");
|
||||||
|
}
|
||||||
|
totalWeight = totalWeight.add(boxWeight);
|
||||||
|
if (totalWeight.compareTo(new BigDecimal(0)) == 0) {
|
||||||
|
throw new BadRequestException("理论毛重不能为0");
|
||||||
|
}
|
||||||
StopWatch stopWatch1 = new StopWatch();
|
StopWatch stopWatch1 = new StopWatch();
|
||||||
stopWatch1.start();
|
stopWatch1.start();
|
||||||
//更新及子卷包装状态已分配规格及木箱规格组
|
//更新及子卷包装状态已分配规格及木箱规格组
|
||||||
|
String weightTotal = totalWeight.toString();
|
||||||
CompletableFuture.runAsync(() -> {
|
CompletableFuture.runAsync(() -> {
|
||||||
try {
|
try {
|
||||||
//updateBoxGroup(maxBoxGroup, workIdList, boxSn, boxType, totalWeight);
|
updateBoxGroup(maxBoxGroup, workIdList, boxSn, boxType, weightTotal);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
log.error("异常信息:" + e);
|
log.error("子卷装箱异常,更新子卷包装关系异常:" + e);
|
||||||
}
|
}
|
||||||
}, pool);
|
}, pool);
|
||||||
//给LMS传输子卷包装关系
|
//给MES传输子卷包装关系
|
||||||
CompletableFuture.runAsync(() -> {
|
CompletableFuture.runAsync(() -> {
|
||||||
try {
|
try {
|
||||||
transferBoxPackageToMes(true, null, containerNameList, boxSn, totalWeight);
|
transferBoxPackageToMes(true, null, containerNameList, boxSn, weightTotal);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
log.error("异常信息:" + e);
|
log.error("子卷装箱异常,给MES传输子卷包装关系异常:" + e);
|
||||||
}
|
}
|
||||||
}, pool);
|
}, pool);
|
||||||
//待检区->装箱区agv任务
|
//待检区->装箱区agv任务
|
||||||
@@ -375,16 +421,45 @@ public class PdmBiSubpackagerelationServiceImpl extends ServiceImpl<PdmBiSubpack
|
|||||||
try {
|
try {
|
||||||
agvTransfer(containerNameList, deviceCode, boxSn);
|
agvTransfer(containerNameList, deviceCode, boxSn);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
log.error("异常信息:" + e);
|
log.error("子卷装箱异常,待检区->装箱区agv确定起点任务创建异常:" + e);
|
||||||
}
|
}
|
||||||
}, pool);
|
}, pool);
|
||||||
stopWatch1.stop();
|
|
||||||
System.out.println("子卷装箱代码2装箱信息更新执行花费时间------------------------------------------------------------------------------------------*************************************************************************************************= totalTime = " + stopWatch1.getTotalTimeMillis());
|
|
||||||
log.info("子卷装箱代码2装箱信息更新执行花费时间------------------------------------------------------------------------------------------*************************************************************************************************= totalTime = " + stopWatch1.getTotalTimeMillis());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void updateBoxGroup(Integer maxBoxGroup, List<String> entityList, String boxSn, String boxType) {
|
/**
|
||||||
|
* 空木箱出库
|
||||||
|
*/
|
||||||
|
private void outBox8(List<String> workIdList, Set<String> containerNameList, String deviceCode, Integer
|
||||||
|
maxBoxGroup, String boxType) {
|
||||||
|
//均衡获取装箱对接位
|
||||||
|
JSONObject boxInfo = new JSONObject();
|
||||||
|
//确定装箱区终点
|
||||||
|
boxInfo.put("device_code", deviceCode);
|
||||||
|
boxInfo.put("material_code", boxType);
|
||||||
|
boxInfo.put("num", workIdList.size());
|
||||||
|
String boxSn = outBoxManageService.outBox(boxInfo);
|
||||||
|
//更新及子卷包装状态已分配规格及木箱规格组
|
||||||
|
CompletableFuture.runAsync(() -> {
|
||||||
|
try {
|
||||||
|
// updateBoxGroup(maxBoxGroup, workIdList, boxSn, boxType);
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("updateBoxGroup接口更新及子卷包装状态已分配规格及木箱规格组异常:" + e);
|
||||||
|
}
|
||||||
|
}, pool);
|
||||||
|
//待检区->装箱区agv任务
|
||||||
|
CompletableFuture.runAsync(() -> {
|
||||||
|
try {
|
||||||
|
agvTransfer(containerNameList, deviceCode, boxSn);
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("agvTransfer接口待检区->装箱区agv任务异常:" + e);
|
||||||
|
}
|
||||||
|
}, pool);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void updateBoxGroup(Integer maxBoxGroup, List<String> entityList, String boxSn, String boxType, String totalWeight) {
|
||||||
UpdateWrapper<PdmBiSubpackagerelation> updateWrapper = new UpdateWrapper<>();
|
UpdateWrapper<PdmBiSubpackagerelation> updateWrapper = new UpdateWrapper<>();
|
||||||
|
//理论毛重
|
||||||
|
updateWrapper.set("box_weight", totalWeight);
|
||||||
updateWrapper.set("package_box_sn", boxSn);
|
updateWrapper.set("package_box_sn", boxSn);
|
||||||
updateWrapper.set("quanlity_in_box", entityList.size());
|
updateWrapper.set("quanlity_in_box", entityList.size());
|
||||||
updateWrapper.set("box_type", boxType);
|
updateWrapper.set("box_type", boxType);
|
||||||
@@ -426,7 +501,6 @@ public class PdmBiSubpackagerelationServiceImpl extends ServiceImpl<PdmBiSubpack
|
|||||||
|
|
||||||
|
|
||||||
protected void agvTransfer8(Set<String> containerNameList, String deviceCode, String boxSn) {
|
protected void agvTransfer8(Set<String> containerNameList, String deviceCode, String boxSn) {
|
||||||
//todo 正式环境代码,需恢复
|
|
||||||
//待检区点位
|
//待检区点位
|
||||||
List<BstIvtPackageinfoivt> djqPointList = packageinfoivtService
|
List<BstIvtPackageinfoivt> djqPointList = packageinfoivtService
|
||||||
.list(new LambdaUpdateWrapper<BstIvtPackageinfoivt>()
|
.list(new LambdaUpdateWrapper<BstIvtPackageinfoivt>()
|
||||||
@@ -469,7 +543,7 @@ public class PdmBiSubpackagerelationServiceImpl extends ServiceImpl<PdmBiSubpack
|
|||||||
if (CollectionUtils.isEmpty(bstIvtPackageinfoivtList)) {
|
if (CollectionUtils.isEmpty(bstIvtPackageinfoivtList)) {
|
||||||
throw new BadRequestException("没有可用的装箱区对接位");
|
throw new BadRequestException("没有可用的装箱区对接位");
|
||||||
}
|
}
|
||||||
Map<String, Integer> resultMap = new HashMap<>();
|
Map<String, Integer> resultMap = new LinkedHashMap<>();
|
||||||
//获取装箱位任务数量
|
//获取装箱位任务数量
|
||||||
List<Map<String, Object>> taskCount = bstIvtPackageinfoivtMapper.getPointTaskCount();
|
List<Map<String, Object>> taskCount = bstIvtPackageinfoivtMapper.getPointTaskCount();
|
||||||
if (taskCount != null) {
|
if (taskCount != null) {
|
||||||
@@ -485,12 +559,12 @@ public class PdmBiSubpackagerelationServiceImpl extends ServiceImpl<PdmBiSubpack
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
bstIvtPackageinfoivtList.stream()
|
bstIvtPackageinfoivtList.stream()
|
||||||
.collect(Collectors.toMap(
|
.sorted(Comparator.comparing(BstIvtPackageinfoivt::getSort_seq))
|
||||||
BstIvtPackageinfoivt::getPoint_code,
|
.forEach(p -> {
|
||||||
p -> StringUtils.isNotBlank(p.getContainer_name()) ? 1 : 0,
|
String key = p.getPoint_code();
|
||||||
Integer::sum
|
int value = StringUtils.isNotBlank(p.getContainer_name()) ? 1 : 0;
|
||||||
))
|
resultMap.merge(key, value, Integer::sum);
|
||||||
.forEach((key, value) -> resultMap.merge(key, value, Integer::sum));
|
});
|
||||||
List<Map<String, Integer>> result = resultMap.entrySet().stream()
|
List<Map<String, Integer>> result = resultMap.entrySet().stream()
|
||||||
.map(entry -> Collections.singletonMap(entry.getKey(), entry.getValue()))
|
.map(entry -> Collections.singletonMap(entry.getKey(), entry.getValue()))
|
||||||
.collect(Collectors.toList());
|
.collect(Collectors.toList());
|
||||||
@@ -574,88 +648,6 @@ public class PdmBiSubpackagerelationServiceImpl extends ServiceImpl<PdmBiSubpack
|
|||||||
sub.setProduct_name("测试");
|
sub.setProduct_name("测试");
|
||||||
this.saveOrUpdate(sub);
|
this.saveOrUpdate(sub);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 子卷装箱
|
|
||||||
*
|
|
||||||
* @param whereJson 分配信息
|
|
||||||
*/
|
|
||||||
@Override
|
|
||||||
@Transactional(rollbackFor = Exception.class)
|
|
||||||
public void updateEntityList(JSONObject whereJson) {
|
|
||||||
List<PdmBiSubpackagerelation> packagerelationList = JSONObject.parseArray(whereJson.getJSONArray("tableMater").toJSONString(), PdmBiSubpackagerelation.class);
|
|
||||||
if (CollectionUtils.isEmpty(packagerelationList)) {
|
|
||||||
throw new BadRequestException("无选中子卷信息");
|
|
||||||
}
|
|
||||||
// if (packagerelationList.size() > 1) {
|
|
||||||
// throw new BadRequestException("暂时只能选择一个子卷");
|
|
||||||
// }
|
|
||||||
//检查是否存在已分配规格的子卷号
|
|
||||||
List<PdmBiSubpackagerelation> isOutBox = packagerelationList.stream().filter(r -> r.getStatus().equals("0")).collect(Collectors.toList());
|
|
||||||
if (isOutBox.size() > 0) {
|
|
||||||
throw new BadRequestException("标记为黄色的子卷号已分配且对应的木箱已出库,请重新选择未分配木箱规格的子卷");
|
|
||||||
}
|
|
||||||
//均衡获取木箱出库装箱区对接位
|
|
||||||
String deviceCode = getPointCode();
|
|
||||||
Integer taskCount = bstIvtPackageinfoivtMapper.getZxqTaskCount(deviceCode.substring(deviceCode.lastIndexOf("_") + 1));
|
|
||||||
if (taskCount + packagerelationList.size() > 10) {
|
|
||||||
throw new BadRequestException("子卷搬运任务数已达上限!");
|
|
||||||
}
|
|
||||||
List<PdmBiSubpackagerelation> pdmBiSubpackagerelationList = pdmBiSubpackagerelationMapper
|
|
||||||
.selectList(new LambdaQueryWrapper<PdmBiSubpackagerelation>().eq(PdmBiSubpackagerelation::getSale_order_name, packagerelationList.get(0).getSale_order_name()));
|
|
||||||
Integer maxBoxGroup = pdmBiSubpackagerelationList.stream()
|
|
||||||
.map(PdmBiSubpackagerelation::getBox_group)
|
|
||||||
.filter(Objects::nonNull)
|
|
||||||
.map(Integer::parseInt)
|
|
||||||
.max(Integer::compareTo)
|
|
||||||
.orElse(0) + 1;
|
|
||||||
List<String> workIdList = JSONObject.parseArray(whereJson.getJSONArray("tableMater").toJSONString(), PdmBiSubpackagerelation.class).stream()
|
|
||||||
.map(PdmBiSubpackagerelation::getWorkorder_id)
|
|
||||||
.map(String::valueOf)
|
|
||||||
.collect(Collectors.toList());
|
|
||||||
if (workIdList.isEmpty()) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
//根据分切计划获取子卷重量计算理论毛重
|
|
||||||
Set<String> containerNameList = packagerelationList.stream()
|
|
||||||
.map(PdmBiSubpackagerelation::getContainer_name)
|
|
||||||
.collect(Collectors.toSet());
|
|
||||||
outBox(workIdList, containerNameList, deviceCode, maxBoxGroup, whereJson.getString("checked"));
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 空木箱出库
|
|
||||||
*/
|
|
||||||
private void outBox(List<String> workIdList, Set<String> containerNameList, String deviceCode, Integer
|
|
||||||
maxBoxGroup, String boxType) {
|
|
||||||
//均衡获取装箱对接位
|
|
||||||
JSONObject boxInfo = new JSONObject();
|
|
||||||
//确定装箱区终点
|
|
||||||
boxInfo.put("device_code", deviceCode);
|
|
||||||
boxInfo.put("material_code", boxType);
|
|
||||||
boxInfo.put("num", workIdList.size());
|
|
||||||
String boxSn = outBoxManageService.outBox(boxInfo);
|
|
||||||
//更新及子卷包装状态已分配规格及木箱规格组
|
|
||||||
CompletableFuture.runAsync(() -> {
|
|
||||||
try {
|
|
||||||
updateBoxGroup(maxBoxGroup, workIdList, boxSn, boxType);
|
|
||||||
} catch (Exception e) {
|
|
||||||
log.error("updateBoxGroup接口更新及子卷包装状态已分配规格及木箱规格组异常:" + e);
|
|
||||||
}
|
|
||||||
}, pool);
|
|
||||||
//待检区->装箱区agv任务
|
|
||||||
CompletableFuture.runAsync(() -> {
|
|
||||||
try {
|
|
||||||
agvTransfer(containerNameList, deviceCode, boxSn);
|
|
||||||
} catch (Exception e) {
|
|
||||||
log.error("agvTransfer接口待检区->装箱区agv任务异常:" + e);
|
|
||||||
}
|
|
||||||
}, pool);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -14,6 +14,7 @@ import lombok.SneakyThrows;
|
|||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.apache.commons.collections4.CollectionUtils;
|
import org.apache.commons.collections4.CollectionUtils;
|
||||||
import org.apache.commons.lang3.StringUtils;
|
import org.apache.commons.lang3.StringUtils;
|
||||||
|
import org.nl.b_lms.pdm.info.service.IPdmBiContainerinfoService;
|
||||||
import org.nl.b_lms.pdm.subpackagerelation.service.IpdmBiSubpackagerelationService;
|
import org.nl.b_lms.pdm.subpackagerelation.service.IpdmBiSubpackagerelationService;
|
||||||
import org.nl.b_lms.sch.point.dao.BstIvtPackageinfoivt;
|
import org.nl.b_lms.sch.point.dao.BstIvtPackageinfoivt;
|
||||||
import org.nl.b_lms.sch.point.dao.mapper.BstIvtPackageinfoivtMapper;
|
import org.nl.b_lms.sch.point.dao.mapper.BstIvtPackageinfoivtMapper;
|
||||||
@@ -62,7 +63,8 @@ public class BstIvtPackageinfoivtServiceImpl extends ServiceImpl<BstIvtPackagein
|
|||||||
@Resource
|
@Resource
|
||||||
private IpdmBiSubpackagerelationService subpackagerelationService;
|
private IpdmBiSubpackagerelationService subpackagerelationService;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private IPdmBiContainerinfoService iPdmBiContainerinfoService;
|
||||||
/**
|
/**
|
||||||
* 查询数据分页
|
* 查询数据分页
|
||||||
*
|
*
|
||||||
@@ -827,7 +829,7 @@ public class BstIvtPackageinfoivtServiceImpl extends ServiceImpl<BstIvtPackagein
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
if (whereJson.getString("ivt_status").equals(PackageInfoIvtEnum.IVT_STATUS.code("合格品"))) {
|
if (whereJson.getString("ivt_status").equals(PackageInfoIvtEnum.IVT_STATUS.code("合格品"))) {
|
||||||
subpackagerelationService.createSubTest(whereJson);
|
iPdmBiContainerinfoService.createSubInfoByContainer(whereJson.getString("container_name"));
|
||||||
}
|
}
|
||||||
updateWrapper.set("container_name", dtoList.get(0).getContainer_name());
|
updateWrapper.set("container_name", dtoList.get(0).getContainer_name());
|
||||||
updateWrapper.set("ivt_status", whereJson.getString("ivt_status"));
|
updateWrapper.set("ivt_status", whereJson.getString("ivt_status"));
|
||||||
@@ -836,7 +838,7 @@ public class BstIvtPackageinfoivtServiceImpl extends ServiceImpl<BstIvtPackagein
|
|||||||
else if (StringUtils.isNotBlank(whereJson.getString("container_name")) && StringUtils.isNotBlank(whereJson.getString("pointCode"))) {
|
else if (StringUtils.isNotBlank(whereJson.getString("container_name")) && StringUtils.isNotBlank(whereJson.getString("pointCode"))) {
|
||||||
dtoList = bstIvtPackageinfoivtMapper.selectList(new LambdaQueryWrapper<BstIvtPackageinfoivt>().eq(BstIvtPackageinfoivt::getPoint_code, whereJson.getString("pointCode").equals("1") ? "ZXQ_135" : "ZXQ_136"));
|
dtoList = bstIvtPackageinfoivtMapper.selectList(new LambdaQueryWrapper<BstIvtPackageinfoivt>().eq(BstIvtPackageinfoivt::getPoint_code, whereJson.getString("pointCode").equals("1") ? "ZXQ_135" : "ZXQ_136"));
|
||||||
if (whereJson.getString("ivt_status").equals(PackageInfoIvtEnum.IVT_STATUS.code("合格品"))) {
|
if (whereJson.getString("ivt_status").equals(PackageInfoIvtEnum.IVT_STATUS.code("合格品"))) {
|
||||||
subpackagerelationService.createSubTest(whereJson);
|
iPdmBiContainerinfoService.createSubInfoByContainer(whereJson.getString("container_name"));
|
||||||
updateWrapper.set("container_name", whereJson.getString("container_name"));
|
updateWrapper.set("container_name", whereJson.getString("container_name"));
|
||||||
updateWrapper.set("ivt_status", PackageInfoIvtEnum.IVT_STATUS.code("合格品"));
|
updateWrapper.set("ivt_status", PackageInfoIvtEnum.IVT_STATUS.code("合格品"));
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -149,7 +149,7 @@ public class ZxDjwTask extends AbstractAcsTask {
|
|||||||
//5.最后一个子卷,清除装箱位木箱信息
|
//5.最后一个子卷,清除装箱位木箱信息
|
||||||
packageinfoivtService.update(null, new UpdateWrapper<BstIvtPackageinfoivt>().set("ivt_status", PackageInfoIvtEnum.IVT_STATUS.code("空")).set("container_name", null).eq("point_code", schBaseTask.getPoint_code2()));
|
packageinfoivtService.update(null, new UpdateWrapper<BstIvtPackageinfoivt>().set("ivt_status", PackageInfoIvtEnum.IVT_STATUS.code("空")).set("container_name", null).eq("point_code", schBaseTask.getPoint_code2()));
|
||||||
//清除最后一个子卷计数
|
//清除最后一个子卷计数
|
||||||
redisUtils.set(NUM_KEY, 0);
|
//redisUtils.set(NUM_KEY, 0);
|
||||||
//6.创建装箱区->待检区或管制区补空任务
|
//6.创建装箱区->待检区或管制区补空任务
|
||||||
callingVehicleToDjqOrGzq(Integer.parseInt(packagerelationList.get(0).getQuanlity_in_box().toString()));
|
callingVehicleToDjqOrGzq(Integer.parseInt(packagerelationList.get(0).getQuanlity_in_box().toString()));
|
||||||
}
|
}
|
||||||
@@ -173,7 +173,8 @@ public class ZxDjwTask extends AbstractAcsTask {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 装箱任务完成,异步调用装箱区->待检区补空任务
|
* 装箱任务完成,异步间隔调用装箱区->待检区补空任务
|
||||||
|
* <a href="https://maimai.cn/article/detail?fid=1481325336&efid=HqBFR_5bjNMzuqkNhfwv0g">...</a>
|
||||||
*/
|
*/
|
||||||
public void callingVehicleToDjqOrGzq(Integer callingNum) {
|
public void callingVehicleToDjqOrGzq(Integer callingNum) {
|
||||||
CompletableFuture.runAsync(() -> {
|
CompletableFuture.runAsync(() -> {
|
||||||
@@ -189,7 +190,7 @@ public class ZxDjwTask extends AbstractAcsTask {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
log.error("updateBoxGroup接口更新及子卷包装状态已分配规格及木箱规格组异常:" + e);
|
log.error("子卷装箱异常,子卷装箱完成,空载具->待检区或管制区任务创建失败:" + e);
|
||||||
}
|
}
|
||||||
}, pool);
|
}, pool);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -146,8 +146,14 @@ public class AutoSendZxToDjw {
|
|||||||
jo.put("is_send", IOSEnum.IS_NOTANDYES.code("是"));
|
jo.put("is_send", IOSEnum.IS_NOTANDYES.code("是"));
|
||||||
//扩展参数
|
//扩展参数
|
||||||
JSONObject param = new JSONObject();
|
JSONObject param = new JSONObject();
|
||||||
//子卷号
|
//查询是否为最后一个子卷,相同木箱号且子卷包装状态为生成
|
||||||
param.put("barcode", containerName);
|
List<PdmBiSubpackagerelation> packagerelationList = subpackageRelationService.list(new LambdaQueryWrapper<PdmBiSubpackagerelation>().eq(PdmBiSubpackagerelation::getPackage_box_sn, boxNo).eq(PdmBiSubpackagerelation::getStatus, "0"));
|
||||||
|
if (packagerelationList.size() == 1 && packagerelationList.get(0).getContainer_name().equals(containerName)) {
|
||||||
|
//最后子卷
|
||||||
|
param.put("lastOne", IOSEnum.IS_NOTANDYES.code("是"));
|
||||||
|
} else {
|
||||||
|
param.put("lastOne", IOSEnum.IS_NOTANDYES.code("否"));
|
||||||
|
}
|
||||||
//获取木箱高度等级
|
//获取木箱高度等级
|
||||||
param.put("heightLevel", getHeightLevel(bstIvtBoxinfo));
|
param.put("heightLevel", getHeightLevel(bstIvtBoxinfo));
|
||||||
//获取子卷长度
|
//获取子卷长度
|
||||||
@@ -156,26 +162,17 @@ public class AutoSendZxToDjw {
|
|||||||
param.put("maxNo", bstIvtBoxinfo.getNum());
|
param.put("maxNo", bstIvtBoxinfo.getNum());
|
||||||
//托盘类型 1小托盘 2大托盘
|
//托盘类型 1小托盘 2大托盘
|
||||||
param.put("containerType", bstIvtBoxinfo.getVehicle_type());
|
param.put("containerType", bstIvtBoxinfo.getVehicle_type());
|
||||||
//木箱计划放入子卷数量
|
//木箱需放入子卷数量
|
||||||
param.put("boxNo", relationList.get(0).getQuanlity_in_box());
|
param.put("boxNo", relationList.get(0).getQuanlity_in_box());
|
||||||
Integer num = getNumFromRedis();
|
//子卷号
|
||||||
num = num + 1;
|
param.put("barcode", containerName);
|
||||||
if (num.equals(Integer.parseInt(relationList.get(0).getQuanlity_in_box().toString()))) {
|
|
||||||
param.put("lastOne", IOSEnum.IS_NOTANDYES.code("是"));
|
|
||||||
num = 0;
|
|
||||||
} else {
|
|
||||||
param.put("lastOne", IOSEnum.IS_NOTANDYES.code("否"));
|
|
||||||
}
|
|
||||||
// 更新计数
|
|
||||||
redisUtils.set(NUM_KEY, num);
|
|
||||||
jo.put("request_param", param.toString());
|
jo.put("request_param", param.toString());
|
||||||
zxDjwTask.createTask(jo);
|
zxDjwTask.createTask(jo);
|
||||||
// try {
|
try {
|
||||||
//todo 传输子卷包装关系至MES,暂时不计算,MES会推过来
|
transferBoxPackageToMes(relationList, bstIvtBoxinfo);
|
||||||
//transferBoxPackageToMes(relationList, bstIvtBoxinfo);
|
} catch (Exception ex) {
|
||||||
// } catch (Exception ex) {
|
log.error("子卷装箱异常,传输子卷包装关系至MES接口捕获异常信息:" + ex);
|
||||||
// log.error("装箱区->装箱对接位sendZxToDjw,传输子卷包装关系至MES接口捕获异常信息:" + ex);
|
}
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@@ -194,7 +191,7 @@ public class AutoSendZxToDjw {
|
|||||||
*/
|
*/
|
||||||
public void transferBoxPackageToMes(List<PdmBiSubpackagerelation> packagerelationList, BstIvtBoxinfo bstIvtBoxinfo) {
|
public void transferBoxPackageToMes(List<PdmBiSubpackagerelation> packagerelationList, BstIvtBoxinfo bstIvtBoxinfo) {
|
||||||
if (StringUtils.isBlank(packagerelationList.get(0).getPackage_box_sn())) {
|
if (StringUtils.isBlank(packagerelationList.get(0).getPackage_box_sn())) {
|
||||||
log.info("transferBoxPackageToMes接口的子卷号:" + packagerelationList.get(0).getContainer_name() + ",子卷未确定木箱规格信息");
|
log.info("子卷装箱异常,transferBoxPackageToMes接口的子卷号:" + packagerelationList.get(0).getContainer_name() + ",子卷未确定木箱规格信息");
|
||||||
throw new BadRequestException("子卷未确定木箱规格信息!");
|
throw new BadRequestException("子卷未确定木箱规格信息!");
|
||||||
}
|
}
|
||||||
JSONObject param = new JSONObject();
|
JSONObject param = new JSONObject();
|
||||||
@@ -203,7 +200,7 @@ public class AutoSendZxToDjw {
|
|||||||
.collect(Collectors.toSet());
|
.collect(Collectors.toSet());
|
||||||
List<PdmBiSlittingproductionplan> planList = iPdmBiSlittingproductionplanService.list(new LambdaQueryWrapper<PdmBiSlittingproductionplan>().in(PdmBiSlittingproductionplan::getContainer_name, containerNameList));
|
List<PdmBiSlittingproductionplan> planList = iPdmBiSlittingproductionplanService.list(new LambdaQueryWrapper<PdmBiSlittingproductionplan>().in(PdmBiSlittingproductionplan::getContainer_name, containerNameList));
|
||||||
if (CollectionUtils.isEmpty(planList)) {
|
if (CollectionUtils.isEmpty(planList)) {
|
||||||
log.info("装箱区的子卷号为" + planList.get(0).getContainer_name() + "无对应的分切计划信息,请检查!");
|
log.info("子卷装箱异常,transferBoxPackageToMes接口的子卷号:" + packagerelationList.get(0).getContainer_name() + ",无对应的分切计划信息,请检查!");
|
||||||
throw new BadRequestException("该箱号不存在分切计划");
|
throw new BadRequestException("该箱号不存在分切计划");
|
||||||
}
|
}
|
||||||
BigDecimal totalWeight;
|
BigDecimal totalWeight;
|
||||||
@@ -214,17 +211,17 @@ public class AutoSendZxToDjw {
|
|||||||
.map(BigDecimal::new)
|
.map(BigDecimal::new)
|
||||||
.reduce(BigDecimal.ZERO, BigDecimal::add);
|
.reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||||
if (totalWeight.compareTo(new BigDecimal(0)) == 0) {
|
if (totalWeight.compareTo(new BigDecimal(0)) == 0) {
|
||||||
log.info(planList.get(0).getContainer_name()+"分切计划的子卷重量不能为0");
|
log.info("子卷装箱异常,transferBoxPackageToMes接口的子卷号:" + packagerelationList.get(0).getContainer_name() + ",分切计划的子卷重量不能为0");
|
||||||
throw new BadRequestException("分切计划的子卷重量不能为0");
|
throw new BadRequestException("分切计划的子卷重量不能为0");
|
||||||
}
|
}
|
||||||
BigDecimal boxWeight = new BigDecimal(bstIvtBoxinfo.getBox_weight());
|
BigDecimal boxWeight = new BigDecimal(bstIvtBoxinfo.getBox_weight());
|
||||||
if (boxWeight.compareTo(new BigDecimal(0)) == 0) {
|
if (boxWeight.compareTo(new BigDecimal(0)) == 0) {
|
||||||
log.info(planList.get(0).getContainer_name()+"对应的木箱的重量不能0");
|
log.info("子卷装箱异常,transferBoxPackageToMes接口的子卷号:" + packagerelationList.get(0).getContainer_name() + ",对应的木箱的重量不能0");
|
||||||
throw new BadRequestException("木箱的重量不能0");
|
throw new BadRequestException("木箱的重量不能0");
|
||||||
}
|
}
|
||||||
totalWeight = totalWeight.add(boxWeight);
|
totalWeight = totalWeight.add(boxWeight);
|
||||||
if (totalWeight.compareTo(new BigDecimal(0)) == 0) {
|
if (totalWeight.compareTo(new BigDecimal(0)) == 0) {
|
||||||
log.info(planList.get(0).getContainer_name()+"理论毛重计算有误,不能为0,请检查!");
|
log.info("子卷装箱异常,transferBoxPackageToMes接口的子卷号:" + packagerelationList.get(0).getContainer_name() + ",理论毛重计算有误,不能为0,请检查!");
|
||||||
throw new BadRequestException("理论毛重不能为0");
|
throw new BadRequestException("理论毛重不能为0");
|
||||||
}
|
}
|
||||||
//更新子卷包装关系的重量
|
//更新子卷包装关系的重量
|
||||||
@@ -244,7 +241,6 @@ public class AutoSendZxToDjw {
|
|||||||
|
|
||||||
|
|
||||||
void sendZxToDjw8() {
|
void sendZxToDjw8() {
|
||||||
//todo 正式环境代码,需恢复
|
|
||||||
//装箱位有木箱
|
//装箱位有木箱
|
||||||
List<BstIvtPackageinfoivt> zxwPackageinfoivtList = packageinfoivtService.checkEndPointTask(PackageInfoIvtEnum.POINT_STATUS.code("装箱位"), PackageInfoIvtEnum.IVT_STATUS.code("空载具"), "", PackageInfoIvtEnum.SORT_TYPE.code("升序"), PackageInfoIvtEnum.TASK_TYPE.code("装箱区->装箱对接位"));
|
List<BstIvtPackageinfoivt> zxwPackageinfoivtList = packageinfoivtService.checkEndPointTask(PackageInfoIvtEnum.POINT_STATUS.code("装箱位"), PackageInfoIvtEnum.IVT_STATUS.code("空载具"), "", PackageInfoIvtEnum.SORT_TYPE.code("升序"), PackageInfoIvtEnum.TASK_TYPE.code("装箱区->装箱对接位"));
|
||||||
if (CollectionUtils.isEmpty(zxwPackageinfoivtList)) {
|
if (CollectionUtils.isEmpty(zxwPackageinfoivtList)) {
|
||||||
@@ -312,6 +308,32 @@ public class AutoSendZxToDjw {
|
|||||||
param.put("barcode", containerName);
|
param.put("barcode", containerName);
|
||||||
jo.put("request_param", param.toString());
|
jo.put("request_param", param.toString());
|
||||||
zxDjwTask.createTask(jo);
|
zxDjwTask.createTask(jo);
|
||||||
|
//扩展参数
|
||||||
|
// JSONObject param = new JSONObject();
|
||||||
|
// //子卷号
|
||||||
|
// param.put("barcode", containerName);
|
||||||
|
// //获取木箱高度等级
|
||||||
|
// param.put("heightLevel", getHeightLevel(bstIvtBoxinfo));
|
||||||
|
// //获取子卷长度
|
||||||
|
// param.put("len", getMaxNum(productionPlanList.get(0), null));
|
||||||
|
// //木箱最大数量
|
||||||
|
// param.put("maxNo", bstIvtBoxinfo.getNum());
|
||||||
|
// //托盘类型 1小托盘 2大托盘
|
||||||
|
// param.put("containerType", bstIvtBoxinfo.getVehicle_type());
|
||||||
|
// //木箱计划放入子卷数量
|
||||||
|
// param.put("boxNo", relationList.get(0).getQuanlity_in_box());
|
||||||
|
// Integer num = getNumFromRedis();
|
||||||
|
// num = num + 1;
|
||||||
|
// if (num.equals(Integer.parseInt(relationList.get(0).getQuanlity_in_box().toString()))) {
|
||||||
|
// param.put("lastOne", IOSEnum.IS_NOTANDYES.code("是"));
|
||||||
|
// num = 0;
|
||||||
|
// } else {
|
||||||
|
// param.put("lastOne", IOSEnum.IS_NOTANDYES.code("否"));
|
||||||
|
// }
|
||||||
|
// // 更新计数
|
||||||
|
// redisUtils.set(NUM_KEY, num);
|
||||||
|
// jo.put("request_param", param.toString());
|
||||||
|
// zxDjwTask.createTask(jo);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -73,9 +73,9 @@ public class TaskQueue {
|
|||||||
zxqTask.immediateNotifyAcs(null);
|
zxqTask.immediateNotifyAcs(null);
|
||||||
log.info("待检区->装箱区agv任务编号为:"+task.getTask_code()+",任务状态为:"+task.getTask_status()+"下发完成。");
|
log.info("待检区->装箱区agv任务编号为:"+task.getTask_code()+",任务状态为:"+task.getTask_status()+"下发完成。");
|
||||||
//同步删除子卷包装关系
|
//同步删除子卷包装关系
|
||||||
LambdaQueryWrapper<PdmBiSubpackagerelation> queryWrapper = new LambdaQueryWrapper<>();
|
//LambdaQueryWrapper<PdmBiSubpackagerelation> queryWrapper = new LambdaQueryWrapper<>();
|
||||||
queryWrapper.eq(PdmBiSubpackagerelation::getContainer_name, task.getVehicle_code());
|
//queryWrapper.eq(PdmBiSubpackagerelation::getContainer_name, task.getVehicle_code());
|
||||||
pdmBiSubpackagerelationMapper.delete(queryWrapper);
|
//pdmBiSubpackagerelationMapper.delete(queryWrapper);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -18,16 +18,12 @@
|
|||||||
AND attr.lock_type = '1'
|
AND attr.lock_type = '1'
|
||||||
AND attr.is_delete = '0'
|
AND attr.is_delete = '0'
|
||||||
and attr.is_used = '1'
|
and attr.is_used = '1'
|
||||||
|
|
||||||
<if test="query.search != null and query.search != ''">
|
<if test="query.search != null and query.search != ''">
|
||||||
and (box.material_code = #{query.search}
|
and (box.material_code = #{query.search}
|
||||||
or box.material_name LIKE '%${query.search}%')
|
or box.material_name LIKE '%${query.search}%')
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
GROUP BY box.material_code
|
GROUP BY box.material_code
|
||||||
|
|
||||||
</where>
|
</where>
|
||||||
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="getBoxIvtPage" resultType="java.util.Map">
|
<select id="getBoxIvtPage" resultType="java.util.Map">
|
||||||
|
|||||||
@@ -66,7 +66,10 @@ public enum PackageInfoIvtEnum {
|
|||||||
PACK_POINT(MapOf.of("装箱对接位01", "ZXQ_1_1")),
|
PACK_POINT(MapOf.of("装箱对接位01", "ZXQ_1_1")),
|
||||||
|
|
||||||
//库存状态
|
//库存状态
|
||||||
IVT_STATUS(MapOf.of("空", "0", "空载具", "1", "有子卷", "2", "合格品", "3", "管制品", "4"));
|
IVT_STATUS(MapOf.of("空", "0", "空载具", "1", "有子卷", "2", "合格品", "3", "管制品", "4")),
|
||||||
|
|
||||||
|
//请求源
|
||||||
|
REQUEST_SOURCE(MapOf.of("PC", "0", "手持", "1"));
|
||||||
|
|
||||||
|
|
||||||
private Map<String, String> code;
|
private Map<String, String> code;
|
||||||
|
|||||||
@@ -33,7 +33,8 @@
|
|||||||
:header-cell-style="{background:'#f5f7fa',color:'#606266'}"
|
:header-cell-style="{background:'#f5f7fa',color:'#606266'}"
|
||||||
:row-key="row => row.name"
|
:row-key="row => row.name"
|
||||||
:span-method="handleSpanMethod"
|
:span-method="handleSpanMethod"
|
||||||
@row-click="handleRowClick"handleRowClick
|
handle-row-click
|
||||||
|
@row-click="handleRowClick"
|
||||||
>
|
>
|
||||||
<!-- 列的定义... -->
|
<!-- 列的定义... -->
|
||||||
<!-- <el-table-column prop="box_group" label="木箱组 " align="center" width="120">-->
|
<!-- <el-table-column prop="box_group" label="木箱组 " align="center" width="120">-->
|
||||||
@@ -45,6 +46,9 @@
|
|||||||
<el-table-column show-overflow-tooltip prop="quanlity_in_box" label="箱内子卷数" align="center" />
|
<el-table-column show-overflow-tooltip prop="quanlity_in_box" label="箱内子卷数" align="center" />
|
||||||
<el-table-column show-overflow-tooltip prop="container_name" label="子卷号" align="center" />
|
<el-table-column show-overflow-tooltip prop="container_name" label="子卷号" align="center" />
|
||||||
<el-table-column show-overflow-tooltip prop="paper_tube_description" label="子卷规格" align="center" />
|
<el-table-column show-overflow-tooltip prop="paper_tube_description" label="子卷规格" align="center" />
|
||||||
|
<el-table-column show-overflow-tooltip prop="paper_weight" label="子管重量" align="center" />
|
||||||
|
<el-table-column show-overflow-tooltip prop="weight" label="子卷重量" align="center" />
|
||||||
|
<el-table-column show-overflow-tooltip prop="box_type" label="木箱料号" align="center" />
|
||||||
</el-table>
|
</el-table>
|
||||||
</el-card>
|
</el-card>
|
||||||
<div style="margin-bottom: 20px;" />
|
<div style="margin-bottom: 20px;" />
|
||||||
@@ -117,6 +121,8 @@
|
|||||||
<el-table-column show-overflow-tooltip prop="box_group" label="木箱组" align="center" width="130" />
|
<el-table-column show-overflow-tooltip prop="box_group" label="木箱组" align="center" width="130" />
|
||||||
<el-table-column show-overflow-tooltip prop="container_name" label="子卷号" align="center" />
|
<el-table-column show-overflow-tooltip prop="container_name" label="子卷号" align="center" />
|
||||||
<el-table-column show-overflow-tooltip prop="paper_tube_description" label="子卷规格" align="center" />
|
<el-table-column show-overflow-tooltip prop="paper_tube_description" label="子卷规格" align="center" />
|
||||||
|
<el-table-column show-overflow-tooltip prop="paper_weight" label="子管重量" align="center" />
|
||||||
|
<el-table-column show-overflow-tooltip prop="weight" label="子卷重量" align="center" />
|
||||||
<el-table-column show-overflow-tooltip prop="box_type" label="木箱料号" align="center" />
|
<el-table-column show-overflow-tooltip prop="box_type" label="木箱料号" align="center" />
|
||||||
</el-table>
|
</el-table>
|
||||||
</el-card>
|
</el-card>
|
||||||
@@ -319,6 +325,7 @@ export default {
|
|||||||
const selectedRows = table2Data.filter(row => (row.container_name == groupValue) || (row.box_group === groupValue && row.box_group !== null && row.box_group !== '0'))
|
const selectedRows = table2Data.filter(row => (row.container_name == groupValue) || (row.box_group === groupValue && row.box_group !== null && row.box_group !== '0'))
|
||||||
table2.clearSelection()
|
table2.clearSelection()
|
||||||
selectedRows.forEach(row => table2.toggleRowSelection(row))
|
selectedRows.forEach(row => table2.toggleRowSelection(row))
|
||||||
|
this.box_type = ''
|
||||||
// 给木箱料号赋值
|
// 给木箱料号赋值
|
||||||
this.box_type = scope.box_type
|
this.box_type = scope.box_type
|
||||||
},
|
},
|
||||||
@@ -328,11 +335,18 @@ export default {
|
|||||||
if (selection.length > 0) {
|
if (selection.length > 0) {
|
||||||
this.isButtonDisabled = !selection.every(item => item.status === '99')
|
this.isButtonDisabled = !selection.every(item => item.status === '99')
|
||||||
this.isButtonDisabled1 = selection.some(item => item.status === '99')
|
this.isButtonDisabled1 = selection.some(item => item.status === '99')
|
||||||
|
this.box_type = ''
|
||||||
|
// 给木箱料号赋值
|
||||||
|
const box_type = selection.filter(item => item.box_type !== '' && item.box_type !== null)
|
||||||
|
if (box_type.length > 0) {
|
||||||
|
this.box_type = box_type[0].box_type
|
||||||
|
}
|
||||||
this.currentSelection = selection
|
this.currentSelection = selection
|
||||||
if (!this.searchText) {
|
if (!this.searchText) {
|
||||||
this.previousSelection = selection
|
this.previousSelection = selection
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
debugger
|
||||||
if (!this.searchText) {
|
if (!this.searchText) {
|
||||||
this.cancelSelection = []
|
this.cancelSelection = []
|
||||||
this.cancelSelection = [...this.currentSelection]
|
this.cancelSelection = [...this.currentSelection]
|
||||||
@@ -370,8 +384,8 @@ export default {
|
|||||||
this.crud.notify('子卷数量超过木箱的最大装卷数!', CRUD.NOTIFICATION_TYPE.WARNING)
|
this.crud.notify('子卷数量超过木箱的最大装卷数!', CRUD.NOTIFICATION_TYPE.WARNING)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
debugger
|
||||||
this.form.checked = row.material_code
|
this.form.checked = row.material_code
|
||||||
this.form.box_weight = row.box_weight
|
|
||||||
this.form.sale_order_name = this.saleOrderName
|
this.form.sale_order_name = this.saleOrderName
|
||||||
await crudPackagerelation.updateEntityList(this.form)
|
await crudPackagerelation.updateEntityList(this.form)
|
||||||
const res = crudSubpackagerelation.queryContainerization({ 'sale_order_name': this.saleOrderName })
|
const res = crudSubpackagerelation.queryContainerization({ 'sale_order_name': this.saleOrderName })
|
||||||
@@ -392,6 +406,12 @@ export default {
|
|||||||
const paper_tube_description = descriptionList[0].paper_tube_description
|
const paper_tube_description = descriptionList[0].paper_tube_description
|
||||||
const descriptionsAreSame = this.currentSelection.every(item => item.paper_tube_description === paper_tube_description)
|
const descriptionsAreSame = this.currentSelection.every(item => item.paper_tube_description === paper_tube_description)
|
||||||
if (descriptionsAreSame) {
|
if (descriptionsAreSame) {
|
||||||
|
// 给木箱料号赋值
|
||||||
|
const box_type = this.currentSelection.filter(item => item.box_type !== '' && item.box_type !== null)
|
||||||
|
if (box_type.length > 0) {
|
||||||
|
this.box_type = ''
|
||||||
|
this.box_type = box_type[0].box_type
|
||||||
|
}
|
||||||
this.paperTubeDescription = paper_tube_description
|
this.paperTubeDescription = paper_tube_description
|
||||||
this.structShow = true
|
this.structShow = true
|
||||||
this.$refs.child.getMsg(false)
|
this.$refs.child.getMsg(false)
|
||||||
|
|||||||
@@ -38,7 +38,6 @@
|
|||||||
@select-all="onSelectAll"
|
@select-all="onSelectAll"
|
||||||
>
|
>
|
||||||
<el-table-column type="selection" width="55" />
|
<el-table-column type="selection" width="55" />
|
||||||
<!-- <el-table-column prop="box_no" label="木箱号" :min-width="flexWidth('box_no',crud.data,'木箱号')" />-->
|
|
||||||
<el-table-column prop="material_code" label="木箱规格" :min-width="flexWidth('material_code',crud.data,'木箱规格')" />
|
<el-table-column prop="material_code" label="木箱规格" :min-width="flexWidth('material_code',crud.data,'木箱规格')" />
|
||||||
<el-table-column prop="material_name" label="物料名称" :min-width="flexWidth('material_name',crud.data,'物料名称')" />
|
<el-table-column prop="material_name" label="物料名称" :min-width="flexWidth('material_name',crud.data,'物料名称')" />
|
||||||
<el-table-column prop="box_length" label="木箱长度" />
|
<el-table-column prop="box_length" label="木箱长度" />
|
||||||
|
|||||||
@@ -225,13 +225,14 @@ export default {
|
|||||||
},
|
},
|
||||||
async divOpen() {
|
async divOpen() {
|
||||||
this.saleOrderName = this.currentRow.sale_order_name
|
this.saleOrderName = this.currentRow.sale_order_name
|
||||||
const res = await crudSubpackagerelation.queryContainerization({ 'sale_order_name': this.currentRow.sale_order_name })
|
const queryParam = { sale_order_name: this.currentRow.sale_order_name, type: '0' }
|
||||||
|
const res = await crudSubpackagerelation.queryContainerization(queryParam)
|
||||||
this.openParam = res.content
|
this.openParam = res.content
|
||||||
// this.divShow = true
|
// this.divShow = true
|
||||||
},
|
},
|
||||||
divOpen1() {
|
divOpen1() {
|
||||||
this.saleOrderName = this.currentRow.sale_order_name
|
const queryParam = { sale_order_name: this.currentRow.sale_order_name, type: '0' }
|
||||||
crudSubpackagerelation.queryContainerization({ 'sale_order_name': this.currentRow.sale_order_name }).then(res => {
|
crudSubpackagerelation.queryContainerization(queryParam).then(res => {
|
||||||
this.openParam = res.content
|
this.openParam = res.content
|
||||||
this.divShow = true
|
this.divShow = true
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -24,11 +24,11 @@ export function edit(data) {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
export function queryContainerization(params) {
|
export function queryContainerization(data) {
|
||||||
return request({
|
return request({
|
||||||
url: '/api/pdmBiSubpackagerelation/queryContainerNameBySaleOrder',
|
url: '/api/pdmBiSubpackagerelation/queryContainerNameBySaleOrder',
|
||||||
method: 'get',
|
method: 'post',
|
||||||
params
|
data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user