新增混炼示方密炼PS审批联动同步审批人功能,优化混炼示方的编辑与删除权限控制,增强用户交互体验。

This commit is contained in:
geht
2026-05-26 11:15:00 +08:00
parent 7786369a63
commit c70f7b2b90
6 changed files with 98 additions and 3 deletions

View File

@@ -407,3 +407,10 @@ jeecgboot-vue3/src/views/xslmes/mesXslRubberQuickTestMethod/MesXslRubberQuickTes
jeecgboot-vue3/src/views/xslmes/mesXslRubberQuickTestMethod/components/MesXslRubberQuickTestMethodModal.vue
jeecg-boot-module/jeecg-module-xslmes/src/main/java/org/jeecg/modules/xslmes/controller/MesXslRubberQuickTestMethodController.java
jeecgboot-vue3/src/components/jeecg/JVxeTable/src/components/cells/JVxeSelectCell.vue
-- author:cursor---date:20260526--for: 【XSLMES-20260526-A61】混炼示方密炼PS校对/审核/批准联动同步审批人 -----------
jeecg-boot-module/jeecg-module-xslmes/src/main/java/org/jeecg/modules/xslmes/service/IMesXslMixingSpecService.java
jeecg-boot-module/jeecg-module-xslmes/src/main/java/org/jeecg/modules/xslmes/service/impl/MesXslMixingSpecServiceImpl.java
jeecg-boot-module/jeecg-module-xslmes/src/main/java/org/jeecg/modules/xslmes/service/impl/MesXslMixerPsCompileServiceImpl.java
jeecgboot-vue3/src/views/xslmes/mesXslMixingSpec/MesXslMixingSpec.data.ts
jeecgboot-vue3/src/views/xslmes/mesXslMixingSpec/MesXslMixingSpecList.vue

View File

