diff --git a/src/views/modules/erf/components/expTriConfirm.vue b/src/views/modules/erf/components/expTriConfirm.vue index be7c8f3..f1d9101 100644 --- a/src/views/modules/erf/components/expTriConfirm.vue +++ b/src/views/modules/erf/components/expTriConfirm.vue @@ -512,6 +512,10 @@ export default { type: String, required: true }, + buNo: { + type: String, + required: true + }, height: { type: String, default: '35vh' @@ -762,12 +766,12 @@ export default { } let text = this.batchProcessInput.trim() - + // 检查是否包含明确的分隔符 - const hasExplicitSeparator = /[\+、,,;;\|]/.test(text) || - /\d+[\.\)]/.test(text) || + const hasExplicitSeparator = /[\+、,,;;\|]/.test(text) || + /\d+[\.\)]/.test(text) || /然后|接着|再做|再进行|之后/.test(text) - + // 智能解析输入,支持多种分隔符和格式 text = text // 处理数字序号:1. 2. 或 1) 2) 或 1、 2、 @@ -779,7 +783,7 @@ export default { .replace(/[\+、,,;;\|]/g, '\n') // 中文连接词 .replace(/然后|接着|再做|再进行|之后/g, '\n') - + // 如果没有明确分隔符,将空格(包括单个空格)也视为分隔符 if (!hasExplicitSeparator) { text = text.replace(/\s+/g, '\n') @@ -787,7 +791,7 @@ export default { // 有明确分隔符时,只处理多个空格 text = text.replace(/\s{2,}/g, '\n') } - + // 分割并清理 let names = text.split('\n') .map(n => n.trim()) @@ -1060,12 +1064,13 @@ export default { }, /** - * 加载工序模版列表 + * 加载工序模版列表(根据BU过滤) */ loadTemplateList() { this.templateLoading = true getProcessTemplateList({ - site: this.$store.state.user.site + site: this.$store.state.user.site, + buNo: this.buNo }).then(({data}) => { this.templateLoading = false if (data && data.code === 0) { @@ -1141,6 +1146,7 @@ export default { }).then(() => { saveProcessTemplate({ site: this.$store.state.user.site, + buNo: this.buNo, templateName: this.processForm.processStep.trim(), prodApproverName: this.processForm.prodApproverName, prodApproverUserId: this.processForm.prodApproverUserId, @@ -1152,6 +1158,8 @@ export default { }).then(({data}) => { if (data && data.code === 0) { this.$message.success('保存模版成功') + // 刷新模版列表 + this.loadTemplateList() } else { this.$message.error(data.msg || '保存模版失败') } @@ -1179,13 +1187,14 @@ export default { }, /** - * 加载人员列表 + * 加载人员列表(根据BU过滤) */ loadUserList(roleType) { this.userLoading = true getUserListByRole({ roleType: roleType, - site: this.$store.state.user.site + site: this.$store.state.user.site, + buNo: this.buNo }).then(({data}) => { this.userLoading = false if (data && data.code === 0) { diff --git a/src/views/modules/erf/expApplyList.vue b/src/views/modules/erf/expApplyList.vue index 10be19b..a91888f 100644 --- a/src/views/modules/erf/expApplyList.vue +++ b/src/views/modules/erf/expApplyList.vue @@ -290,6 +290,7 @@ v-if="currentRow.applyNo&¤tRow.experimentType==='High Risk'" ref="triConfirm" :apply-no="currentRow.applyNo" + :bu-no="currentRow.buNo" :experiment-type="currentRow.experimentType" :height="detailHeight">