From ec434b0b4fa56ce740863486496ca1cbc83a2856 Mon Sep 17 00:00:00 2001 From: memorylkf <312904636@qq.com> Date: Tue, 10 Mar 2026 10:46:34 +0800 Subject: [PATCH 1/3] =?UTF-8?q?feat:=20[=E6=AD=A5=E9=AA=A4=E7=AE=A1?= =?UTF-8?q?=E7=90=86]=20=E6=A0=B7=E5=93=81=E5=88=86=E5=8F=96=E6=AD=A5?= =?UTF-8?q?=E9=AA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/Template/Step.vue | 15 +++ .../Template/StepComponents/qxwdx/qxjz.vue | 10 +- .../Template/StepComponents/ypfq/fq2.vue | 120 +++++++++++++++++++++ src/components/Template/StepComponents/ypfq/hh.vue | 67 ++++++++++++ 4 files changed, 211 insertions(+), 1 deletion(-) create mode 100644 src/components/Template/StepComponents/ypfq/fq2.vue create mode 100644 src/components/Template/StepComponents/ypfq/hh.vue diff --git a/src/components/Template/Step.vue b/src/components/Template/Step.vue index 22e2934..756dc7f 100644 --- a/src/components/Template/Step.vue +++ b/src/components/Template/Step.vue @@ -149,6 +149,12 @@ import qxlx from './StepComponents/qxwdx/qxlx.vue';//全血稳定性-全血离 //全血稳定性-全血取样:使用全血稳定性-全血静置 //全血稳定性-静置后离心:使用全血稳定性-全血离心 + +//样品分取 +import fq2 from './StepComponents/ypfq/fq2.vue';//样品分取-分取2 +//样品分取-分取3:使用样品分取-分取2 +import hh from './StepComponents/ypfq/hh.vue';//样品分取-混合 + import { public_templateStepList } from '@/api/business/public/public'; @@ -289,6 +295,10 @@ export default { qxfz, qxjz, qxlx, + + //样品分取 + fq2, + hh, }, computed: { stepComponentMap() { @@ -399,6 +409,11 @@ export default { 'qxlx':'qxlx', 'qxqy':'qxjz', 'jzhlx':'qxlx', + + //样品分取 + 'fq2':'fq2', + 'fq3':'fq2', + 'hh':'hh', } } diff --git a/src/components/Template/StepComponents/qxwdx/qxjz.vue b/src/components/Template/StepComponents/qxwdx/qxjz.vue index c80c673..85b3735 100644 --- a/src/components/Template/StepComponents/qxwdx/qxjz.vue +++ b/src/components/Template/StepComponents/qxwdx/qxjz.vue @@ -66,7 +66,7 @@ export default { compareTo: "yjhj", }, text6: { - label: this.sn==='qxqy'?"条件下暂存,作为":"条件下静置,即稳定性", + label: this.sn==='qxqy'?"条件下暂存至":"条件下静置,即稳定性", type: "text", }, } @@ -93,6 +93,14 @@ export default { fillType: "actFill", otherCode: "ccwzOther", } + config[0].config.text8 = { + type: "text", + label: "作为", + } + config[0].config.yp = { + type: "input", + fillType: "actFill", + } config[0].config.text9 = { type: "text", label: "样品。", diff --git a/src/components/Template/StepComponents/ypfq/fq2.vue b/src/components/Template/StepComponents/ypfq/fq2.vue new file mode 100644 index 0000000..cf24a01 --- /dev/null +++ b/src/components/Template/StepComponents/ypfq/fq2.vue @@ -0,0 +1,120 @@ + + + + + + \ No newline at end of file diff --git a/src/components/Template/StepComponents/ypfq/hh.vue b/src/components/Template/StepComponents/ypfq/hh.vue new file mode 100644 index 0000000..9273c07 --- /dev/null +++ b/src/components/Template/StepComponents/ypfq/hh.vue @@ -0,0 +1,67 @@ + + + + + + \ No newline at end of file From 9af54706c44505d552866083f99998936447843e Mon Sep 17 00:00:00 2001 From: memorylkf <312904636@qq.com> Date: Tue, 10 Mar 2026 11:12:33 +0800 Subject: [PATCH 2/3] =?UTF-8?q?feat:=20[=E6=AD=A5=E9=AA=A4=E7=AE=A1?= =?UTF-8?q?=E7=90=86]=20=E7=BB=84=E7=BB=87=E6=B8=85=E6=B4=97=E6=AD=A5?= =?UTF-8?q?=E9=AA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/Template/Step.vue | 16 +++++ src/components/Template/StepComponents/zzqx/qx.vue | 59 +++++++++++++++++++ src/components/Template/StepComponents/zzqx/qy.vue | 47 +++++++++++++++ src/components/Template/StepComponents/zzqx/zc.vue | 68 ++++++++++++++++++++++ src/components/Template/mixins/stepMixins.js | 2 +- 5 files changed, 191 insertions(+), 1 deletion(-) create mode 100644 src/components/Template/StepComponents/zzqx/qx.vue create mode 100644 src/components/Template/StepComponents/zzqx/qy.vue create mode 100644 src/components/Template/StepComponents/zzqx/zc.vue diff --git a/src/components/Template/Step.vue b/src/components/Template/Step.vue index 756dc7f..6c0071e 100644 --- a/src/components/Template/Step.vue +++ b/src/components/Template/Step.vue @@ -155,6 +155,12 @@ import fq2 from './StepComponents/ypfq/fq2.vue';//样品分取-分取2 //样品分取-分取3:使用样品分取-分取2 import hh from './StepComponents/ypfq/hh.vue';//样品分取-混合 + +//组织清洗 +import qx from './StepComponents/zzqx/qx.vue';//组织清洗-清洗 +import zc from './StepComponents/zzqx/zc.vue';//组织清洗-暂存 +import qy from './StepComponents/zzqx/qy.vue';//组织清洗-弃液 + import { public_templateStepList } from '@/api/business/public/public'; @@ -299,6 +305,11 @@ export default { //样品分取 fq2, hh, + + //组织清洗 + qx, + zc, + qy, }, computed: { stepComponentMap() { @@ -415,6 +426,11 @@ export default { 'fq3':'fq2', 'hh':'hh', + //组织清洗 + 'qx':'qx', + 'zc':'zc', + 'qy':'qy', + } } return this.componentMap diff --git a/src/components/Template/StepComponents/zzqx/qx.vue b/src/components/Template/StepComponents/zzqx/qx.vue new file mode 100644 index 0000000..cc9beb2 --- /dev/null +++ b/src/components/Template/StepComponents/zzqx/qx.vue @@ -0,0 +1,59 @@ + + + + + + \ No newline at end of file diff --git a/src/components/Template/StepComponents/zzqx/qy.vue b/src/components/Template/StepComponents/zzqx/qy.vue new file mode 100644 index 0000000..dccd533 --- /dev/null +++ b/src/components/Template/StepComponents/zzqx/qy.vue @@ -0,0 +1,47 @@ + + + + + + \ No newline at end of file diff --git a/src/components/Template/StepComponents/zzqx/zc.vue b/src/components/Template/StepComponents/zzqx/zc.vue new file mode 100644 index 0000000..2d9fb8a --- /dev/null +++ b/src/components/Template/StepComponents/zzqx/zc.vue @@ -0,0 +1,68 @@ + + + + + + \ No newline at end of file diff --git a/src/components/Template/mixins/stepMixins.js b/src/components/Template/mixins/stepMixins.js index 469366b..c5b7ccf 100644 --- a/src/components/Template/mixins/stepMixins.js +++ b/src/components/Template/mixins/stepMixins.js @@ -2,7 +2,7 @@ export default { dicts:[ "business_tjdw","business_czhj","business_rqcz","business_zldw", "business_yqscdw","business_zsdw","business_wddw","business_ccwz","business_ggdw", - "business_hjxx" + "business_hjxx","business_zzzc" ], props: { formData: { From fc1b46418c36ee6469fba82508f2016819c2574f Mon Sep 17 00:00:00 2001 From: HanLong <404402223@qq.com> Date: Tue, 10 Mar 2026 14:52:20 +0800 Subject: [PATCH 3/3] =?UTF-8?q?feat:[=E6=A8=A1=E6=9D=BF=E7=AE=A1=E7=90=86]?= =?UTF-8?q?[PCR008]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/lang/en/template/pcr.js | 2 +- src/lang/zh/template/pcr.js | 4 +- .../business/comps/template/comps/pcr/PCR008.vue | 140 +++++++++++++++------ .../comps/template/formConfig/PCRTableConfig.js | 9 +- 4 files changed, 107 insertions(+), 48 deletions(-) diff --git a/src/lang/en/template/pcr.js b/src/lang/en/template/pcr.js index 72e860b..6be5868 100644 --- a/src/lang/en/template/pcr.js +++ b/src/lang/en/template/pcr.js @@ -52,7 +52,7 @@ export default { ypmc: '样品名称', cyqypgsjyjtjtj: '采样前样品管试剂预计添加体积', cyqypgsjsjtjtj: '采样前样品管试剂实际添加体积', - cygzl: '采集管重量', + cjgzl: '采集管重量', czsj: '称重时间', clpbh: 'Analysis Batch Number', ypmc: '样品名称', diff --git a/src/lang/zh/template/pcr.js b/src/lang/zh/template/pcr.js index 4e51090..af4ca3c 100644 --- a/src/lang/zh/template/pcr.js +++ b/src/lang/zh/template/pcr.js @@ -51,7 +51,7 @@ export default { ypmc: '样品名称', cyqypgsjyjtjtj: '采样前样品管试剂预计添加体积', cyqypgsjsjtjtj: '采样前样品管试剂实际添加体积', - cygzl: '采集管重量', + cjgzl: '采集管重量', czsj: '称重时间', clpbh: 'Analysis Batch Number', ypmc: '样品名称', @@ -66,7 +66,7 @@ export default { }, pcr008: { czb: '称重表', - clsj: 'Work Time', + clsj: '处理时间', yjry: '匀浆溶液', bs: '倍数', yjyjry: '已加匀浆溶液', diff --git a/src/views/business/comps/template/comps/pcr/PCR008.vue b/src/views/business/comps/template/comps/pcr/PCR008.vue index df299c2..1983f58 100644 --- a/src/views/business/comps/template/comps/pcr/PCR008.vue +++ b/src/views/business/comps/template/comps/pcr/PCR008.vue @@ -15,7 +15,8 @@
+ :formConfig="stepFormConfig" @blur="onHandleBlur" :formData="formData" + @beforeReagentSubmit="onBeforeReagentSubmit" @onRegentSubmit="onRegentSubmit" />
{{ $t('form.delete') }} @@ -230,16 +231,66 @@ export default { this.onHandleTableBlur() }, methods: { - onRegentSubmit(data){ - console.log(data,"回调") + onBeforeReagentSubmit(data) { + const { selectData, callback } = data; + + let selectedRows = selectData.selectedRows + let cjgzlUnit; + let error = false; + if (selectedRows) { + selectedRows.forEach(item => { + let bdnr = JSON.parse(item.bdnr) + if (!cjgzlUnit) { + cjgzlUnit = bdnr.headerSelectFields.cjgzlUnit + } + if (cjgzlUnit != bdnr.headerSelectFields.cjgzlUnit) { + error = true + } + }) + } + if (error) { + callback.prevent("所选表单单位不一致,请重新选择") + } + + }, + onRegentSubmit(data) { + let addRows = [] + let selectedRows = data.selectInfo.selectedRows + let cjgzlUnit; + + if (selectedRows) { + selectedRows.forEach(item => { + let bdnr = JSON.parse(item.bdnr) + if (!cjgzlUnit) { + cjgzlUnit = bdnr.headerSelectFields.cjgzlUnit + } + if (bdnr.stepTableFormData) { + bdnr.stepTableFormData.forEach(row => { + addRows.push({ + ypmc: row.ypmc, + cjgz: row.cjgzl, + targetStartSolutionVolumePrecision: 3, + targetDiluentVolumePrecision: 3 + }) + }) + } + }) + if (addRows) { + this.$refs.stepTableRef.addRows(addRows) + let content = this.getFilledFormData(); + setTimeout(() => { + this.justUpdateFilledFormData(); + }, 100); + } + } }, onClickDelete() { this.$modal.confirm(this.$t('form.confirmDelete')).then(() => { - this.$refs.stepTableRef.deleteSelectedRows(this.deleteRows) - this.$refs.stepTableRef.justUpdateFilledFormData(); + setTimeout(() => { + this.justUpdateFilledFormData(); + }, 100); }).catch(() => { }); - }, handleSelectionChange(row) { this.deleteRows = [] @@ -259,17 +310,35 @@ export default { let content = this.getFilledFormData(); let bs = content.bs - content + let yjyjry = content.yjyjry + let yjyjryUnit = content.yjyjryUnit + if (this.fillType === "actFill") { let tableList = content.stepTableFormData if (tableList && tableList.length > 0) { for (let i = 0; i < tableList.length; i++) { let item = tableList[i] - let cqzl = item.cqzl * bs - // 组织重量 乘以 倍数 )减去 已加匀浆溶液 + console.log(item) + let lzzcz = item.lzzcz + let cjgz = item.cjgz + let tabZzzl; + // 组织重量 = 连组织称重 减去 采集管重 + if(lzzcz && cjgz) { + let temp = subTj([lzzcz, cjgz], [content.headerSelectFields.lzzczUnit, content.headerSelectFields.cjgzUnit]) + let zzzl = temp.total + let zzzlUnit = temp.unit + tabZzzl = volumeConverter.convert(zzzl + zzzlUnit, content.headerSelectFields.zzzlUnit) + tableList[i].zzzl = tabZzzl + } + // 预设匀浆溶液补加入量 = (组织重量 乘以 倍数 )减去 已加匀浆溶液 - let ysyjrybjrl = volumeConverter.convert(cqzl + content.headerSelectFields.cqzlUnit, content.headerSelectFields.ysyjrybjrlUnit) - tableList[i].ysyjrybjrl = ysyjrybjrl + if(tabZzzl && bs && yjyjry) { + let temp = subTj([tabZzzl * bs, yjyjry], [content.headerSelectFields.zzzlUnit, yjyjryUnit]) + let ysyjrybjrl = temp.total + let ysyjrybjrlUnit = temp.unit + ysyjrybjrl = volumeConverter.convert(ysyjrybjrl + ysyjrybjrlUnit, content.headerSelectFields.ysyjrybjrlUnit) + tableList[i].ysyjrybjrl = ysyjrybjrl + } } } this.$refs.stepTableRef.updateDataSource(tableList); @@ -289,36 +358,25 @@ export default { //生成resource let tmpResource = [] if (this.fillType === "actFill") { - let tableList = content.stepTableFormData - if (tableList && tableList.length > 0) { - for (let i = 0; i < tableList.length; i++) { - //配置的试剂 - let item = tableList[i] - console.log('表格item:' + JSON.stringify(item)) - - //使用的 - - tmpResource.push({ - mc: null, - bh: content.subSolution, - ph: null, - ndz: null, - nd: null, - nddw: null, - ly: 'ELN配制', - sxrq: null, - kc: null, - kcdw: null, - syl: item.ysxsyxytj, - type: 1, - elnType: this.product, - syldw: content.headerSelectFields.sjxsyxytjUnit, - yxzq: null, - yxzqdw: null, - }) - - } - } + //使用的 + tmpResource.push({ + mc: null, + bh: content.yjrybh, + ph: null, + ndz: null, + nd: null, + nddw: null, + ly: null, + sxrq: null, + kc: null, + kcdw: null, + syl: content.yjyjry, + type: 1, + elnType: this.product, + syldw: content.yjyjryUnit, + yxzq: null, + yxzqdw: null, + }) } if (tmpResource.length > 0) { tmpResource = uniqeResourceOne(tmpResource) diff --git a/src/views/business/comps/template/formConfig/PCRTableConfig.js b/src/views/business/comps/template/formConfig/PCRTableConfig.js index 51e3074..c7f49f7 100644 --- a/src/views/business/comps/template/formConfig/PCRTableConfig.js +++ b/src/views/business/comps/template/formConfig/PCRTableConfig.js @@ -735,12 +735,12 @@ export const getPCR007Config = ($this) => { bodyMaxlength: 10, }, { - label: 'template.pcr.pcr007.cygzl', - prop: 'cygzl', + label: 'template.pcr.pcr007.cjgzl', + prop: 'cjgzl', width: 280, showWidth: 180, fillType: 'preFill', - headerSelectKey: 'cygzlUnit', + headerSelectKey: 'cjgzlUnit', headerOptions: $this.getDictOptions('business_tjdw'), bodyType: 'inputNumber', bodyFillType: 'actFill', @@ -794,10 +794,11 @@ export const getPCR008Config = ($this) => { bodyType: 'inputNumber', bodyFillType: 'actFill', bodyMaxlength: 10, - bodySubType: 'inputNumber', bodyFillType: 'actFill', bodySubType: 'button', bodySubButtonName: 'form.hqz', + bodySubFillType: 'actFill', + showBodySub: $this.fillType === 'actFill', }, { label: 'template.pcr.pcr008.zzzl',