@@ -10,6 +10,7 @@ import org.jeecg.modules.xslmes.entity.MesXslMixingSpecDownStep;
import org.jeecg.modules.xslmes.entity.MesXslMixingSpecMaterial;
import org.jeecg.modules.xslmes.entity.MesXslMixingSpecStep;
import org.jeecg.modules.xslmes.entity.MesXslMixingSpecTcu;
import org.jeecg.modules.xslmes.entity.MesXslMixerPsCompile;
import org.jeecg.modules.xslmes.vo.MesXslMixingSpecPage;
public interface IMesXslMixingSpecService extends IService<MesXslMixingSpec> {
@@ -36,4 +37,14 @@ public interface IMesXslMixingSpecService extends IService<MesXslMixingSpec> {
List<Map<String, String>> queryIssueNumberOptions(String keyword);
List<Map<String, String>> queryPurposeOptions(String keyword);
//update-begin---author:cursor ---date:20260526 for【XSLMES-20260526-A61】混炼示方密炼PS审批联动同步审批人-----------
/**
* 密炼PS校对/审核/批准后按发行编号PS编码同步关联混炼示方审批人
*
* @param ps 已更新后的密炼PS编制单
* @param mixerPsTargetStatus 密炼PS目标状态proofread / audit / approve
*/
void syncFromMixerPsWorkflow(MesXslMixerPsCompile ps, String mixerPsTargetStatus);
//update-end---author:cursor ---date:20260526 for【XSLMES-20260526-A61】混炼示方密炼PS审批联动同步审批人-----------
}

View File

@@ -10,6 +10,7 @@ import org.jeecg.modules.xslmes.common.XslMesBizConstants;
import org.jeecg.modules.xslmes.entity.MesXslMixerPsCompile;
import org.jeecg.modules.xslmes.mapper.MesXslMixerPsCompileMapper;
import org.jeecg.modules.xslmes.service.IMesXslFormulaSpecService;
import org.jeecg.modules.xslmes.service.IMesXslMixingSpecService;
import org.jeecg.modules.xslmes.service.IMesXslMixerPsCompileService;
import org.jeecg.modules.xslmes.service.IMesXslRubberQuickTestStdService;
import org.springframework.beans.factory.annotation.Autowired;
@@ -26,6 +27,9 @@ public class MesXslMixerPsCompileServiceImpl extends ServiceImpl<MesXslMixerPsCo
@Autowired
private IMesXslFormulaSpecService mesXslFormulaSpecService;
@Autowired
private IMesXslMixingSpecService mesXslMixingSpecService;
@Autowired
private IMesXslRubberQuickTestStdService mesXslRubberQuickTestStdService;
@@ -61,6 +65,9 @@ public class MesXslMixerPsCompileServiceImpl extends ServiceImpl<MesXslMixerPsCo
//update-begin---author:cursor ---date:20260522 for【配合示方】密炼PS审批联动同步状态与审批人-----------
mesXslFormulaSpecService.syncFromMixerPsWorkflow(entity, targetStatus);
//update-end---author:cursor ---date:20260522 for【配合示方】密炼PS审批联动同步状态与审批人-----------
//update-begin---author:cursor ---date:20260526 for【XSLMES-20260526-A61】混炼示方密炼PS审批联动同步审批人-----------
mesXslMixingSpecService.syncFromMixerPsWorkflow(entity, targetStatus);
//update-end---author:cursor ---date:20260526 for【XSLMES-20260526-A61】混炼示方密炼PS审批联动同步审批人-----------
//update-begin---author:jiangxh ---date:20260525 for【MES】原材料检验标准PS批准后关联实验标准置已批准-----------
if ("approve".equals(targetStatus)
&& XslMesBizConstants.PS_TYPE_RAW_INSPECT_STD.equals(entity.getPsType())) {

View File

@@ -1,6 +1,7 @@
package org.jeecg.modules.xslmes.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.baomidou.mybatisplus.extension.toolkit.Db;
import jakarta.annotation.Resource;
@@ -21,6 +22,7 @@ import java.util.stream.Collectors;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils;
import org.jeecg.common.constant.CommonConstant;
import org.jeecg.common.util.oConvertUtils;
import org.jeecg.modules.mes.material.entity.MesMixerMaterial;
import org.jeecg.modules.mes.material.service.IMesMixerMaterialService;
import org.jeecg.modules.system.entity.SysCategory;
@@ -30,6 +32,7 @@ import org.jeecg.modules.xslmes.entity.MesXslMixingSpecDownStep;
import org.jeecg.modules.xslmes.entity.MesXslMixingSpecMaterial;
import org.jeecg.modules.xslmes.entity.MesXslMixingSpecStep;
import org.jeecg.modules.xslmes.entity.MesXslMixingSpecTcu;
import org.jeecg.modules.xslmes.entity.MesXslMixerPsCompile;
import org.jeecg.modules.xslmes.mapper.MesXslMixingSpecDownStepMapper;
import org.jeecg.modules.xslmes.mapper.MesXslMixingSpecMapper;
import org.jeecg.modules.xslmes.mapper.MesXslMixingSpecMaterialMapper;
@@ -782,4 +785,33 @@ public class MesXslMixingSpecServiceImpl extends ServiceImpl<MesXslMixingSpecMap
return categoryId;
}
//update-end---author:cursor ---date:20260525 for【XSLMES-20260525-A49】删除混炼示方时同步删除B/F段胶密炼物料-----------
//update-begin---author:cursor ---date:20260526 for【XSLMES-20260526-A61】混炼示方密炼PS审批联动同步审批人-----------
@Override
public void syncFromMixerPsWorkflow(MesXslMixerPsCompile ps, String mixerPsTargetStatus) {
if (ps == null || oConvertUtils.isEmpty(ps.getPsCode()) || oConvertUtils.isEmpty(mixerPsTargetStatus)) {
return;
}
LambdaUpdateWrapper<MesXslMixingSpec> wrapper = new LambdaUpdateWrapper<>();
wrapper.eq(MesXslMixingSpec::getIssueNumber, ps.getPsCode());
switch (mixerPsTargetStatus) {
case "proofread":
wrapper.set(MesXslMixingSpec::getProofreadBy, ps.getProofreadBy())
.set(MesXslMixingSpec::getProofreadTime, ps.getProofreadTime());
break;
case "audit":
wrapper.set(MesXslMixingSpec::getAuditBy, ps.getAuditBy())
.set(MesXslMixingSpec::getAuditTime, ps.getAuditTime());
break;
case "approve":
wrapper.set(MesXslMixingSpec::getApproveBy, ps.getApproveBy())
.set(MesXslMixingSpec::getApproveTime, ps.getApproveTime());
break;
default:
return;
}
wrapper.set(MesXslMixingSpec::getUpdateTime, new Date());
this.update(wrapper);
}
//update-end---author:cursor ---date:20260526 for【XSLMES-20260526-A61】混炼示方密炼PS审批联动同步审批人-----------
}