From 4e232fb9713bb2bec27cb1401b727891f9e2938a Mon Sep 17 00:00:00 2001 From: memorylkf <312904636@qq.com> Date: Thu, 26 Mar 2026 14:40:31 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20[=E6=96=87=E6=A1=88=E4=BF=AE=E6=94=B9]?= =?UTF-8?q?=20=E9=85=8D=E7=BD=AE->=E9=85=8D=E5=88=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/business/sj/sj.js | 6 +- src/api/system/config.js | 6 +- src/assets/images/dark.svg | 2 +- src/assets/images/light.svg | 2 +- src/components/Editor/index.vue | 2 +- src/components/Template/CustomTable.vue | 8 +- src/components/Template/README.md | 14 +- src/components/Template/Step.vue | 158 +-- .../Template/StepComponents/ContainerStep.vue | 2 +- .../Template/StepComponents/ZLSubPackage.vue | 2 +- .../Template/mixins/formPackageMixins.js | 1215 ++++++++-------- src/components/Template/mixins/stepMixins.js | 256 ++-- .../Template/operation/TableOpertaion.vue | 6 +- src/lang/en.js | 2 +- src/lang/en/business/study/studyEnter.js | 2 +- src/lang/en/template/gsp.js | 44 +- src/lang/zh.js | 4 +- src/lang/zh/business/study/studyEnter.js | 15 +- src/lang/zh/business/study/studyFormPlan.js | 4 +- src/lang/zh/system/template.js | 2 +- src/lang/zh/template/gsp.js | 46 +- src/layout/components/Settings/index.vue | 6 +- src/router/index.js | 4 +- src/settings.js | 4 +- src/utils/request.js | 2 +- .../business/comps/template/comps/bl/BL001.vue | 4 +- .../business/comps/template/comps/bl/BL002.vue | 6 +- .../business/comps/template/comps/dj/DJ001.vue | 8 +- .../business/comps/template/comps/dj/DJ002.vue | 4 +- .../business/comps/template/comps/dj/DJ003.vue | 4 +- .../business/comps/template/comps/dl/DL003.vue | 4 +- .../business/comps/template/comps/dl/DL004.vue | 4 +- .../business/comps/template/comps/dl/DL005.vue | 4 +- .../business/comps/template/comps/dl/DL006.vue | 22 +- .../business/comps/template/comps/dl/DL007.vue | 4 +- .../business/comps/template/comps/dl/DL008.vue | 22 +- .../business/comps/template/comps/dl/DL009.vue | 32 +- .../business/comps/template/comps/dl/DL010.vue | 4 +- .../business/comps/template/comps/dl/DL011.vue | 4 +- .../business/comps/template/comps/dl/DL012.vue | 10 +- .../business/comps/template/comps/dl/DL013.vue | 14 +- .../business/comps/template/comps/dl/DL014.vue | 14 +- .../business/comps/template/comps/dl/DL015.vue | 8 +- .../business/comps/template/comps/dl/DL016.vue | 4 +- .../business/comps/template/comps/dl/DL017.vue | 4 +- .../business/comps/template/comps/dl/DL018.vue | 4 +- .../business/comps/template/comps/dl/DL019.vue | 4 +- .../business/comps/template/comps/dl/DL020.vue | 4 +- .../business/comps/template/comps/dl/DL021.vue | 4 +- .../business/comps/template/comps/dl/DL022.vue | 4 +- .../business/comps/template/comps/dl/DL023.vue | 4 +- .../business/comps/template/comps/dl/DL024.vue | 4 +- .../comps/template/comps/gsp/DMYPPZJLB.vue | 8 +- .../business/comps/template/comps/gsp/GSP001.vue | 8 +- .../business/comps/template/comps/gsp/GSP002.vue | 12 +- .../business/comps/template/comps/gsp/GSP003.vue | 8 +- .../business/comps/template/comps/gsp/GSP004.vue | 12 +- .../business/comps/template/comps/gsp/GSP005.vue | 12 +- .../business/comps/template/comps/gsp/GSP009.vue | 12 +- .../business/comps/template/comps/gsp/GSP010.vue | 6 +- .../business/comps/template/comps/gsp/GSP015.vue | 10 +- .../business/comps/template/comps/gsp/MJYLQSQD.vue | 4 +- .../comps/template/comps/gsp/SYWZPZJHB.vue | 8 +- .../business/comps/template/comps/lba/LBA002.vue | 6 +- .../business/comps/template/comps/lba/LBA003.vue | 6 +- .../business/comps/template/comps/lba/LBA004.vue | 16 +- .../business/comps/template/comps/lba/LBA006.vue | 10 +- .../business/comps/template/comps/lba/LBA008.vue | 10 +- .../business/comps/template/comps/pcr/PCR005.vue | 12 +- .../business/comps/template/comps/pcr/PCR007.vue | 10 +- .../business/comps/template/comps/pcr/PCR008.vue | 8 +- .../business/comps/template/comps/pcr/PCR009.vue | 12 +- .../business/comps/template/comps/pcr/PCR010.vue | 10 +- .../business/comps/template/comps/pcr/PCR011.vue | 10 +- .../business/comps/template/comps/pcr/PCR012.vue | 14 +- .../business/comps/template/comps/sp/Demo.vue | 2 +- .../business/comps/template/comps/sp/SP001.vue | 10 +- .../business/comps/template/comps/sp/SP0019.vue | 6 +- .../business/comps/template/comps/sp/SP0020.vue | 4 +- .../business/comps/template/comps/sp/SP0021.vue | 10 +- .../business/comps/template/comps/sp/SP003.vue | 10 +- .../business/comps/template/comps/sp/SP00456.vue | 20 +- .../business/comps/template/comps/sp/SP007.vue | 8 +- .../business/comps/template/comps/sp/SP008.vue | 8 +- .../business/comps/template/comps/sp/SP009.vue | 10 +- .../comps/template/comps/sp/comps/LadderConfig.vue | 14 +- .../business/comps/template/comps/xb/XB001.vue | 10 +- .../business/comps/template/comps/yp/YP002.vue | 4 +- .../business/comps/template/comps/yp/YP003.vue | 4 +- .../business/comps/template/comps/yp/YP004.vue | 4 +- .../business/comps/template/comps/yp/YP005.vue | 4 +- .../comps/template/formConfig/PCRTableConfig.js | 8 +- .../formConfig/SWYPFXFFXYPZBBTableConfig.js | 2 +- .../template/formConfig/paralleAndLadderConfig.js | 131 +- .../comps/template/formConfig/sp/SP0019.js | 279 ++-- .../comps/template/formConfig/sp/SP0020.js | 276 ++-- .../business/comps/template/formConfig/xb/xb001.js | 696 ++++----- .../comps/template/mixins/templateMixin.js | 1490 ++++++++++---------- src/views/business/study/comp/tbbd/Xq.vue | 2 +- src/views/business/template/list.vue | 4 +- src/views/lblh/components/AutoSaveTextarea.vue | 2 +- src/views/lblh/index.vue | 2 +- src/views/system/config/index.vue | 2 +- src/views/system/dict/data.vue | 2 +- src/views/system/dict/index.vue | 2 +- src/views/system/role/index.vue | 2 +- src/views/system/user/index.vue | 2 +- src/views/tool/gen/index.vue | 2 +- 108 files changed, 2745 insertions(+), 2533 deletions(-) diff --git a/src/api/business/sj/sj.js b/src/api/business/sj/sj.js index 47448a6..88ab057 100644 --- a/src/api/business/sj/sj.js +++ b/src/api/business/sj/sj.js @@ -161,7 +161,7 @@ export function sj_subpackage(data) { data: data }) } -// 开始配置 +// 开始配制 export function sj_startConfiguration(data) { return request({ url: '/system/business/studyFormFill/startConfiguration', @@ -169,7 +169,7 @@ export function sj_startConfiguration(data) { data: data }) } -// 完成配置 +// 完成配制 export function sj_configurationCompleted(data) { return request({ url: '/system/business/studyFormFill/configurationCompleted', @@ -185,4 +185,4 @@ export function exportDetail(query) { method: 'get', params: query }) -} \ No newline at end of file +} diff --git a/src/api/system/config.js b/src/api/system/config.js index a404d82..4d7eed2 100644 --- a/src/api/system/config.js +++ b/src/api/system/config.js @@ -25,7 +25,7 @@ export function getConfigKey(configKey) { }) } -// 新增参数配置 +// 新增参数配制 export function addConfig(data) { return request({ url: '/system/config', @@ -34,7 +34,7 @@ export function addConfig(data) { }) } -// 修改参数配置 +// 修改参数配制 export function updateConfig(data) { return request({ url: '/system/config', @@ -43,7 +43,7 @@ export function updateConfig(data) { }) } -// 删除参数配置 +// 删除参数配制 export function delConfig(configId) { return request({ url: '/system/config/' + configId, diff --git a/src/assets/images/dark.svg b/src/assets/images/dark.svg index f646bd7..dd0fc1f 100644 --- a/src/assets/images/dark.svg +++ b/src/assets/images/dark.svg @@ -19,7 +19,7 @@ - + diff --git a/src/assets/images/light.svg b/src/assets/images/light.svg index ab7cc08..5cad3ff 100644 --- a/src/assets/images/light.svg +++ b/src/assets/images/light.svg @@ -19,7 +19,7 @@ - + diff --git a/src/components/Editor/index.vue b/src/components/Editor/index.vue index 61fe98e..466691b 100644 --- a/src/components/Editor/index.vue +++ b/src/components/Editor/index.vue @@ -72,7 +72,7 @@ export default { bounds: document.body, debug: "warn", modules: { - // 工具栏配置 + // 工具栏配制 toolbar: [ ["bold", "italic", "underline", "strike"], // 加粗 斜体 下划线 删除线 ["blockquote", "code-block"], // 引用 代码块 diff --git a/src/components/Template/CustomTable.vue b/src/components/Template/CustomTable.vue index 842239a..2c28231 100644 --- a/src/components/Template/CustomTable.vue +++ b/src/components/Template/CustomTable.vue @@ -507,7 +507,7 @@ export default { getOperationColumns() { return { columnsData: this.columns, headerSelectFields: this.headerSelectFields,fieldItemLabel: this.fieldItemLabel } }, - //获取其他下拉框的配置 + //获取其他下拉框的配制 getOtherItem(sItem) { return { label: sItem.otherLabel ? this.$t(sItem.otherLabel) : this.$t("template.common.other"), @@ -936,7 +936,7 @@ export default { // 优先从行数据中获取动态label(如jzbh1Label) item.checkboxLabel = currentItem[dynamicLabelKey]; } else if (col.checkboxLabel !== undefined && col.checkboxLabel !== '') { - // 否则使用列配置的checkboxLabel + // 否则使用列配制的checkboxLabel item.checkboxLabel = this.$t(col.checkboxLabel); } if (col.bodyType === "operableInput" ) { @@ -1151,7 +1151,7 @@ export default { onBlur(rowIndex, colKey) { const value = this.localDataSource[rowIndex][colKey]; - // 查找对应的列配置 + // 查找对应的列配制 const col = this.columns.find(c => c.prop === colKey); if (col && col.bodyFillType === "actFill" && col.compareTo) { const compareToValue = this.localDataSource[rowIndex][col.compareTo]; @@ -1168,7 +1168,7 @@ export default { this.$emit("blur", { rowIndex, colKey, value, dataSource: this.localDataSource, headerSelectFields: this.headerSelectFields, item: this.localDataSource[rowIndex] }); }, onSubBlur(rowIndex, colKey, value) { - // 查找对应的列配置 + // 查找对应的列配制 const col = this.columns.find(c => c.bodySubKey === colKey); if (col && col.bodySubFillType === "actFill" && col.bodySubCompareTo) { const compareToValue = this.localDataSource[rowIndex][col.bodySubCompareTo]; diff --git a/src/components/Template/README.md b/src/components/Template/README.md index a0cb698..ce1e41c 100644 --- a/src/components/Template/README.md +++ b/src/components/Template/README.md @@ -1,5 +1,7 @@ ## BaseInfoFormPackage组件config字段描述: + # demo: + ``` "formConfig":[ { @@ -11,7 +13,7 @@ fillType: "preFill" |"actFill",//主要是边框的区分,preFill为预填(蓝色),actFill为实际填报(橙色); options: this.getDictOptions("business_cctj"),//当前表单的type为select时,options为必填项,如:[{label:"",value:""}] otherCode: "storageConditionOther",//当前表单可能会触发其他输入项,otherCode为其他输入项的key值; - span:2,//一行几列,默认2列,目前最多配置3列,如果有需要后续再调整; + span:2,//一行几列,默认2列,目前最多配制3列,如果有需要后续再调整; maxlength:100,//当前表单的最大长度,默认50; placeholder: "请输入存储条件",//当前表单的placeholder值,不填写时默认拼接请输入/请选择+label; rows: 5,//当前表单的type为textarea时,默认5行; @@ -29,10 +31,12 @@ } } ] - ``` +``` + +## CommonTable组件config字段描述: - ## CommonTable组件config字段描述: # demo: + ``` formConfig:[ { @@ -53,9 +57,9 @@ formConfig:[ compareTo: "storageCondition",//需要比较的字段,字段不一样时背景标红; copyFrom:"storageCondition",//需要复制的字段,复制后会自动填充到当前表单; bodyPrecisionKey: "storageConditionPrecision",//当前表单小数点位数 - + } ] -``` \ No newline at end of file +``` diff --git a/src/components/Template/Step.vue b/src/components/Template/Step.vue index b0070bb..a70ea52 100644 --- a/src/components/Template/Step.vue +++ b/src/components/Template/Step.vue @@ -82,27 +82,27 @@ import jr from "./StepComponents/ry/jr.vue";//溶液-加热 import fz from "./StepComponents/ry/fz.vue";//溶液-分装 //罗开凡新增 -//表配置 -import jrry_b from './StepComponents/b/jrry_b.vue';//表配置-加入溶液 -//表配置-离心:使用溶液-离心 -import cl from './StepComponents/b/cl.vue';//表配置-称量 -//表配置-超声:使用溶液-超声 -//表配置-恒温混匀:使用溶液-恒温混匀 -//表配置-振摇混匀:使用溶液-振摇混匀 -//表配置-涡旋混匀:使用溶液-涡旋混匀 -//表配置-颠倒混匀:使用溶液-颠倒混匀 - -//表配置-搅拌:使用溶液-搅拌 -//表配置-加热搅拌:使用溶液-加热搅拌 -//表配置-水浴:使用溶液-水浴 -//表配置-正压:使用溶液-正压 -//表配置-氮吹:使用溶液-氮吹 -//表配置-过滤(自动):使用溶液-过滤(自动) -//表配置-过滤(手动):使用溶液-过滤(手动) -//表配置-静置:使用溶液-静置 -//表配置-解冻:使用溶液-解冻 -//表配置-孵育:使用溶液-孵育 -//表配置-复溶:使用溶液-复溶 +//表配制 +import jrry_b from './StepComponents/b/jrry_b.vue';//表配制-加入溶液 +//表配制-离心:使用溶液-离心 +import cl from './StepComponents/b/cl.vue';//表配制-称量 +//表配制-超声:使用溶液-超声 +//表配制-恒温混匀:使用溶液-恒温混匀 +//表配制-振摇混匀:使用溶液-振摇混匀 +//表配制-涡旋混匀:使用溶液-涡旋混匀 +//表配制-颠倒混匀:使用溶液-颠倒混匀 + +//表配制-搅拌:使用溶液-搅拌 +//表配制-加热搅拌:使用溶液-加热搅拌 +//表配制-水浴:使用溶液-水浴 +//表配制-正压:使用溶液-正压 +//表配制-氮吹:使用溶液-氮吹 +//表配制-过滤(自动):使用溶液-过滤(自动) +//表配制-过滤(手动):使用溶液-过滤(手动) +//表配制-静置:使用溶液-静置 +//表配制-解冻:使用溶液-解冻 +//表配制-孵育:使用溶液-孵育 +//表配制-复溶:使用溶液-复溶 //生物样品分析 @@ -228,58 +228,58 @@ import yxpcry from './StepComponents/pcrfxyp/yxpcry.vue';//PCR分析样品处理 import cdnsypfz from './StepComponents/pcrfxyp/cdnsypfz.vue';//PCR分析样品处理表-cDNA样品分装 -//检测板配置 -import bb from './StepComponents/jcb/bb.vue';//检测板配置-包被 -//检测板配置-洗板:使用检测板配置-包被 -//检测板配置-封闭:使用检测板配置-包被 -import jy from './StepComponents/jcb/jy.vue';//检测板配置-加样 -//检测板配置-中和:使用检测板配置-包被 -//检测板配置-加检测试剂:使用检测板配置-包被 -//检测板配置-酸解:使用检测板配置-包被 -import sjjy_jcb from './StepComponents/jcb/sjjy_jcb.vue';//检测板配置-酸解加样 -import zhfy from './StepComponents/jcb/zhfy.vue';//检测板配置-中和孵育 -//检测板配置-二次酸解:使用检测板配置-包被 -import xs_jcb from './StepComponents/jcb/xs_jcb.vue';//检测板配置-显色 -//检测板配置-终止:使用检测板配置-包被 -//检测板配置-检测:使用检测板配置-包被 -import dbmby from './StepComponents/jcb/dbmby.vue';//检测板配置-读板(酶标仪) -//检测板配置-读板(化学发光系统):使用检测板配置-读板(酶标仪) -import dbdhxfgxt from './StepComponents/jcb/dbdhxfgxt.vue';//检测板配置-读板(电化学发光系统) -import dbygxt from './StepComponents/jcb/dbygxt.vue';//检测板配置-读板(荧光系统) -import dzacl from './StepComponents/jcb/dzacl.vue';//检测板配置-读值(ACL) -import qb from './StepComponents/jcb/qb.vue';//检测板配置-取板 -import jzks from './StepComponents/jcb/jzks.vue';//检测板配置-静置开始 -import fyxks from './StepComponents/jcb/fyxks.vue';//检测板配置-孵育箱开始 -import ycfyks from './StepComponents/jcb/ycfyks.vue';//检测板配置-摇床孵育开始 -import ycks from './StepComponents/jcb/ycks.vue';//检测板配置-摇床开始 -import js_jcb from './StepComponents/jcb/js_jcb.vue';//检测板配置-结束 -//检测板配置-覆膜:使用检测板配置-读值(ACL) -//检测板配置-拍干:使用检测板配置-读值(ACL) -import czqx from './StepComponents/jcb/czqx.vue';//检测板配置-磁珠清洗 -import czzx from './StepComponents/jcb/czzx.vue';//检测板配置-磁珠重悬 -import ychy from './StepComponents/jcb/ychy.vue';//检测板配置-摇床混匀 -import czzy from './StepComponents/jcb/czzy.vue';//检测板配置-磁珠转移 -import sjbj from './StepComponents/jcb/sjbj.vue';//检测板配置-试剂标记 - - -//细胞/菌株配置 -import qxb from './StepComponents/xbjzpz/qxb.vue';//细胞/菌株配置-取细胞 -import qjz from './StepComponents/xbjzpz/qjz.vue';//细胞/菌株配置-取菌株 -import fr_xbjzpz from './StepComponents/xbjzpz/fr_xbjzpz.vue';//细胞/菌株配置-复溶 -import lxqy from './StepComponents/xbjzpz/lxqy.vue';//细胞/菌株配置-离心(弃液) -import cd from './StepComponents/xbjzpz/cd.vue';//细胞/菌株配置-吹打 -import xbzy from './StepComponents/xbjzpz/xbzy.vue';//细胞/菌株配置-细胞转移 -import jzzy from './StepComponents/xbjzpz/jzzy.vue';//细胞/菌株配置-菌株转移 -import dypyy from './StepComponents/xbjzpz/dypyy.vue';//细胞/菌株配置-倒原培养液 -import xd from './StepComponents/xbjzpz/xd.vue';//细胞/菌株配置-洗涤 -//细胞/菌株配置-消化:使用细胞/菌株配置-洗涤 -//细胞/菌株配置-终止消化:使用细胞/菌株配置-洗涤 -import copy from './StepComponents/xbjzpz/copy.vue';//细胞/菌株配置-CO2培养 -import gc from './StepComponents/xbjzpz/gc.vue';//细胞/菌株配置-观察 -import cdmd from './StepComponents/xbjzpz/cdmd.vue';//细胞/菌株配置-测定密度 -//细胞/菌株配置-低渗:使用细胞/菌株配置-洗涤 -//细胞/菌株配置-固定:使用细胞/菌株配置-洗涤 -import cdxs from './StepComponents/xbjzpz/cdxs.vue';//细胞/菌株配置-传代/稀释 +//检测板配制 +import bb from './StepComponents/jcb/bb.vue';//检测板配制-包被 +//检测板配制-洗板:使用检测板配制-包被 +//检测板配制-封闭:使用检测板配制-包被 +import jy from './StepComponents/jcb/jy.vue';//检测板配制-加样 +//检测板配制-中和:使用检测板配制-包被 +//检测板配制-加检测试剂:使用检测板配制-包被 +//检测板配制-酸解:使用检测板配制-包被 +import sjjy_jcb from './StepComponents/jcb/sjjy_jcb.vue';//检测板配制-酸解加样 +import zhfy from './StepComponents/jcb/zhfy.vue';//检测板配制-中和孵育 +//检测板配制-二次酸解:使用检测板配制-包被 +import xs_jcb from './StepComponents/jcb/xs_jcb.vue';//检测板配制-显色 +//检测板配制-终止:使用检测板配制-包被 +//检测板配制-检测:使用检测板配制-包被 +import dbmby from './StepComponents/jcb/dbmby.vue';//检测板配制-读板(酶标仪) +//检测板配制-读板(化学发光系统):使用检测板配制-读板(酶标仪) +import dbdhxfgxt from './StepComponents/jcb/dbdhxfgxt.vue';//检测板配制-读板(电化学发光系统) +import dbygxt from './StepComponents/jcb/dbygxt.vue';//检测板配制-读板(荧光系统) +import dzacl from './StepComponents/jcb/dzacl.vue';//检测板配制-读值(ACL) +import qb from './StepComponents/jcb/qb.vue';//检测板配制-取板 +import jzks from './StepComponents/jcb/jzks.vue';//检测板配制-静置开始 +import fyxks from './StepComponents/jcb/fyxks.vue';//检测板配制-孵育箱开始 +import ycfyks from './StepComponents/jcb/ycfyks.vue';//检测板配制-摇床孵育开始 +import ycks from './StepComponents/jcb/ycks.vue';//检测板配制-摇床开始 +import js_jcb from './StepComponents/jcb/js_jcb.vue';//检测板配制-结束 +//检测板配制-覆膜:使用检测板配制-读值(ACL) +//检测板配制-拍干:使用检测板配制-读值(ACL) +import czqx from './StepComponents/jcb/czqx.vue';//检测板配制-磁珠清洗 +import czzx from './StepComponents/jcb/czzx.vue';//检测板配制-磁珠重悬 +import ychy from './StepComponents/jcb/ychy.vue';//检测板配制-摇床混匀 +import czzy from './StepComponents/jcb/czzy.vue';//检测板配制-磁珠转移 +import sjbj from './StepComponents/jcb/sjbj.vue';//检测板配制-试剂标记 + + +//细胞/菌株配制 +import qxb from './StepComponents/xbjzpz/qxb.vue';//细胞/菌株配制-取细胞 +import qjz from './StepComponents/xbjzpz/qjz.vue';//细胞/菌株配制-取菌株 +import fr_xbjzpz from './StepComponents/xbjzpz/fr_xbjzpz.vue';//细胞/菌株配制-复溶 +import lxqy from './StepComponents/xbjzpz/lxqy.vue';//细胞/菌株配制-离心(弃液) +import cd from './StepComponents/xbjzpz/cd.vue';//细胞/菌株配制-吹打 +import xbzy from './StepComponents/xbjzpz/xbzy.vue';//细胞/菌株配制-细胞转移 +import jzzy from './StepComponents/xbjzpz/jzzy.vue';//细胞/菌株配制-菌株转移 +import dypyy from './StepComponents/xbjzpz/dypyy.vue';//细胞/菌株配制-倒原培养液 +import xd from './StepComponents/xbjzpz/xd.vue';//细胞/菌株配制-洗涤 +//细胞/菌株配制-消化:使用细胞/菌株配制-洗涤 +//细胞/菌株配制-终止消化:使用细胞/菌株配制-洗涤 +import copy from './StepComponents/xbjzpz/copy.vue';//细胞/菌株配制-CO2培养 +import gc from './StepComponents/xbjzpz/gc.vue';//细胞/菌株配制-观察 +import cdmd from './StepComponents/xbjzpz/cdmd.vue';//细胞/菌株配制-测定密度 +//细胞/菌株配制-低渗:使用细胞/菌株配制-洗涤 +//细胞/菌株配制-固定:使用细胞/菌株配制-洗涤 +import cdxs from './StepComponents/xbjzpz/cdxs.vue';//细胞/菌株配制-传代/稀释 //细胞表单 @@ -431,7 +431,7 @@ export default { fz, //罗开凡新增 - //表配置 + //表配制 jrry_b, cl, @@ -517,7 +517,7 @@ export default { yxpcry, cdnsypfz, - //检测板配置 + //检测板配制 bb, jy, sjjy_jcb, @@ -539,7 +539,7 @@ export default { czzy, sjbj, - //细胞/菌株配置 + //细胞/菌株配制 qxb, qjz, fr_xbjzpz, @@ -629,7 +629,7 @@ export default { 'fz': 'fz', //罗开凡新增 - //标配配置 + //标配配制 'jrry_b': 'jrry_b', 'cl': 'cl', 'lx_b': 'Lx', @@ -753,7 +753,7 @@ export default { 'yxpcry':'yxpcry', 'cdnsypfz':'cdnsypfz', - //检测板配置 + //检测板配制 'bb':'bb', 'xb':'bb', 'fb_jcb':'bb', @@ -786,7 +786,7 @@ export default { 'czzy':'czzy', 'sjbj':'sjbj', - //细胞/菌株配置 + //细胞/菌株配制 'qxb':'qxb', 'qjz':'qjz', 'fr_xbjzpz':'fr_xbjzpz', diff --git a/src/components/Template/StepComponents/ContainerStep.vue b/src/components/Template/StepComponents/ContainerStep.vue index 83a0ee4..5eaef59 100644 --- a/src/components/Template/StepComponents/ContainerStep.vue +++ b/src/components/Template/StepComponents/ContainerStep.vue @@ -22,7 +22,7 @@ export default { formData: { containerType: '', }, - // 字段配置 + // 字段配制 fieldConfigs: { containerType: { label: '容器选择', diff --git a/src/components/Template/StepComponents/ZLSubPackage.vue b/src/components/Template/StepComponents/ZLSubPackage.vue index 6165d81..224bf68 100644 --- a/src/components/Template/StepComponents/ZLSubPackage.vue +++ b/src/components/Template/StepComponents/ZLSubPackage.vue @@ -182,7 +182,7 @@ export default { validateFormData() { let isValid = true; - // 定义需要验证的基础字段配置 + // 定义需要验证的基础字段配制 const baseFieldConfigs = this.subConfig; // 验证基础字段 diff --git a/src/components/Template/mixins/formPackageMixins.js b/src/components/Template/mixins/formPackageMixins.js index 455a714..364a4ee 100644 --- a/src/components/Template/mixins/formPackageMixins.js +++ b/src/components/Template/mixins/formPackageMixins.js @@ -1,588 +1,695 @@ -import _ from "lodash"; -import { getuuid, isEqual, isValueEmpty } from "@/utils/index.js"; -import { isShowOtherByCheckboxTree } from "@/utils/formPackageCommon.js"; +import _ from 'lodash' +import { getuuid, isEqual, isValueEmpty } from '@/utils/index.js' +import { isShowOtherByCheckboxTree } from '@/utils/formPackageCommon.js' export default { - inject: ["getZdxgjl", "updateZdxgjl"], - watch: { - formData: { - immediate: true, - deep: true, // 深度监听,以便检测嵌套对象变化 - handler(v) { - if (v) { - this.handleFormField(true); - } - } - }, - fieldItemLabel: { - immediate: true, - deep: true, // 深度监听,以便检测嵌套对象变化 - handler(v) { - if (v) { - console.log(v, "fieldItemLabel") - } - } - }, - formConfig: { - immediate: true, - deep: true, // 深度监听,以便检测嵌套对象变化 - handler(v) { - this.handleFormField(); - } + inject: ['getZdxgjl', 'updateZdxgjl'], + watch: { + formData: { + immediate: true, + deep: true, // 深度监听,以便检测嵌套对象变化 + handler(v) { + if (v) { + this.handleFormField(true) } + } }, - data() { - return { - uuid: getuuid(), - oldFormFields: {}, - clickableKey: "", + fieldItemLabel: { + immediate: true, + deep: true, // 深度监听,以便检测嵌套对象变化 + handler(v) { + if (v) { + console.log(v, 'fieldItemLabel') } + } + }, + formConfig: { + immediate: true, + deep: true, // 深度监听,以便检测嵌套对象变化 + handler(v) { + this.handleFormField() + } + } + }, + data() { + return { + uuid: getuuid(), + oldFormFields: {}, + clickableKey: '' + } + }, + mounted() { + this.handleFormField() + }, + unmounted() { + this.formFields = {} //清空当前填写的数据 + }, + + methods: { + onSelectChange(key, val, type) { + // 获取对应的配制 + const currentConfig = this.allFieldsConfig[key] + if (currentConfig?.selectTo) { + this.formFields[currentConfig?.selectTo] = val + } + this.onValueChangeCompareTo(key, val) + this.formFields[key] = val + this.$emit('select', { key, value: val, type, ...this.formFields }) + // 清除该表单项的错误状态 + if (this.errors[key]) { + this.$set(this.errors, key, false) + } }, - mounted() { - this.handleFormField(); + + //试剂/仪器等弹窗提交 + onRegentSubmit(data, inputValue, key, item) { + this.updateFormData(key, inputValue) + this.$emit('onRegentSubmit', { + selectInfo: data, + inputValue, + key, + config: item + }) }, - unmounted() { - this.formFields = {};//清空当前填写的数据 + getRegentItem(item, fieldCode = 'type') { + const type = item[fieldCode] + const fillType = + fieldCode === 'type' ? item.fillType : item.subFillType || item.fillType + return { + label: '', + type, + fillType, + parentLabel: item.label, + filledCodes: item.filledCodes, + qxbdType: item.qxbdType, + checkType: item.checkType, + regentFillType: item.regentFillType + } }, - methods: { - onSelectChange(key, val, type) { - // 获取对应的配置 - const currentConfig = this.allFieldsConfig[key]; - if (currentConfig?.selectTo) { - this.formFields[currentConfig?.selectTo] = val; - } - this.onValueChangeCompareTo(key, val); - this.formFields[key] = val; - this.$emit("select", { key, value: val, type, ...this.formFields }); - // 清除该表单项的错误状态 - if (this.errors[key]) { - this.$set(this.errors, key, false); - } - }, + handleClickButton(key) { + this.$emit('clickButton', key) + }, + getFillType(type) { + const typeObj = { + actFill: 'orange-border', //实际填写的边框颜色 + green: 'green-border', + preFill: 'blue-border' //预填写的边框颜色 + } + return typeObj[type] || '' + }, + onInputNumberChange(key, val) { + this.formFields[key] = val + // 清除该表单项的错误状态 + if (this.errors[key]) { + this.$set(this.errors, key, false) + } + }, + //批量更新表单数据 + batchUpdateFormData(data) { + const cloneFormFields = JSON.parse(JSON.stringify(this.formFields)) + Object.keys(data).forEach((key) => { + this.oldFormFields[key] = cloneFormFields[key] + this.formFields[key] = data[key] + // 清除该表单项的错误状态 + if (this.errors[key]) { + this.$set(this.errors, key, false) + } + }) + }, + //更新表单数据 + updateFormData(key, value, data) { + const { isUpdateRecord, signData } = data || {} + // 深拷贝当前表单数据,避免直接修改原数据 + const cloneFormFields = JSON.parse(JSON.stringify(this.formFields)) - //试剂/仪器等弹窗提交 - onRegentSubmit(data, inputValue, key, item) { - this.updateFormData(key, inputValue); - this.$emit("onRegentSubmit", { selectInfo: data, inputValue, key, config: item }); - }, - getRegentItem(item, fieldCode = "type") { - const type = item[fieldCode]; - const fillType = fieldCode === "type" ? item.fillType : (item.subFillType || item.fillType); - return { - label: "", - type, - fillType, - parentLabel: item.label, - filledCodes: item.filledCodes, - qxbdType: item.qxbdType, - checkType: item.checkType, - regentFillType: item.regentFillType, - } - }, + this.oldFormFields[key] = cloneFormFields[key] + this.formFields[key] = value + // 清除该表单项的错误状态 + if (this.errors[key]) { + this.$set(this.errors, key, false) + } - handleClickButton(key) { - this.$emit("clickButton", key) - }, - getFillType(type) { - const typeObj = { - actFill: "orange-border",//实际填写的边框颜色 - green: "green-border", - preFill: "blue-border",//预填写的边框颜色 - } - return typeObj[type] || "" - }, - onInputNumberChange(key, val) { - this.formFields[key] = val; - // 清除该表单项的错误状态 - if (this.errors[key]) { - this.$set(this.errors, key, false); - } - }, - //批量更新表单数据 - batchUpdateFormData(data) { - const cloneFormFields = JSON.parse(JSON.stringify(this.formFields)); - Object.keys(data).forEach(key => { - this.oldFormFields[key] = cloneFormFields[key]; - this.formFields[key] = data[key]; - // 清除该表单项的错误状态 - if (this.errors[key]) { - this.$set(this.errors, key, false); - } - }) + if (isUpdateRecord) { + setTimeout(() => { + this.$refs[key][0].handleUpdateRecord(signData, { + oldValue: this.oldFormFields[key], + inputValue: value + }) + }, 10) + } + }, - }, - //更新表单数据 - updateFormData(key, value, data) { - const { isUpdateRecord, signData } = data || {}; - // 深拷贝当前表单数据,避免直接修改原数据 - const cloneFormFields = JSON.parse(JSON.stringify(this.formFields)); + handleClickable(sItem, key) { + if (this.templateFillType !== 'actFill') { + return + } + this.clickableKey = key + this.$emit('clickable', sItem) + }, + //根据span判断一行显示几列 + getSpanClass(sItem) { + const spanArr = ['full-row', '', 'three-row'] + if (sItem.span) { + return spanArr[sItem.span - 1] + } + return '' + }, + //获取其他下拉框的配制 + getOtherItem(sItem) { + return { + label: sItem.otherLabel + ? this.$t(sItem.otherLabel) + : this.$t('template.common.other'), + fillType: sItem.fillType, + maxlength: sItem.otherMaxlength || 50, + parentLabel: sItem.label, + options: sItem.otherOptions || [] + } + }, + getRadioOtherItem(sItem) { + return { + // label: sItem.otherLabel ? this.$t(sItem.otherLabel) : this.$t("template.common.other"), + fillType: sItem.fillType, + maxlength: sItem.otherMaxlength || 50, + parentLabel: sItem.label + } + }, + getClickableItem(sItem) { + return { + label: '', + type: 'clickable', + fillType: sItem.subFillType || sItem.fillType, + parentLabel: sItem.label + } + }, + getSubItem(sItem) { + const config = { + label: '', + options: sItem.subOptions || [], + fillType: sItem.subFillType || sItem.fillType, + parentLabel: sItem.label + } + if (sItem.subDisabled) { + config.disabled = sItem.subDisabled + } + return config + }, + //获取第三个的配制 + getThirdItem(sItem) { + const config = { + label: '', + options: sItem.thirdOptions || [], + fillType: sItem.thirdFillType, + parentLabel: sItem.label, + maxlength: sItem.thirdMaxlength || 50 + } + if (sItem.thirdDisabled) { + config.disabled = sItem.thirdDisabled + } + return config + }, + // 根据formConfig回填form表单数据 + handleFormField(update = false) { + const result = {} + let config = {} + const { formConfig, formData, formFields } = this + // 遍历配制 + formConfig.forEach((item) => { + if (item.config) { + // 合并配制项 + config = { ...config, ...item.config } - this.oldFormFields[key] = cloneFormFields[key]; - this.formFields[key] = value; - // 清除该表单项的错误状态 - if (this.errors[key]) { - this.$set(this.errors, key, false); - } + // 处理每个配制项 + Object.keys(item.config).forEach((key) => { + const currentConfig = item.config[key] + let value = formData[key] - if (isUpdateRecord) { - setTimeout(() => { - this.$refs[key][0].handleUpdateRecord(signData, { oldValue: this.oldFormFields[key], inputValue: value }); - }, 10); + // 如果formFields中已经有值,保持原值(用户输入或之前设置的值) + if ( + formFields[key] !== null && + formFields[key] !== undefined && + formFields[key] !== '' + // typeof formFields[key] !== 'object' + ) { + // 保留原值,不使用formData中的值 + result[key] = formFields[key] + } else { + // 使用formData中的值 + result[key] = value } - }, - - handleClickable(sItem, key) { - if (this.templateFillType !== 'actFill') { - return + // 处理特殊字段 - "其他"字段 + if (currentConfig.otherCode) { + const { otherCode, type } = currentConfig + //如果是更新的话,优先使用formFields中的值 + if (update) { + result[otherCode] = + formFields[otherCode] || formData[otherCode] || '' + } else { + result[otherCode] = + formData[otherCode] || formFields[otherCode] || '' + } + config[otherCode] = { + label: 'template.common.other', + parentType: type, + parentKey: key, + type: 'input', + fillType: currentConfig.fillType + } } - this.clickableKey = key; - this.$emit("clickable", sItem) - }, - //根据span判断一行显示几列 - getSpanClass(sItem) { - const spanArr = ["full-row", "", "three-row"] - if (sItem.span) { - return spanArr[sItem.span - 1] + if (currentConfig.thirdOtherCode) { + const { thirdOtherCode, type } = currentConfig + //如果是更新的话,优先使用formFields中的值 + if (update) { + result[thirdOtherCode] = + formFields[thirdOtherCode] || formData[thirdOtherCode] || '' + } else { + result[thirdOtherCode] = + formData[thirdOtherCode] || formFields[thirdOtherCode] || '' + } + config[thirdOtherCode] = { + label: 'template.common.other', + parentType: type, + parentKey: key, + type: 'input', + fillType: currentConfig.fillType + } } - return "" - }, - //获取其他下拉框的配置 - getOtherItem(sItem) { - return { - label: sItem.otherLabel ? this.$t(sItem.otherLabel) : this.$t("template.common.other"), - fillType: sItem.fillType, - maxlength: sItem.otherMaxlength || 50, - parentLabel: sItem.label, - options: sItem.otherOptions || [], + if (currentConfig.subKey) { + const { subKey } = currentConfig + if (update) { + result[subKey] = formFields[subKey] || formData[subKey] || '' + } else { + result[subKey] = formData[subKey] || formFields[subKey] || '' + } + config[subKey] = { + label: currentConfig.label, + subKey, + type: currentConfig.subType, + fillType: currentConfig.subFillType || currentConfig.fillType, + selectTo: currentConfig.selectTo + } } - }, - getRadioOtherItem(sItem) { - return { - // label: sItem.otherLabel ? this.$t(sItem.otherLabel) : this.$t("template.common.other"), - fillType: sItem.fillType, - maxlength: sItem.otherMaxlength || 50, - parentLabel: sItem.label, + if (currentConfig.thirdKey) { + const { thirdKey } = currentConfig + if (update) { + result[thirdKey] = + formFields[thirdKey] || formData[thirdKey] || '' + } else { + result[thirdKey] = + formFields[thirdKey] || formData[thirdKey] || '' + } + config[thirdKey] = { + label: currentConfig.label, + thirdKey, + type: currentConfig.thirdType, + fillType: currentConfig.thirdFillType, + selectTo: currentConfig.selectTo + } } - }, - getClickableItem(sItem) { - return { - label: "", - type: "clickable", - fillType: sItem.subFillType || sItem.fillType, - parentLabel: sItem.label, + if (currentConfig.fourthKey) { + const { fourthKey } = currentConfig + if (update) { + result[fourthKey] = + formFields[fourthKey] || formData[fourthKey] || '' + } else { + result[fourthKey] = + formFields[fourthKey] || formData[fourthKey] || '' + } + config[fourthKey] = { + label: currentConfig.label, + fourthKey, + type: currentConfig.fourthType, + fillType: currentConfig.fourthFillType, + selectTo: currentConfig.selectTo + } } - }, - getSubItem(sItem) { - const config = { - label: "", - options: sItem.subOptions || [], - fillType: sItem.subFillType || sItem.fillType, - parentLabel: sItem.label, - } - if (sItem.subDisabled) { - config.disabled = sItem.subDisabled; + + // 检查compareTo字段 + if ( + currentConfig.compareTo && + formData[currentConfig.compareTo] && + result[key] + ) { + const compareToValue = formData[currentConfig.compareTo] + const currentValue = result[key] + this.compareFieldsIsEqual(currentValue, compareToValue, key) } - return config; - }, - //获取第三个的配置 - getThirdItem(sItem) { - const config = { - label: "", - options: sItem.thirdOptions || [], - fillType: sItem.thirdFillType, - parentLabel: sItem.label, - maxlength: sItem.thirdMaxlength || 50, + // 检查compareTo字段 + if ( + currentConfig.subCompareTo && + formData[currentConfig.subCompareTo] && + result[currentConfig.subKey] + ) { + const compareToValue = formData[currentConfig.subCompareTo] + const currentValue = result[currentConfig.subKey] + this.compareFieldsIsEqual( + currentValue, + compareToValue, + currentConfig.subKey + ) } - if (sItem.thirdDisabled) { - config.disabled = sItem.thirdDisabled; + if ( + currentConfig.otherCodeCompareTo && + formData[currentConfig.otherCodeCompareTo] && + result[currentConfig.otherCode] + ) { + const compareToValue = formData[currentConfig.otherCodeCompareTo] + const currentValue = result[currentConfig.otherCode] + this.compareFieldsIsEqual( + currentValue, + compareToValue, + currentConfig.otherCode + ) } - return config; - }, - // 根据formConfig回填form表单数据 - handleFormField(update = false) { - const result = {}; - let config = {}; - const { formConfig, formData, formFields } = this; - // 遍历配置 - formConfig.forEach((item) => { - if (item.config) { - // 合并配置项 - config = { ...config, ...item.config } - - // 处理每个配置项 - Object.keys(item.config).forEach(key => { - const currentConfig = item.config[key]; - let value = formData[key]; - - // 如果formFields中已经有值,保持原值(用户输入或之前设置的值) - if (formFields[key] !== null && - formFields[key] !== undefined && - formFields[key] !== '' - // typeof formFields[key] !== 'object' - ) { - - // 保留原值,不使用formData中的值 - result[key] = formFields[key]; - - } else { - // 使用formData中的值 - result[key] = value; - } - - // 处理特殊字段 - "其他"字段 - if (currentConfig.otherCode) { - const { otherCode, type } = currentConfig; - //如果是更新的话,优先使用formFields中的值 - if (update) { - result[otherCode] = formFields[otherCode] || formData[otherCode] || ''; - } else { - result[otherCode] = formData[otherCode] || formFields[otherCode] || ''; - } - config[otherCode] = { label: "template.common.other", parentType: type, parentKey: key, type: "input", fillType: currentConfig.fillType } - } - if (currentConfig.thirdOtherCode) { - const { thirdOtherCode, type } = currentConfig; - //如果是更新的话,优先使用formFields中的值 - if (update) { - result[thirdOtherCode] = formFields[thirdOtherCode] || formData[thirdOtherCode] || ''; - } else { - result[thirdOtherCode] = formData[thirdOtherCode] || formFields[thirdOtherCode] || ''; - } - config[thirdOtherCode] = { label: "template.common.other", parentType: type, parentKey: key, type: "input", fillType: currentConfig.fillType } - } - if (currentConfig.subKey) { - const { subKey } = currentConfig; - if (update) { - result[subKey] = formFields[subKey] || formData[subKey] || ''; - } else { - result[subKey] = formData[subKey] || formFields[subKey] || ''; - } - config[subKey] = { label: currentConfig.label, subKey, type: currentConfig.subType, fillType: currentConfig.subFillType || currentConfig.fillType, selectTo: currentConfig.selectTo } - } - if (currentConfig.thirdKey) { - const { thirdKey } = currentConfig; - if (update) { - result[thirdKey] = formFields[thirdKey] || formData[thirdKey] || ''; - } else { - result[thirdKey] = formFields[thirdKey] || formData[thirdKey] || ''; - } - config[thirdKey] = { label: currentConfig.label, thirdKey, type: currentConfig.thirdType, fillType: currentConfig.thirdFillType, selectTo: currentConfig.selectTo } - } - if (currentConfig.fourthKey) { - const { fourthKey } = currentConfig; - if (update) { - result[fourthKey] = formFields[fourthKey] || formData[fourthKey] || ''; - } else { - result[fourthKey] = formFields[fourthKey] || formData[fourthKey] || ''; - } - config[fourthKey] = { label: currentConfig.label, fourthKey, type: currentConfig.fourthType, fillType: currentConfig.fourthFillType, selectTo: currentConfig.selectTo } - } - - // 检查compareTo字段 - if (currentConfig.compareTo && formData[currentConfig.compareTo] && result[key]) { - const compareToValue = formData[currentConfig.compareTo]; - const currentValue = result[key]; - this.compareFieldsIsEqual(currentValue, compareToValue, key) - - } - // 检查compareTo字段 - if (currentConfig.subCompareTo && formData[currentConfig.subCompareTo] && result[currentConfig.subKey]) { - const compareToValue = formData[currentConfig.subCompareTo]; - const currentValue = result[currentConfig.subKey]; - this.compareFieldsIsEqual(currentValue, compareToValue, currentConfig.subKey) - - } - if (currentConfig.otherCodeCompareTo && formData[currentConfig.otherCodeCompareTo] && result[currentConfig.otherCode]) { - const compareToValue = formData[currentConfig.otherCodeCompareTo]; - const currentValue = result[currentConfig.otherCode]; - this.compareFieldsIsEqual(currentValue, compareToValue, currentConfig.otherCode) + }) - } - }); - - // 处理可能存在的直接otherCode字段 - if (item.config?.otherCode) { - config[item.config?.otherCode] = item.config?.otherCode; - } - if (item.config?.thirdOtherCode) { - config[item.config?.thirdOtherCode] = item.config?.thirdOtherCode; - } - } - }); - // 处理selectInfo_开头的字段,步骤表单需要保留selectInfo_开头的字段 - const selectInfoKeys = Object.keys(formData).filter(key => key.startsWith("selectInfo_")); - selectInfoKeys.forEach(key => { - result[key] = formData[key]; - }) - // 更新表单字段 - this.formFields = {...result}; - this.allFieldsConfig = config; - }, - //比较值是否相等 - compareFieldsIsEqual(currentValue, compareToValue, key) { - if (!currentValue || !compareToValue) return; - // 如果当前值与compareTo字段的值不相等,则设置橙色背景 - if (isEqual(currentValue, compareToValue)) { - // 如果相等,移除橙色背景(如果之前设置了的话) - this.$set(this.orangeBgFields, key, false); - } else { - this.$set(this.orangeBgFields, key, true); + // 处理可能存在的直接otherCode字段 + if (item.config?.otherCode) { + config[item.config?.otherCode] = item.config?.otherCode + } + if (item.config?.thirdOtherCode) { + config[item.config?.thirdOtherCode] = item.config?.thirdOtherCode + } + } + }) + // 处理selectInfo_开头的字段,步骤表单需要保留selectInfo_开头的字段 + const selectInfoKeys = Object.keys(formData).filter((key) => + key.startsWith('selectInfo_') + ) + selectInfoKeys.forEach((key) => { + result[key] = formData[key] + }) + // 更新表单字段 + this.formFields = { ...result } + this.allFieldsConfig = config + }, + //比较值是否相等 + compareFieldsIsEqual(currentValue, compareToValue, key) { + if (!currentValue || !compareToValue) return + // 如果当前值与compareTo字段的值不相等,则设置橙色背景 + if (isEqual(currentValue, compareToValue)) { + // 如果相等,移除橙色背景(如果之前设置了的话) + this.$set(this.orangeBgFields, key, false) + } else { + this.$set(this.orangeBgFields, key, true) + } + }, + //判断是否禁用 + getDisabled() { + const { item } = this + const { fillType } = item + if (item.hasOwnProperty('disabled')) { + return item.disabled + } else { + if (fillType === 'actFill') { + //当模板状态是实际填写时,只有当fillType是actFill时才能填写 + return this.templateFillType !== 'actFill' + } else if (fillType === 'preFill') { + //当模板状态是预填写时,只有当fillType是preFill才能填写 + return this.templateFillType !== 'preFill' + } else { + return true + } + } + }, + // 表单数据校验 + validateFormData() { + const { formFields, allFieldsConfig } = this + const errors = [] + // 清空之前的错误状态 + this.errors = {} + for (const key in allFieldsConfig) { + const o = allFieldsConfig[key] + if (o.otherCode) { + // + if (o.type === 'select') { + const isSelectedOther = this.isShowOther(formFields[key], o) + if (!isSelectedOther) { + //如果其他选项没有被选择,清空其他字段 + formFields[o.otherCode] = '' } - }, - //判断是否禁用 - getDisabled() { - const { item } = this; - const { fillType } = item; - if (item.hasOwnProperty("disabled")) { - return item.disabled - } else { - if (fillType === "actFill") {//当模板状态是实际填写时,只有当fillType是actFill时才能填写 - return this.templateFillType !== "actFill" - } else if (fillType === "preFill") {//当模板状态是预填写时,只有当fillType是preFill才能填写 - return this.templateFillType !== "preFill" - } else { - return true - } + } else if (o.subType === 'select') { + const isSelectedOther = this.isShowOther(formFields[o.subKey], o) + if (!isSelectedOther) { + //如果其他选项没有被选择,清空其他字段 + formFields[o.otherCode] = '' } - }, - // 表单数据校验 - validateFormData() { - const { formFields, allFieldsConfig } = this; - const errors = []; - // 清空之前的错误状态 - this.errors = {}; - for (const key in allFieldsConfig) { - const o = allFieldsConfig[key]; - if (o.otherCode) {// - if (o.type === "select") { - const isSelectedOther = this.isShowOther(formFields[key], o); - if (!isSelectedOther) {//如果其他选项没有被选择,清空其他字段 - formFields[o.otherCode] = ""; - } - } else if (o.subType === "select") { - const isSelectedOther = this.isShowOther(formFields[o.subKey], o); - if (!isSelectedOther) {//如果其他选项没有被选择,清空其他字段 - formFields[o.otherCode] = ""; - } - } else if (o.type === "radioAndOther") { - const isSelectedOther = this.isShowOtherByRadioAndOther(formFields[key], o); - if (!isSelectedOther) {//如果其他选项没有被选择,清空其他字段 - formFields[o.otherCode] = ""; - } - } - - } - if (o.type === "attachment" && o.fillType === this.templateFillType) { - const attValue = formFields[key]; - if (!attValue || attValue == "[]") { - errors.push({ - field: key, - label: o.label, - error: "请上传附件" - }); - this.$set(this.errors, key, true); - } - } else if (o.type === "fqyq" && o.fillType === this.templateFillType) { - const fqyqValue = formFields[key] || {}; - const { mainRadio, subRadio, inputValue } = fqyqValue; - if (!mainRadio) { - errors.push({ - field: key, - label: o.label, - error: "请选择是否在规定时间完成" - }); - this.$set(this.errors, key, true); - } else { - if (mainRadio === "是") { - if (!subRadio) { - errors.push({ - field: key, - label: o.label, - error: "请选择是否在规定时间完成" - }); - this.$set(this.errors, key, true); - } else if (!inputValue) { - errors.push({ - field: key, - label: o.label, - error: "请输入信息" - }); - this.$set(this.errors, key, true); - } - } - } - - continue - } else if (o.type === "checkboxTree" && o.fillType === this.templateFillType) { - const checkboxTreeValue = formFields[key] || {}; - const { checkedValues = [], otherValues = {} } = checkboxTreeValue;; - const { options = [] } = o; - //需要校验第一层是否有选中项 - const parentOptions = options.map(item => item.label); - const isChecked = checkedValues.some(option => { - return option.checked === true; - }); - //获取所有选中的选项 - const allCheckedOptions = checkedValues.filter(item => item.checked).map(item => item.label); - //再筛选出需要显示其他输入框的选项 - const otherOptions = allCheckedOptions.filter((label) => isShowOtherByCheckboxTree(label)) - const isHasOtherInfo = otherOptions.every(item => otherValues[item]); - console.log(isChecked, isHasOtherInfo, "isChecked") - if (!isChecked || !isHasOtherInfo) { - errors.push({ - field: key, - label: o.label, - error: "请选择方法学验证" - }); - this.$set(this.errors, key, true); - } - continue - } else if (o.type === "radioAndOther" && o.fillType === this.templateFillType) { - const radioValue = formFields[key] || {}; - const { otherCode } = o; - const otherValue = formFields[otherCode] || ""; - const isShow = this.isShowOtherByRadioAndOther(radioValue, o) - if (isShow && !otherValue) { - errors.push({ - field: key, - label: o.label, - error: "请输入信息" - }); - this.$set(this.errors, key, true); - } - // if (!radioValue) { - // errors.push({ - // field: key, - // label: o.label, - // error: "请选择方法学验证" - // }); - // this.$set(this.errors, key, true); - // } - continue - } - if (isValueEmpty(formFields[key])) { - // 其他字段需要判断是否显示再校验 - if (o.label === "template.common.other" && !this.isShowOther(formFields[o.parentKey])) { - continue - } - - //span的字段不校验 - if (o.type === "span" || o.type === "text" || o.type === "button") { - continue - } - if (o.fillType === this.templateFillType && !o.disabled) { - let prefix = ""; - if (o.type === "input" || o.type === "inputNumber" || o.type === "textarea") { - prefix = "填写"; - } else { - prefix = "选择"; - } + } else if (o.type === 'radioAndOther') { + const isSelectedOther = this.isShowOtherByRadioAndOther( + formFields[key], + o + ) + if (!isSelectedOther) { + //如果其他选项没有被选择,清空其他字段 + formFields[o.otherCode] = '' + } + } + } + if (o.type === 'attachment' && o.fillType === this.templateFillType) { + const attValue = formFields[key] + if (!attValue || attValue == '[]') { + errors.push({ + field: key, + label: o.label, + error: '请上传附件' + }) + this.$set(this.errors, key, true) + } + } else if (o.type === 'fqyq' && o.fillType === this.templateFillType) { + const fqyqValue = formFields[key] || {} + const { mainRadio, subRadio, inputValue } = fqyqValue + if (!mainRadio) { + errors.push({ + field: key, + label: o.label, + error: '请选择是否在规定时间完成' + }) + this.$set(this.errors, key, true) + } else { + if (mainRadio === '是') { + if (!subRadio) { + errors.push({ + field: key, + label: o.label, + error: '请选择是否在规定时间完成' + }) + this.$set(this.errors, key, true) + } else if (!inputValue) { + errors.push({ + field: key, + label: o.label, + error: '请输入信息' + }) + this.$set(this.errors, key, true) + } + } + } - const errorItem = { - field: key, - label: o.label, - error: `请${prefix}${o.label}` - }; + continue + } else if ( + o.type === 'checkboxTree' && + o.fillType === this.templateFillType + ) { + const checkboxTreeValue = formFields[key] || {} + const { checkedValues = [], otherValues = {} } = checkboxTreeValue + const { options = [] } = o + //需要校验第一层是否有选中项 + const parentOptions = options.map((item) => item.label) + const isChecked = checkedValues.some((option) => { + return option.checked === true + }) + //获取所有选中的选项 + const allCheckedOptions = checkedValues + .filter((item) => item.checked) + .map((item) => item.label) + //再筛选出需要显示其他输入框的选项 + const otherOptions = allCheckedOptions.filter((label) => + isShowOtherByCheckboxTree(label) + ) + const isHasOtherInfo = otherOptions.every((item) => otherValues[item]) + console.log(isChecked, isHasOtherInfo, 'isChecked') + if (!isChecked || !isHasOtherInfo) { + errors.push({ + field: key, + label: o.label, + error: '请选择方法学验证' + }) + this.$set(this.errors, key, true) + } + continue + } else if ( + o.type === 'radioAndOther' && + o.fillType === this.templateFillType + ) { + const radioValue = formFields[key] || {} + const { otherCode } = o + const otherValue = formFields[otherCode] || '' + const isShow = this.isShowOtherByRadioAndOther(radioValue, o) + if (isShow && !otherValue) { + errors.push({ + field: key, + label: o.label, + error: '请输入信息' + }) + this.$set(this.errors, key, true) + } + // if (!radioValue) { + // errors.push({ + // field: key, + // label: o.label, + // error: "请选择方法学验证" + // }); + // this.$set(this.errors, key, true); + // } + continue + } + if (isValueEmpty(formFields[key])) { + // 其他字段需要判断是否显示再校验 + if ( + o.label === 'template.common.other' && + !this.isShowOther(formFields[o.parentKey]) + ) { + continue + } - errors.push(errorItem); - this.$set(this.errors, key, true); - } - } + //span的字段不校验 + if (o.type === 'span' || o.type === 'text' || o.type === 'button') { + continue + } + if (o.fillType === this.templateFillType && !o.disabled) { + let prefix = '' + if ( + o.type === 'input' || + o.type === 'inputNumber' || + o.type === 'textarea' + ) { + prefix = '填写' + } else { + prefix = '选择' } - console.log(errors, "errors") - return { - valid: errors.length === 0, - errors: errors - }; - }, - getFormData() { - // 同时执行数据校验和子组件校验 - const validateResult = this.validateFormData(); - const subComponentValidateResult = this.validateSubComponents(); - // const subComponentValidateResult = {valid: true, error: ''}; - return new Promise((resolve, reject) => { - if (validateResult.valid && subComponentValidateResult.valid) { - resolve(this.formFields); - } else if (!validateResult.valid) { - // this.$message.error("表单内容未填完,请填写后再提交"); - reject(validateResult.errors[0].error); - } else { - reject(subComponentValidateResult.error); - } - }); - }, - // 子组件校验钩子方法,子组件可以重写此方法来添加额外的校验逻辑 - validateSubComponents() { - return { - valid: true, - error: '' - }; - }, - //直接获取表单数据,不做校验 - getFilledFormData() { - return this.formFields; - }, - getFormDataByKey(key) { - return this.formFields[key]; - }, - onBlur(key, val) { - // compareTo 功能:当fillType==="actFill"时,判断当前值是否与compareTo字段的值一样,如果不一样则将当前input框的背景色标记成橙色 - this.onValueChangeCompareTo(key, val); - if (this.errors[key]) { - this.$set(this.errors, key, false); + const errorItem = { + field: key, + label: o.label, + error: `请${prefix}${o.label}` } - this.$emit("blur", { key, value: val, ...this.formFields }); - }, - onValueChangeCompareTo(key, val, compKey) { - // compareTo 功能:当fillType==="actFill"时,判断当前值是否与compareTo字段的值一样,如果不一样则将当前input框的背景色标记成橙色 - const currentFieldConfig = this.allFieldsConfig[key]; - if (currentFieldConfig && currentFieldConfig.fillType === "actFill") { - if ((currentFieldConfig.compareTo || compKey)) { - const compareToKey = compKey || currentFieldConfig.compareTo; - const compareToValue = this.formFields[compareToKey]; - this.compareFieldsIsEqual(val, compareToValue, key); - } - if (currentFieldConfig.otherCodeCompareTo && this.formFields[currentFieldConfig.otherCodeCompareTo] && this.formFields[currentFieldConfig.otherCode]) { - const compareToValue = this.formFields[currentFieldConfig.otherCodeCompareTo]; - const currentValue = this.formFields[currentFieldConfig.otherCode]; - this.compareFieldsIsEqual(currentValue, compareToValue, currentFieldConfig.otherCode) - } - if(currentFieldConfig.subCompareTo && this.formFields[currentFieldConfig.subCompareTo] && this.formFields[currentFieldConfig.subKey]){ - const compareToValue = this.formFields[currentFieldConfig.subCompareTo]; - const currentValue = this.formFields[currentFieldConfig.subKey]; - this.compareFieldsIsEqual(currentValue, compareToValue, currentFieldConfig.subKey) - } - } - }, - onAttachmentChange(key, val) { - this.formFields[key] = val; - // 清除该表单项的错误状态 - if (this.errors[key]) { - this.$set(this.errors, key, false); - } + errors.push(errorItem) + this.$set(this.errors, key, true) + } + } + } + console.log(errors, 'errors') + return { + valid: errors.length === 0, + errors: errors + } + }, + getFormData() { + // 同时执行数据校验和子组件校验 + const validateResult = this.validateFormData() + const subComponentValidateResult = this.validateSubComponents() + // const subComponentValidateResult = {valid: true, error: ''}; - // 如果是checkboxList类型,需要处理otherValues - if (val && typeof val === 'object' && val.otherValues) { - // 将otherValues中的每个值也保存到formFields中 - Object.keys(val.otherValues).forEach(otherCode => { - this.formFields[otherCode] = val.otherValues[otherCode]; - }); - } - }, - //复制 - onCopy(config, key) { - const { formFields } = this; - if (config.copyFrom) { - formFields[key] = formFields[config.copyFrom]; - this.onBlur(key, formFields[key]); - } - }, - resetRecord(key) { - this.formFields = { ...this.formFields, ...this.oldFormFields }; - this.oldFormFields = {}; - }, + return new Promise((resolve, reject) => { + if (validateResult.valid && subComponentValidateResult.valid) { + resolve(this.formFields) + } else if (!validateResult.valid) { + // this.$message.error("表单内容未填完,请填写后再提交"); + reject(validateResult.errors[0].error) + } else { + reject(subComponentValidateResult.error) + } + }) + }, + // 子组件校验钩子方法,子组件可以重写此方法来添加额外的校验逻辑 + validateSubComponents() { + return { + valid: true, + error: '' + } + }, + //直接获取表单数据,不做校验 + getFilledFormData() { + return this.formFields + }, + getFormDataByKey(key) { + return this.formFields[key] + }, + onBlur(key, val) { + // compareTo 功能:当fillType==="actFill"时,判断当前值是否与compareTo字段的值一样,如果不一样则将当前input框的背景色标记成橙色 + this.onValueChangeCompareTo(key, val) + if (this.errors[key]) { + this.$set(this.errors, key, false) + } + this.$emit('blur', { key, value: val, ...this.formFields }) + }, + onValueChangeCompareTo(key, val, compKey) { + // compareTo 功能:当fillType==="actFill"时,判断当前值是否与compareTo字段的值一样,如果不一样则将当前input框的背景色标记成橙色 + const currentFieldConfig = this.allFieldsConfig[key] + if (currentFieldConfig && currentFieldConfig.fillType === 'actFill') { + if (currentFieldConfig.compareTo || compKey) { + const compareToKey = compKey || currentFieldConfig.compareTo + const compareToValue = this.formFields[compareToKey] + this.compareFieldsIsEqual(val, compareToValue, key) + } + if ( + currentFieldConfig.otherCodeCompareTo && + this.formFields[currentFieldConfig.otherCodeCompareTo] && + this.formFields[currentFieldConfig.otherCode] + ) { + const compareToValue = + this.formFields[currentFieldConfig.otherCodeCompareTo] + const currentValue = this.formFields[currentFieldConfig.otherCode] + this.compareFieldsIsEqual( + currentValue, + compareToValue, + currentFieldConfig.otherCode + ) + } + if ( + currentFieldConfig.subCompareTo && + this.formFields[currentFieldConfig.subCompareTo] && + this.formFields[currentFieldConfig.subKey] + ) { + const compareToValue = + this.formFields[currentFieldConfig.subCompareTo] + const currentValue = this.formFields[currentFieldConfig.subKey] + this.compareFieldsIsEqual( + currentValue, + compareToValue, + currentFieldConfig.subKey + ) + } + } + }, + onAttachmentChange(key, val) { + this.formFields[key] = val + // 清除该表单项的错误状态 + if (this.errors[key]) { + this.$set(this.errors, key, false) + } + + // 如果是checkboxList类型,需要处理otherValues + if (val && typeof val === 'object' && val.otherValues) { + // 将otherValues中的每个值也保存到formFields中 + Object.keys(val.otherValues).forEach((otherCode) => { + this.formFields[otherCode] = val.otherValues[otherCode] + }) + } + }, + //复制 + onCopy(config, key) { + const { formFields } = this + if (config.copyFrom) { + formFields[key] = formFields[config.copyFrom] + this.onBlur(key, formFields[key]) + } + }, + resetRecord(key) { + this.formFields = { ...this.formFields, ...this.oldFormFields } + this.oldFormFields = {} } -} \ No newline at end of file + } +} diff --git a/src/components/Template/mixins/stepMixins.js b/src/components/Template/mixins/stepMixins.js index 476c8c7..e8b5e8d 100644 --- a/src/components/Template/mixins/stepMixins.js +++ b/src/components/Template/mixins/stepMixins.js @@ -1,126 +1,150 @@ -import { getuuid } from '@/utils/index.js'; -import { EventBus } from "@/utils/eventBus"; -import { getLatestSn, getLatestSnArr } from '@/api/template'; +import { getuuid } from '@/utils/index.js' +import { EventBus } from '@/utils/eventBus' +import { getLatestSn, getLatestSnArr } from '@/api/template' export default { - inject: ['templateFillType'], - dicts: [ - "business_tjdw", "business_czhj", "business_rqcz", "business_zldw", - "business_yqscdw", "business_zsdw", "business_wddw", "business_ccwz", "business_ggdw", - "business_hjxx", "business_zzzc", "business_step_pcr", "business_fycx", "business_step_pcrfxyp", - "business_cctj" - ], - props: { - formData: { - type: Object, - default: () => ({}) - }, - stepIndex: { - type: String, - default: '' - } + inject: ['templateFillType'], + dicts: [ + 'business_tjdw', + 'business_czhj', + 'business_rqcz', + 'business_zldw', + 'business_yqscdw', + 'business_zsdw', + 'business_wddw', + 'business_ccwz', + 'business_ggdw', + 'business_hjxx', + 'business_zzzc', + 'business_step_pcr', + 'business_fycx', + 'business_step_pcrfxyp', + 'business_cctj' + ], + props: { + formData: { + type: Object, + default: () => ({}) }, - data() { - return { - uuid: getuuid(), - fzInfo:null, - } + stepIndex: { + type: String, + default: '' + } + }, + data() { + return { + uuid: getuuid(), + fzInfo: null + } + }, + mounted() { + EventBus.$on('dialogSubPackageSubmit', (data) => { + this.onSubPackageSubmit(data) + }) + EventBus.$on('subPackageDialogPrintTag', (data) => { + this.onPrintTag(data) + }) + }, + destroyed() { + EventBus.$off('dialogSubPackageSubmit') + EventBus.$off('subPackageDialogPrintTag') + }, + + methods: { + //获取最新的多个编号 + async getLatestSnArr(params) { + const res = await getLatestSnArr(params) + if (res.code === 200) { + return res.data + } + return [] }, - mounted() { - EventBus.$on("dialogSubPackageSubmit", (data) => { - this.onSubPackageSubmit(data) - }) - EventBus.$on("subPackageDialogPrintTag", (data) => { - this.onPrintTag(data) - }) + async getLatestSn(params) { + const defaultParams = { + count: 1, + type: 1, + pre: '' + } + const finalParams = { ...defaultParams, ...params } + const res = await getLatestSn(finalParams) + if (res.code === 200) { + return res.data + } + return [] }, - destroyed() { - EventBus.$off("dialogSubPackageSubmit") - EventBus.$off("subPackageDialogPrintTag") + // 打印标签 + onPrintTag(data) { + this.$emit('printTag') }, + onSubPackageSubmit(data) { + if (data.uuid === this.uuid) { + console.log(data, 'ddd') + this.fzInfo = data + //通知后端保存数据 + const params = { + type: 'fieldChanged', + newRecord: null, + resourceList: null + } + EventBus.$emit('onModifyRecord', params) + } + }, + // 点击按钮 + onHandleClickButton(e, item, key) { + const { + buttonName = '', + myCodeFields = [], + maxVolumeField = '', + maxVolumeUnitField = '' + } = e - methods: { - //获取最新的多个编号 - async getLatestSnArr(params) { - const res = await getLatestSnArr(params) - if (res.code === 200) { - return res.data - } - return [] - }, - async getLatestSn(params) { - const defaultParams = { - count: 1, - type:1, - pre: '', - } - const finalParams = {...defaultParams, ...params} - const res = await getLatestSn(finalParams) - if (res.code === 200) { - return res.data - } - return [] - }, - // 打印标签 - onPrintTag(data) { - this.$emit("printTag") - }, - onSubPackageSubmit(data) { - if (data.uuid === this.uuid) { - console.log(data, "ddd") - this.fzInfo = data; - //通知后端保存数据 - const params = { - type: "fieldChanged", - newRecord: null, - resourceList: null, - } - EventBus.$emit('onModifyRecord', params); - } - }, - // 点击按钮 - onHandleClickButton(e, item, key) { - const { buttonName = "", myCodeFields = [], maxVolumeField = "", maxVolumeUnitField = "" } = e; - - if (buttonName === '分装') { - const fields = []; - const stepFormData = this.getFilledFormData(); - if (!myCodeFields.length || !maxVolumeField || !maxVolumeUnitField) { - console.warn("请配置分装参数") - return - } - const maxVolume = stepFormData[maxVolumeField]; - const maxVolumeUnit = stepFormData[maxVolumeUnitField]; - myCodeFields.forEach((key) => { - fields.push(stepFormData[key]) - }); + if (buttonName === '分装') { + const fields = [] + const stepFormData = this.getFilledFormData() + if (!myCodeFields.length || !maxVolumeField || !maxVolumeUnitField) { + console.warn('请配制分装参数') + return + } + const maxVolume = stepFormData[maxVolumeField] + const maxVolumeUnit = stepFormData[maxVolumeUnitField] + myCodeFields.forEach((key) => { + fields.push(stepFormData[key]) + }) - EventBus.$emit("showSubPackageDialog", { mybh: fields.join(""), maxVolume, maxVolumeUnit, uuid: this.uuid, fzType: "step" }) - } - }, + EventBus.$emit('showSubPackageDialog', { + mybh: fields.join(''), + maxVolume, + maxVolumeUnit, + uuid: this.uuid, + fzType: 'step' + }) + } + }, - async getFormData() { - return await this.$refs.stepFormPackageRef.getFormData(); - }, - getFilledFormData() { - return this.$refs.stepFormPackageRef?.getFilledFormData(); - }, - getSjResource() { - return this.$refs.stepFormPackageRef?.getSjResource(); - }, - //试验配制条件options - getDictOptions(dictType) { - return this.dict.type[dictType] || [] - }, - resetRecord() { - this.$refs.stepFormPackageRef.resetRecord(); - }, - //更新温层数据 - updateWcData(key, value) { - const options = this.getDictOptions("business_ccwz"); - const selectedOption = options.find(item => item.value === value); - if (selectedOption) { - this.$refs.stepFormPackageRef.updateFormData(key, [selectedOption.raw.remark]); - } - } + async getFormData() { + return await this.$refs.stepFormPackageRef.getFormData() + }, + getFilledFormData() { + return this.$refs.stepFormPackageRef?.getFilledFormData() + }, + getSjResource() { + return this.$refs.stepFormPackageRef?.getSjResource() + }, + //试验配制条件options + getDictOptions(dictType) { + return this.dict.type[dictType] || [] + }, + resetRecord() { + this.$refs.stepFormPackageRef.resetRecord() }, + //更新温层数据 + updateWcData(key, value) { + const options = this.getDictOptions('business_ccwz') + const selectedOption = options.find((item) => item.value === value) + if (selectedOption) { + this.$refs.stepFormPackageRef.updateFormData(key, [ + selectedOption.raw.remark + ]) + } + } + } } diff --git a/src/components/Template/operation/TableOpertaion.vue b/src/components/Template/operation/TableOpertaion.vue index fd8755f..1885b0a 100644 --- a/src/components/Template/operation/TableOpertaion.vue +++ b/src/components/Template/operation/TableOpertaion.vue @@ -105,11 +105,11 @@ export default { }); return o; }, - // 开始配置 + // 开始配制 onStartConfig() { this.$emit("startConfig", { rowData: this.innerRow, rowIndex: this.rowIndex, headerSelectFields: this.columns.headerSelectFields }) }, - // 配置完成 + // 配制完成 onConfigComplete() { const actConfig = this.getColumnConfig(); const cloneRow = JSON.parse(JSON.stringify(this.innerRow)); @@ -149,7 +149,7 @@ export default { const { myCodeFields, maxVolumeField, maxVolumeFieldUnit } = col; const fields = [], cols = [], units = []; if(!myCodeFields || myCodeFields.length === 0){ - console.warn("请先配置myCodeFields字段") + console.warn("请先配制myCodeFields字段") return } myCodeFields.forEach((key) => { diff --git a/src/lang/en.js b/src/lang/en.js index c00293a..9ae4f95 100644 --- a/src/lang/en.js +++ b/src/lang/en.js @@ -13,7 +13,7 @@ import user from './en/system/user' import template from './en/system/template' // 字典管理 import dict from './en/system/dict' -// 公共模板语言配置 +// 公共模板语言配制 import commonTemplate from './en/template/commonTemplate' //色谱模板 import sp from './en/template/sp' diff --git a/src/lang/en/business/study/studyEnter.js b/src/lang/en/business/study/studyEnter.js index 7e8c890..acee686 100644 --- a/src/lang/en/business/study/studyEnter.js +++ b/src/lang/en/business/study/studyEnter.js @@ -16,7 +16,7 @@ export default { czfzr: 'Leader', xzfzr: 'Choose', - pzfflb: '配置方法列表', + pzfflb: '配制方法列表', sjlb: '试剂列表', gsplb: '供试品列表', diff --git a/src/lang/en/template/gsp.js b/src/lang/en/template/gsp.js index 7a476ae..7a4099a 100644 --- a/src/lang/en/template/gsp.js +++ b/src/lang/en/template/gsp.js @@ -47,29 +47,29 @@ export default { xzry: '新增溶液', zl: '质量', ry: '溶液', - jspz:'结束配置', - kspz:'开始配置', - pzkssj:'配置开始时间', - pzjssj:'配置结束时间', - sywzbhph:'试验物质编号/批号', - yrybhph:'源溶液编号/批号', - yrymc:'源溶液名称', - yryyjtj:'源溶液预计体积', - yrysjtj:'源溶液实际体积', - yryyjnd:'源溶液预计浓度', - yrysjnd:'源溶液实际浓度', - yryxs:'源溶液系数', - sywzmc:'试验物资名称', - sywzzsxs:'试验物资折射系数', - sywzyjclz:'试验物质预计称量值', - sywzsjclz:'试验物质实际称量值', - rjbhph:'溶剂编号/批号', - rjmc:'溶剂名称', - rjyjtj:'溶剂预计体积', - rjsjtj:'溶剂实际体积', + jspz: '结束配制', + kspz: '开始配制', + pzkssj: '配制开始时间', + pzjssj: '配制结束时间', + sywzbhph: '试验物质编号/批号', + yrybhph: '源溶液编号/批号', + yrymc: '源溶液名称', + yryyjtj: '源溶液预计体积', + yrysjtj: '源溶液实际体积', + yryyjnd: '源溶液预计浓度', + yrysjnd: '源溶液实际浓度', + yryxs: '源溶液系数', + sywzmc: '试验物资名称', + sywzzsxs: '试验物资折射系数', + sywzyjclz: '试验物质预计称量值', + sywzsjclz: '试验物质实际称量值', + rjbhph: '溶剂编号/批号', + rjmc: '溶剂名称', + rjyjtj: '溶剂预计体积', + rjsjtj: '溶剂实际体积' }, - gsp007:{ - bzqx:'标准曲线', + gsp007: { + bzqx: '标准曲线' }, gsp009: { xtsyx: '系统适应性', diff --git a/src/lang/zh.js b/src/lang/zh.js index da943db..284ee34 100644 --- a/src/lang/zh.js +++ b/src/lang/zh.js @@ -13,7 +13,7 @@ import user from './zh/system/user' import template from './zh/system/template' // 字典管理 import dict from './zh/system/dict' -// 公共模板语言配置 +// 公共模板语言配制 import commonTemplate from './zh/template/commonTemplate' //色谱模板 import sp from './zh/template/sp' @@ -153,7 +153,7 @@ export default { closeAll: '关闭所有' }, settings: { - title: '系统布局配置', + title: '系统布局配制', theme: '主题色', tagsView: '开启 Tags-View', fixedHeader: '固定 Header', diff --git a/src/lang/zh/business/study/studyEnter.js b/src/lang/zh/business/study/studyEnter.js index 7d65355..6f83762 100644 --- a/src/lang/zh/business/study/studyEnter.js +++ b/src/lang/zh/business/study/studyEnter.js @@ -16,13 +16,12 @@ export default { czfzr: '学科/操作负责人', xzfzr: '选择负责人', - pzfflb: '配置方法列表', + pzfflb: '配制方法列表', - - sjlb:'试剂列表', - gsplb:'供试品列表', - gyzjlb:'给药制剂列表', - mjylb:'麻精药列表', - xblb:'细胞列表', - xjlb:'细菌列表', + sjlb: '试剂列表', + gsplb: '供试品列表', + gyzjlb: '给药制剂列表', + mjylb: '麻精药列表', + xblb: '细胞列表', + xjlb: '细菌列表' } diff --git a/src/lang/zh/business/study/studyFormPlan.js b/src/lang/zh/business/study/studyFormPlan.js index 24e21a4..c7e3e7e 100644 --- a/src/lang/zh/business/study/studyFormPlan.js +++ b/src/lang/zh/business/study/studyFormPlan.js @@ -20,7 +20,7 @@ export default { bzyy: '备注原因', jcgj: '稽查轨迹', cjjl: '创建记录', - xzpzjhb: '新增配置计划表', + xzpzjhb: '新增配制计划表', yes: '是', shryId: '复核人员', no: '否', @@ -49,7 +49,7 @@ export default { cjsj: '创建时间', sdsy: '锁定试验', syjj: '试验简介', - xz: '新增配置计划表', + xz: '新增配制计划表', syxkxx: '试验学科信息', ysy: '已审阅' } diff --git a/src/lang/zh/system/template.js b/src/lang/zh/system/template.js index 2a5e815..7d297fd 100644 --- a/src/lang/zh/system/template.js +++ b/src/lang/zh/system/template.js @@ -6,7 +6,7 @@ export default { statusEnable: '启用', statusDisable: '禁用', bj: '编辑', - bdpz: '表单配置', + bdpz: '表单配制', select: '选择', selectTemplate: '选择表单模板', detail: '详情' diff --git a/src/lang/zh/template/gsp.js b/src/lang/zh/template/gsp.js index e5935a3..996ef20 100644 --- a/src/lang/zh/template/gsp.js +++ b/src/lang/zh/template/gsp.js @@ -7,7 +7,7 @@ export default { lqsj: '领取时间', fxsj: '分析时间', sywz: '试验物质', - pzpl: '配置频率', + pzpl: '配制频率', gyzjhzb: '给药剂量或组别', pznd: '配制浓度', pztj: '配制体积' @@ -47,29 +47,29 @@ export default { xzry: '新增溶液', zl: '质量', ry: '溶液', - jspz:'结束配置', - kspz:'开始配置', - pzkssj:'配置开始时间', - pzjssj:'配置结束时间', - sywzbhph:'试验物质编号/批号', - yrybhph:'源溶液编号/批号', - yrymc:'源溶液名称', - yryyjtj:'源溶液预计体积', - yrysjtj:'源溶液实际体积', - yryyjnd:'源溶液预计浓度', - yrysjnd:'源溶液实际浓度', - yryxs:'源溶液系数', - sywzmc:'试验物资名称', - sywzzsxs:'试验物资折射系数', - sywzyjclz:'试验物质预计称量值', - sywzsjclz:'试验物质实际称量值', - rjbhph:'溶剂编号/批号', - rjmc:'溶剂名称', - rjyjtj:'溶剂预计体积', - rjsjtj:'溶剂实际体积', + jspz: '结束配制', + kspz: '开始配制', + pzkssj: '配制开始时间', + pzjssj: '配制结束时间', + sywzbhph: '试验物质编号/批号', + yrybhph: '源溶液编号/批号', + yrymc: '源溶液名称', + yryyjtj: '源溶液预计体积', + yrysjtj: '源溶液实际体积', + yryyjnd: '源溶液预计浓度', + yrysjnd: '源溶液实际浓度', + yryxs: '源溶液系数', + sywzmc: '试验物资名称', + sywzzsxs: '试验物资折射系数', + sywzyjclz: '试验物质预计称量值', + sywzsjclz: '试验物质实际称量值', + rjbhph: '溶剂编号/批号', + rjmc: '溶剂名称', + rjyjtj: '溶剂预计体积', + rjsjtj: '溶剂实际体积' }, - gsp007:{ - bzqx:'标准曲线', + gsp007: { + bzqx: '标准曲线' }, gsp009: { xtsyx: '系统适应性', diff --git a/src/layout/components/Settings/index.vue b/src/layout/components/Settings/index.vue index 11539b7..d74116c 100644 --- a/src/layout/components/Settings/index.vue +++ b/src/layout/components/Settings/index.vue @@ -37,7 +37,7 @@ -

系统布局配置

+

系统布局配制

开启 TopNav @@ -76,8 +76,8 @@ - 保存配置 - 重置配置 + 保存配制 + 重置配制
diff --git a/src/router/index.js b/src/router/index.js index 81ff8c0..ebb1005 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -7,7 +7,7 @@ Vue.use(Router) import Layout from '@/layout' /** - * Note: 路由配置项 + * Note: 路由配制项 * * hidden: true // 当设置 true 的时候该路由不会再侧边栏出现 如401,login等页面,或者如一些编辑页面/edit/1 * alwaysShow: true // 当你一个路由下面的 children 声明的路由大于1个时,自动会变成嵌套的模式--如组件页面 @@ -164,7 +164,7 @@ export const dynamicRoutes = [ path: 'index/:tableId(\\d+)', component: () => import('@/views/tool/gen/editTable'), name: 'GenEdit', - meta: { title: '修改生成配置', activeMenu: '/tool/gen' } + meta: { title: '修改生成配制', activeMenu: '/tool/gen' } } ] }, diff --git a/src/settings.js b/src/settings.js index b103e0c..7762cce 100644 --- a/src/settings.js +++ b/src/settings.js @@ -10,7 +10,7 @@ module.exports = { sideTheme: 'theme-dark', /** - * 系统布局配置 + * 系统布局配制 */ showSettings: true, @@ -23,7 +23,7 @@ module.exports = { * 是否显示 tagsView */ tagsView: true, - + /** * 显示页签图标 */ diff --git a/src/utils/request.js b/src/utils/request.js index e45eb0e..748c514 100644 --- a/src/utils/request.js +++ b/src/utils/request.js @@ -15,7 +15,7 @@ export let isRelogin = { show: false } axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8' // 创建axios实例 const service = axios.create({ - // axios中请求配置有baseURL选项,表示请求URL公共部分 + // axios中请求配制有baseURL选项,表示请求URL公共部分 baseURL: process.env.VUE_APP_BASE_API, // 超时 timeout: 90000 diff --git a/src/views/business/comps/template/comps/bl/BL001.vue b/src/views/business/comps/template/comps/bl/BL001.vue index 4fe1a10..7cfae14 100644 --- a/src/views/business/comps/template/comps/bl/BL001.vue +++ b/src/views/business/comps/template/comps/bl/BL001.vue @@ -121,7 +121,7 @@ export default { } }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -140,7 +140,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/bl/BL002.vue b/src/views/business/comps/template/comps/bl/BL002.vue index 038979e..930d04e 100644 --- a/src/views/business/comps/template/comps/bl/BL002.vue +++ b/src/views/business/comps/template/comps/bl/BL002.vue @@ -102,7 +102,7 @@ export default { } }, computed: { - // 扫描员备注表单配置 + // 扫描员备注表单配制 smyRemarkConig() { return [ { @@ -121,7 +121,7 @@ export default { } ] }, - // 专题病理学家备注表单配置 + // 专题病理学家备注表单配制 ztblxjRemarkConig() { return [ { @@ -140,7 +140,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dj/DJ001.vue b/src/views/business/comps/template/comps/dj/DJ001.vue index cefdef0..81b27be 100644 --- a/src/views/business/comps/template/comps/dj/DJ001.vue +++ b/src/views/business/comps/template/comps/dj/DJ001.vue @@ -93,7 +93,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -112,7 +112,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -133,7 +133,7 @@ export default { ] }, - //操作步骤配置 + //操作步骤配制 operateConfig() { return [ { @@ -149,7 +149,7 @@ export default { ] }, - //复核范围配置 + //复核范围配制 fhfwCheckBoxConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dj/DJ002.vue b/src/views/business/comps/template/comps/dj/DJ002.vue index ae5b193..6dbf985 100644 --- a/src/views/business/comps/template/comps/dj/DJ002.vue +++ b/src/views/business/comps/template/comps/dj/DJ002.vue @@ -121,7 +121,7 @@ export default { } }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -140,7 +140,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dj/DJ003.vue b/src/views/business/comps/template/comps/dj/DJ003.vue index eef69bc..65af1c1 100644 --- a/src/views/business/comps/template/comps/dj/DJ003.vue +++ b/src/views/business/comps/template/comps/dj/DJ003.vue @@ -97,7 +97,7 @@ export default { } }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -116,7 +116,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL003.vue b/src/views/business/comps/template/comps/dl/DL003.vue index 6deac9f..6eea372 100644 --- a/src/views/business/comps/template/comps/dl/DL003.vue +++ b/src/views/business/comps/template/comps/dl/DL003.vue @@ -91,7 +91,7 @@ export default { } }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -117,7 +117,7 @@ export default { // } // const re = convertConcentration.convert('100mg/mL',"ng/mL") }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL004.vue b/src/views/business/comps/template/comps/dl/DL004.vue index 10fbfb9..3d8bf99 100644 --- a/src/views/business/comps/template/comps/dl/DL004.vue +++ b/src/views/business/comps/template/comps/dl/DL004.vue @@ -99,7 +99,7 @@ export default { } }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -125,7 +125,7 @@ export default { // } // const re = convertConcentration.convert('100mg/mL',"ng/mL") }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL005.vue b/src/views/business/comps/template/comps/dl/DL005.vue index 462533e..60f13ec 100644 --- a/src/views/business/comps/template/comps/dl/DL005.vue +++ b/src/views/business/comps/template/comps/dl/DL005.vue @@ -79,7 +79,7 @@ export default { } }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -105,7 +105,7 @@ export default { // } // const re = convertConcentration.convert('100mg/mL',"ng/mL") }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL006.vue b/src/views/business/comps/template/comps/dl/DL006.vue index ddc9eda..3c2d59d 100644 --- a/src/views/business/comps/template/comps/dl/DL006.vue +++ b/src/views/business/comps/template/comps/dl/DL006.vue @@ -156,7 +156,7 @@ export default { this.rawCzxxColumns = newColumns; } }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -176,7 +176,7 @@ export default { ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -584,7 +584,7 @@ export default { onCzChange(e) { const { sftjs9 , key } = e; if(key == 'sftjs9'){ - // 抽离固定配置(和之前一致) + // 抽离固定配制(和之前一致) const configMap = { 1: { s9hhybh: { @@ -622,7 +622,7 @@ export default { } }; - // 选择要添加的配置和要删除的冗余配置 + // 选择要添加的配制和要删除的冗余配制 let addConfig, removeKeys; if (sftjs9 === 1) { addConfig = configMap[1]; @@ -648,11 +648,11 @@ export default { // 最后一项单独保留 const lastConfig = lastKey ? { [lastKey]: newConfig[lastKey] } : {}; - // 3. 重新组合:前半部分 → 新增配置 → 最后一项 + // 3. 重新组合:前半部分 → 新增配制 → 最后一项 newConfig = { - ...frontConfig, // 原配置的前半部分 - ...addConfig, // 新增的两个配置项(插入到最后一项前面) - ...lastConfig // 原配置的最后一项 + ...frontConfig, // 原配制的前半部分 + ...addConfig, // 新增的两个配制项(插入到最后一项前面) + ...lastConfig // 原配制的最后一项 }; // 4. 赋值回item.config @@ -664,7 +664,7 @@ export default { clickFinish() { // 获取表单数据 const { jzs, jlzsl, pxms, qsbh, stepTableFormData = [] } = this.getFilledFormData(); - // 初始化列配置数组 + // 初始化列配制数组 let columns = []; // 1. 添加固定列:剂量组别 @@ -734,9 +734,9 @@ export default { bodyFillType: 'actFill', // 修复:原bodyTypeFillType拼写错误 }); - // 关键修复1:先更新列配置,确保表格能识别字段 + // 关键修复1:先更新列配制,确保表格能识别字段 this.rawCzxxColumns = [...columns]; // 解构赋值触发响应式更新 - this.$nextTick(() => { // 等待列配置更新完成后再赋值数据 + this.$nextTick(() => { // 等待列配制更新完成后再赋值数据 const doseGroupCount = Number(stepTableFormData.length) || 0; const parallelDishCount = Number(pxms) || 0; if (doseGroupCount <= 0 || parallelDishCount <= 0) { diff --git a/src/views/business/comps/template/comps/dl/DL007.vue b/src/views/business/comps/template/comps/dl/DL007.vue index caba3f2..0f08b8e 100644 --- a/src/views/business/comps/template/comps/dl/DL007.vue +++ b/src/views/business/comps/template/comps/dl/DL007.vue @@ -97,7 +97,7 @@ export default { } }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConfig() { return [ { @@ -116,7 +116,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL008.vue b/src/views/business/comps/template/comps/dl/DL008.vue index 0019082..4ccdb6c 100644 --- a/src/views/business/comps/template/comps/dl/DL008.vue +++ b/src/views/business/comps/template/comps/dl/DL008.vue @@ -124,7 +124,7 @@ export default { headerSelectFields: {} } }, - // 备注表单配置 + // 备注表单配制 remarkConfig() { return [ { @@ -163,7 +163,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -212,9 +212,9 @@ export default { } ] }, - // 成像情况-checkbox网格配置 + // 成像情况-checkbox网格配制 cxqkColumns() { - // 只有在有动态列配置时才返回列配置,否则返回空数组(不显示表格) + // 只有在有动态列配制时才返回列配制,否则返回空数组(不显示表格) return this.dynamicCxqkColumns }, // 仪器使用信息 @@ -275,7 +275,7 @@ export default { return { formData: {}, refConf, - dynamicCxqkColumns: [], // 动态成像情况表格列配置 + dynamicCxqkColumns: [], // 动态成像情况表格列配制 isDataLoaded: false // 标记数据是否已加载 } }, @@ -327,7 +327,7 @@ export default { return } - // 根据已有的 Label 字段生成动态列配置 + // 根据已有的 Label 字段生成动态列配制 const dynamicColumns = [ { label: 'template.dl.dl008.jlzb', @@ -367,11 +367,11 @@ export default { }) }) - // 更新动态列配置 + // 更新动态列配制 this.dynamicCxqkColumns = dynamicColumns this.isDataLoaded = true - // 等待列配置更新后,更新表格数据 + // 等待列配制更新后,更新表格数据 this.$nextTick(() => { if (this.$refs[refConf.cxqk]) { this.$refs[refConf.cxqk].updateDataSource(stepTableFormData_1) @@ -486,7 +486,7 @@ export default { return } - // 1. 生成动态列配置 + // 1. 生成动态列配制 const dynamicColumns = this.generateDynamicColumns(headerFields) if (!dynamicColumns) { this.clearCxqkTable() @@ -511,7 +511,7 @@ export default { } }, - // 生成动态列配置 + // 生成动态列配制 generateDynamicColumns(headerFields) { // 获取所有以 _1 结尾的 key,这些代表列的索引 const columnKeys = Object.keys(headerFields) @@ -592,7 +592,7 @@ export default { // 更新成像情况表格 updateCxqkTable(columns, tableData, headerFields) { - // 更新动态列配置 + // 更新动态列配制 this.dynamicCxqkColumns = columns // 保存 headerFields 到 formData,用于数据回显 diff --git a/src/views/business/comps/template/comps/dl/DL009.vue b/src/views/business/comps/template/comps/dl/DL009.vue index 1df900e..d8bf347 100644 --- a/src/views/business/comps/template/comps/dl/DL009.vue +++ b/src/views/business/comps/template/comps/dl/DL009.vue @@ -137,7 +137,7 @@ export default { headerSelectFields: {} } }, - // 备注表单配置 + // 备注表单配制 remarkConfig() { return [ { @@ -156,7 +156,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -176,7 +176,7 @@ export default { } ] }, - // 处理条件表单配置 + // 处理条件表单配制 cltjFormConfig() { return [ { @@ -259,7 +259,7 @@ export default { } ] }, - // 结果信息前序表单配置 + // 结果信息前序表单配制 jgxxQxbdFormConfig() { return [ { @@ -278,7 +278,7 @@ export default { }, // 结果信息列表 jgxxColumns() { - // 只有在有动态列配置时才返回列配置,否则返回空数组(不显示表格) + // 只有在有动态列配制时才返回列配制,否则返回空数组(不显示表格) return this.dynamicJgxxColumns } }, @@ -286,7 +286,7 @@ export default { return { formData: {}, refConf, - dynamicJgxxColumns: [], // 动态结果信息表格列配置 + dynamicJgxxColumns: [], // 动态结果信息表格列配制 isDataLoaded: false // 标记数据是否已加载 } }, @@ -317,11 +317,11 @@ export default { deep: true, immediate: true }, - // 监听字典数据加载完成后,如果有动态列配置需要更新 + // 监听字典数据加载完成后,如果有动态列配制需要更新 'dict.type.business_dl_amescdqk': { handler(newVal) { if (newVal && newVal.length > 0 && this.dynamicJgxxColumns.length > 0) { - // 如果已经有动态列配置,需要更新 bodyOptions + // 如果已经有动态列配制,需要更新 bodyOptions this.updateDynamicColumnsOptions() } }, @@ -362,7 +362,7 @@ export default { return } - // 根据已有的 jzbh 字段生成动态列配置 + // 根据已有的 jzbh 字段生成动态列配制 const dynamicColumns = [ { label: 'template.dl.dl009.jlzb', @@ -422,7 +422,7 @@ export default { }) }) - // 更新动态列配置 + // 更新动态列配制 this.dynamicJgxxColumns = dynamicColumns // 保存 headerSelectFields 到 formData.headerSelectFields(确保数据一致) @@ -439,7 +439,7 @@ export default { this.isDataLoaded = true - // 等待列配置更新后,更新表格数据 + // 等待列配制更新后,更新表格数据 this.$nextTick(() => { const tableRef = this.$refs[refConf.jgxx] if (tableRef) { @@ -606,7 +606,7 @@ export default { return } - // 1. 生成动态列配置 + // 1. 生成动态列配制 const dynamicColumns = this.generateDynamicJgxxColumns(headerFields) if (!dynamicColumns) { this.clearJgxxTable() @@ -635,7 +635,7 @@ export default { const formData = this.getStepResource() }, - // 生成动态列配置 + // 生成动态列配制 generateDynamicJgxxColumns(headerFields) { // 获取所有以 _1 结尾的 key,这些代表列的索引 const columnKeys = Object.keys(headerFields) @@ -736,7 +736,7 @@ export default { // 更新结果信息表格 updateJgxxTable(columns, tableData, headerFields, savedYqsyData) { - // 更新动态列配置 + // 更新动态列配制 this.dynamicJgxxColumns = columns // 保存 headerFields 到 formData,用于数据回显 @@ -792,13 +792,13 @@ export default { this.$refs[refConf.jgxx]?.updateDataSource([]) }) }, - // 更新动态列配置的字典选项 + // 更新动态列配制的字典选项 updateDynamicColumnsOptions() { if (this.dynamicJgxxColumns.length === 0) { return } - // 遍历动态列配置,更新 select 类型的 bodyOptions + // 遍历动态列配制,更新 select 类型的 bodyOptions this.dynamicJgxxColumns.forEach((col) => { if (col.bodyType === 'select') { if (col.prop.startsWith('czqk')) { diff --git a/src/views/business/comps/template/comps/dl/DL010.vue b/src/views/business/comps/template/comps/dl/DL010.vue index 6001839..9e95fda 100644 --- a/src/views/business/comps/template/comps/dl/DL010.vue +++ b/src/views/business/comps/template/comps/dl/DL010.vue @@ -127,7 +127,7 @@ export default { } }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConfig() { return [ { @@ -146,7 +146,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL011.vue b/src/views/business/comps/template/comps/dl/DL011.vue index 352e970..15463f8 100644 --- a/src/views/business/comps/template/comps/dl/DL011.vue +++ b/src/views/business/comps/template/comps/dl/DL011.vue @@ -114,7 +114,7 @@ export default { } }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConfig() { return [ { @@ -133,7 +133,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL012.vue b/src/views/business/comps/template/comps/dl/DL012.vue index 1dc84ff..0abc403 100644 --- a/src/views/business/comps/template/comps/dl/DL012.vue +++ b/src/views/business/comps/template/comps/dl/DL012.vue @@ -79,7 +79,7 @@ export default { } }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConfig() { return [ { @@ -98,7 +98,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -147,7 +147,7 @@ export default { } ] }, - // 培养信息配置 + // 培养信息配制 pyxxConfig() { return [ { @@ -176,7 +176,7 @@ export default { } ] }, - // 细胞信息配置 - 根据 formData 中已有的 zbhxbbh_ 字段动态渲染 + // 细胞信息配制 - 根据 formData 中已有的 zbhxbbh_ 字段动态渲染 xbxxConfig() { const config = { xbmc: { @@ -298,7 +298,7 @@ export default { } } - // 等配置更新后,同步到子组件的 formFields + // 等配制更新后,同步到子组件的 formFields if (Object.keys(updateData).length > 0) { this.$nextTick(() => { this.$refs[refConf.xbxx].batchUpdateFormData(updateData) diff --git a/src/views/business/comps/template/comps/dl/DL013.vue b/src/views/business/comps/template/comps/dl/DL013.vue index 503c098..52672c0 100644 --- a/src/views/business/comps/template/comps/dl/DL013.vue +++ b/src/views/business/comps/template/comps/dl/DL013.vue @@ -141,7 +141,7 @@ export default { } }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConfig() { return [ { @@ -160,7 +160,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -317,7 +317,7 @@ export default { } }, methods: { - // 获取每次测定的表单配置 + // 获取每次测定的表单配制 getCdxxTimeConfig(index) { return [ { @@ -421,7 +421,7 @@ export default { return 0 } }, - // 删除测定信息配置 + // 删除测定信息配制 handleCdxxDelete(cdxxItem) { const configIndex = this.formData.cdxxConfigs.findIndex( (config) => config.id === cdxxItem.id @@ -467,12 +467,12 @@ export default { this.$set(this.formData, 'yqsyTableheaderFields', currentYqsyData.headerFields || {}) } - // 初始化测定信息配置列表 + // 初始化测定信息配制列表 if (!this.formData.cdxxConfigs) { this.$set(this.formData, 'cdxxConfigs', []) } - // 创建新的测定信息配置对象 + // 创建新的测定信息配制对象 const newCdxxItem = { id: getuuid(), xsbs: null, @@ -483,7 +483,7 @@ export default { yxg: null } - // 添加新的测定信息配置 + // 添加新的测定信息配制 this.formData.cdxxConfigs.push(newCdxxItem) // 更新测定次数 diff --git a/src/views/business/comps/template/comps/dl/DL014.vue b/src/views/business/comps/template/comps/dl/DL014.vue index 823c441..4979661 100644 --- a/src/views/business/comps/template/comps/dl/DL014.vue +++ b/src/views/business/comps/template/comps/dl/DL014.vue @@ -124,7 +124,7 @@ export default { headerSelectFields: this.formData.jlzHeaderSelectFields || {} } }, - // 备注表单配置 + // 备注表单配制 remarkConfig() { return [ { @@ -143,7 +143,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -227,7 +227,7 @@ export default { } ] }, - // 细胞信息表单配置 + // 细胞信息表单配制 xbInfoFormConfig() { return [ { @@ -253,7 +253,7 @@ export default { } ] }, - // 剂量组配制信息表单配置 + // 剂量组配制信息表单配制 jlzInfoFormConfig() { const firstStepConfig = { pxpb: { @@ -306,7 +306,7 @@ export default { } ] }, - // 剂量组名称表格列配置 + // 剂量组名称表格列配制 jlzmcTableColumns() { return [ { @@ -318,7 +318,7 @@ export default { } ] }, - // 培养液表单配置 + // 培养液表单配制 pyyFormConfig() { return [ { @@ -337,7 +337,7 @@ export default { } ] }, - // 剂量组表格列配置 + // 剂量组表格列配制 jlzTableColumns() { const columns = [ { diff --git a/src/views/business/comps/template/comps/dl/DL015.vue b/src/views/business/comps/template/comps/dl/DL015.vue index 72d5502..93b4fc8 100644 --- a/src/views/business/comps/template/comps/dl/DL015.vue +++ b/src/views/business/comps/template/comps/dl/DL015.vue @@ -115,7 +115,7 @@ export default { headerSelectFields: this.formData.headerSelectFields || {} } }, - // 备注表单配置 + // 备注表单配制 remarkConfig() { return [ { @@ -134,7 +134,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -184,7 +184,7 @@ export default { } ] }, - // 细胞信息表单配置 + // 细胞信息表单配制 xbInfoFormConfig() { return [ { @@ -209,7 +209,7 @@ export default { } ] }, - // 换液情况表格列配置 + // 换液情况表格列配制 hyqkColumns() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL016.vue b/src/views/business/comps/template/comps/dl/DL016.vue index c2a5ccb..e5ec706 100644 --- a/src/views/business/comps/template/comps/dl/DL016.vue +++ b/src/views/business/comps/template/comps/dl/DL016.vue @@ -68,7 +68,7 @@ export default { headerSelectFields: {} } }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -87,7 +87,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL017.vue b/src/views/business/comps/template/comps/dl/DL017.vue index a5a0a5c..28f64ba 100644 --- a/src/views/business/comps/template/comps/dl/DL017.vue +++ b/src/views/business/comps/template/comps/dl/DL017.vue @@ -69,7 +69,7 @@ export default { headerSelectFields: {} } }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -88,7 +88,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL018.vue b/src/views/business/comps/template/comps/dl/DL018.vue index a7f91d3..3bf0b10 100644 --- a/src/views/business/comps/template/comps/dl/DL018.vue +++ b/src/views/business/comps/template/comps/dl/DL018.vue @@ -72,7 +72,7 @@ export default { headerSelectFields: {} } }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -91,7 +91,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL019.vue b/src/views/business/comps/template/comps/dl/DL019.vue index 56ad972..01bf7a0 100644 --- a/src/views/business/comps/template/comps/dl/DL019.vue +++ b/src/views/business/comps/template/comps/dl/DL019.vue @@ -75,7 +75,7 @@ export default { headerSelectFields: {} } }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -94,7 +94,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL020.vue b/src/views/business/comps/template/comps/dl/DL020.vue index 3a2a510..ea48c7e 100644 --- a/src/views/business/comps/template/comps/dl/DL020.vue +++ b/src/views/business/comps/template/comps/dl/DL020.vue @@ -45,7 +45,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -64,7 +64,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL021.vue b/src/views/business/comps/template/comps/dl/DL021.vue index f408a7d..325998f 100644 --- a/src/views/business/comps/template/comps/dl/DL021.vue +++ b/src/views/business/comps/template/comps/dl/DL021.vue @@ -70,7 +70,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -89,7 +89,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL022.vue b/src/views/business/comps/template/comps/dl/DL022.vue index 13e9306..e9a0aab 100644 --- a/src/views/business/comps/template/comps/dl/DL022.vue +++ b/src/views/business/comps/template/comps/dl/DL022.vue @@ -74,7 +74,7 @@ export default { headerSelectFields: {} } }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -93,7 +93,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL023.vue b/src/views/business/comps/template/comps/dl/DL023.vue index 0d64b44..d4133fb 100644 --- a/src/views/business/comps/template/comps/dl/DL023.vue +++ b/src/views/business/comps/template/comps/dl/DL023.vue @@ -58,7 +58,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -77,7 +77,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/dl/DL024.vue b/src/views/business/comps/template/comps/dl/DL024.vue index 57fc79b..a7177d2 100644 --- a/src/views/business/comps/template/comps/dl/DL024.vue +++ b/src/views/business/comps/template/comps/dl/DL024.vue @@ -75,7 +75,7 @@ export default { headerSelectFields: {} } }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -94,7 +94,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/gsp/DMYPPZJLB.vue b/src/views/business/comps/template/comps/gsp/DMYPPZJLB.vue index b41874d..df22582 100644 --- a/src/views/business/comps/template/comps/gsp/DMYPPZJLB.vue +++ b/src/views/business/comps/template/comps/gsp/DMYPPZJLB.vue @@ -72,7 +72,7 @@ export default { }, }, computed: { - // 配置条件 + // 配制条件 storageFormConfig() { return [ { @@ -90,7 +90,7 @@ export default { } ]; }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -109,7 +109,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -180,7 +180,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/gsp/GSP001.vue b/src/views/business/comps/template/comps/gsp/GSP001.vue index 12b7dbb..9458edd 100644 --- a/src/views/business/comps/template/comps/gsp/GSP001.vue +++ b/src/views/business/comps/template/comps/gsp/GSP001.vue @@ -71,7 +71,7 @@ export default { }, }, computed: { - // 配置条件 + // 配制条件 storageFormConfig() { return [ { @@ -89,7 +89,7 @@ export default { } ]; }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -108,7 +108,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -179,7 +179,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/gsp/GSP002.vue b/src/views/business/comps/template/comps/gsp/GSP002.vue index 90ae84f..203c908 100644 --- a/src/views/business/comps/template/comps/gsp/GSP002.vue +++ b/src/views/business/comps/template/comps/gsp/GSP002.vue @@ -105,7 +105,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -124,7 +124,7 @@ export default { } ]; }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -546,7 +546,7 @@ export default { "存储条件": stepStorageCondition || paralleStepStorageCondition, "配制日期": moment(startDate).format("YYYY-MM-DD"), "有效期至": moment(targetSolutionExpirationDate || expireDate).format("YYYY-MM-DD HH:mm"), - "配置者": lang === "zh_CN" ? nickName : name, + "配制者": lang === "zh_CN" ? nickName : name, //type==="subPackage"从分装打印过来的, //type==="row" 从列表上点过来的 "编号": type === "subPackage" ? printCode : (row.targetSolutionCode + row.subTargetSolutionCode), @@ -613,18 +613,18 @@ export default { }, //新增平行配制 handleAddParalle() { - // 初始化平行配制配置列表 + // 初始化平行配制配制列表 if (!this.formData.paralleConfigs) { this.$set(this.formData, 'paralleConfigs', []); } - // 添加新的平行配制配置 + // 添加新的平行配制配制 this.formData.paralleConfigs.push({ paralleStepData: [], paralleTableFormData: [], showParalleConfig: true }); }, - //删除平行配制配置 + //删除平行配制配制 deleteParalleConfig(index) { this.formData.paralleConfigs.splice(index, 1); }, diff --git a/src/views/business/comps/template/comps/gsp/GSP003.vue b/src/views/business/comps/template/comps/gsp/GSP003.vue index 5d526ae..6c2261d 100644 --- a/src/views/business/comps/template/comps/gsp/GSP003.vue +++ b/src/views/business/comps/template/comps/gsp/GSP003.vue @@ -94,7 +94,7 @@ export default { } ]; }, - // 配置条件 + // 配制条件 storageFormConfig() { return [ { @@ -112,7 +112,7 @@ export default { } ]; }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -131,7 +131,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -202,7 +202,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/gsp/GSP004.vue b/src/views/business/comps/template/comps/gsp/GSP004.vue index 099aa0e..dc96c05 100644 --- a/src/views/business/comps/template/comps/gsp/GSP004.vue +++ b/src/views/business/comps/template/comps/gsp/GSP004.vue @@ -101,7 +101,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -137,7 +137,7 @@ export default { } ]; }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -569,7 +569,7 @@ export default { "存储条件": stepStorageCondition || paralleStepStorageCondition, "配制日期": moment(startDate).format("YYYY-MM-DD"), "有效期至": moment(targetSolutionExpirationDate || expireDate).format("YYYY-MM-DD HH:mm"), - "配置者": lang === "zh_CN" ? nickName : name, + "配制者": lang === "zh_CN" ? nickName : name, //type==="subPackage"从分装打印过来的, //type==="row" 从列表上点过来的 "编号": type === "subPackage" ? printCode : (row.targetSolutionCode + row.subTargetSolutionCode), @@ -636,18 +636,18 @@ export default { }, //新增平行配制 handleAddParalle() { - // 初始化平行配制配置列表 + // 初始化平行配制配制列表 if (!this.formData.paralleConfigs) { this.$set(this.formData, 'paralleConfigs', []); } - // 添加新的平行配制配置 + // 添加新的平行配制配制 this.formData.paralleConfigs.push({ paralleStepData: [], paralleTableFormData: [], showParalleConfig: true }); }, - //删除平行配制配置 + //删除平行配制配制 deleteParalleConfig(index) { this.formData.paralleConfigs.splice(index, 1); }, diff --git a/src/views/business/comps/template/comps/gsp/GSP005.vue b/src/views/business/comps/template/comps/gsp/GSP005.vue index da5ed1c..05da277 100644 --- a/src/views/business/comps/template/comps/gsp/GSP005.vue +++ b/src/views/business/comps/template/comps/gsp/GSP005.vue @@ -114,7 +114,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -133,7 +133,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -634,7 +634,7 @@ export default { onClickButtonZl(zlIndex, data){ alert('todo') }, - //溶液开始配置 + //溶液开始配制 ryKspz(zlIndex) { this.$refs[`formRyConfigFormPackageRef_${zlIndex}`][0].updateFormData('pzkssj', moment().format("YYYY-MM-DD HH:mm:ss")) const rowData = this.$refs[`formRyConfigFormPackageRef_${zlIndex}`][0].getFilledFormData() @@ -646,7 +646,7 @@ export default { } this.startConfigRequest(postData); }, - //溶液结束配置 + //溶液结束配制 ryJspz(zlIndex) { this.$refs[`formRyConfigFormPackageRef_${zlIndex}`][0].updateFormData('pzjssj', moment().format("YYYY-MM-DD HH:mm:ss")) const rowData = this.$refs[`formRyConfigFormPackageRef_${zlIndex}`][0].getFilledFormData() @@ -663,7 +663,7 @@ export default { } this.configCompleteRequest(postData); }, - //质量开始配置 + //质量开始配制 zlKspz(zlIndex) { this.$refs[`formZlConfigFormPackageRef_${zlIndex}`][0].updateFormData('pzkssj', moment().format("YYYY-MM-DD HH:mm:ss")) const rowData = this.$refs[`formZlConfigFormPackageRef_${zlIndex}`][0].getFilledFormData() @@ -675,7 +675,7 @@ export default { } this.startConfigRequest(postData); }, - //质量结束配置 + //质量结束配制 zlJspz(zlIndex) { this.$refs[`formZlConfigFormPackageRef_${zlIndex}`][0].updateFormData('pzjssj', moment().format("YYYY-MM-DD HH:mm:ss")) const rowData = this.$refs[`formZlConfigFormPackageRef_${zlIndex}`][0].getFilledFormData() diff --git a/src/views/business/comps/template/comps/gsp/GSP009.vue b/src/views/business/comps/template/comps/gsp/GSP009.vue index 2600afd..cec9da4 100644 --- a/src/views/business/comps/template/comps/gsp/GSP009.vue +++ b/src/views/business/comps/template/comps/gsp/GSP009.vue @@ -75,7 +75,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -94,7 +94,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -259,7 +259,7 @@ export default { //生成resource let tmpResource = [] if (this.fillType === "actFill") { - //平行配置 + //平行配制 if (content.paralleConfigs && content.paralleConfigs.length > 0) { for (let i = 0; i < content.paralleConfigs.length; i++) { let paralleConfigs = content.paralleConfigs[i] @@ -309,18 +309,18 @@ export default { isAdd = true } if(isAdd){ - // 初始化平行配制配置列表 + // 初始化平行配制配制列表 if (!this.formData.paralleConfigs) { this.$set(this.formData, 'paralleConfigs', []); } - // 添加新的平行配制配置 + // 添加新的平行配制配制 this.formData.paralleConfigs.push({ showParalleConfig: true }); } //todo: 需要回调保存? }, - // 删除平行配制配置 + // 删除平行配制配制 deleteParalleConfig(index) { if(this.formData.paralleConfigs.length===1){ this.$message.error("至少需要1个"); diff --git a/src/views/business/comps/template/comps/gsp/GSP010.vue b/src/views/business/comps/template/comps/gsp/GSP010.vue index dc83c71..f586835 100644 --- a/src/views/business/comps/template/comps/gsp/GSP010.vue +++ b/src/views/business/comps/template/comps/gsp/GSP010.vue @@ -68,7 +68,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -87,7 +87,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -158,7 +158,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/gsp/GSP015.vue b/src/views/business/comps/template/comps/gsp/GSP015.vue index 20d64cb..139cc57 100644 --- a/src/views/business/comps/template/comps/gsp/GSP015.vue +++ b/src/views/business/comps/template/comps/gsp/GSP015.vue @@ -141,11 +141,11 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return getRemarkFormConfig(this) }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return getBaseInfoFormConfig(this) }, @@ -161,7 +161,7 @@ export default { yjColumns() { return getJyTableColumns(this) }, - // 二次稀释表单配置 + // 二次稀释表单配制 ecFormConfig() { return getEcFormConfig(this) }, @@ -307,7 +307,7 @@ export default { id: getuuid(), } this.formData = { ...this.formData, ...this.getFilledFormData() }; - // 添加新的平行配制配置 + // 添加新的平行配制配制 this.formData[type].push(defaultInfo); this.justUpdateFilledFormData(); }, @@ -391,7 +391,7 @@ export default { //生成resource let tmpResource = [] if (this.fillType === "actFill") { - //配置的试剂 + //配制的试剂 tmpResource.push({ mc: content.targetName, bh: content.targetCode + content.targetCodeSn, diff --git a/src/views/business/comps/template/comps/gsp/MJYLQSQD.vue b/src/views/business/comps/template/comps/gsp/MJYLQSQD.vue index be18aa2..95c09e9 100644 --- a/src/views/business/comps/template/comps/gsp/MJYLQSQD.vue +++ b/src/views/business/comps/template/comps/gsp/MJYLQSQD.vue @@ -63,7 +63,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -82,7 +82,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/gsp/SYWZPZJHB.vue b/src/views/business/comps/template/comps/gsp/SYWZPZJHB.vue index 66905ea..5516435 100644 --- a/src/views/business/comps/template/comps/gsp/SYWZPZJHB.vue +++ b/src/views/business/comps/template/comps/gsp/SYWZPZJHB.vue @@ -62,7 +62,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -81,7 +81,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -102,7 +102,7 @@ export default { }, ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { @@ -132,7 +132,7 @@ export default { } ] }, - // 步骤表格列配置 + // 步骤表格列配制 stepColumns() { return [ { diff --git a/src/views/business/comps/template/comps/lba/LBA002.vue b/src/views/business/comps/template/comps/lba/LBA002.vue index 8ddc1b2..96d909e 100644 --- a/src/views/business/comps/template/comps/lba/LBA002.vue +++ b/src/views/business/comps/template/comps/lba/LBA002.vue @@ -61,7 +61,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -80,7 +80,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -151,7 +151,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 tableStepColumns() { return [{ label: 'template.lba.lba002.jcbmc', diff --git a/src/views/business/comps/template/comps/lba/LBA003.vue b/src/views/business/comps/template/comps/lba/LBA003.vue index de1fced..6d9566d 100644 --- a/src/views/business/comps/template/comps/lba/LBA003.vue +++ b/src/views/business/comps/template/comps/lba/LBA003.vue @@ -46,7 +46,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -65,7 +65,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -135,7 +135,7 @@ export default { } ] }, - // 附件表单配置 + // 附件表单配制 getFjFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/lba/LBA004.vue b/src/views/business/comps/template/comps/lba/LBA004.vue index 12e74c0..b3ab948 100644 --- a/src/views/business/comps/template/comps/lba/LBA004.vue +++ b/src/views/business/comps/template/comps/lba/LBA004.vue @@ -105,7 +105,7 @@ export default { }, }, computed: { - // 操作步骤表单配置 + // 操作步骤表单配制 jcbColumns() { return [{ label: 'template.lba.lba002.jcbmc', @@ -122,7 +122,7 @@ export default { width: 280 }] }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -141,7 +141,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -211,7 +211,7 @@ export default { } ] }, - // 附件表单配置 + // 附件表单配制 getFjFormConfig() { return [ { @@ -385,7 +385,7 @@ export default { //生成resource let tmpResource = [] if (this.fillType === "actFill") { - //平行配置 + //平行配制 if (content.paralleConfigs && content.paralleConfigs.length > 0) { for (let i = 0; i < content.paralleConfigs.length; i++) { let paralleConfigs = content.paralleConfigs[i] @@ -449,11 +449,11 @@ export default { isAdd = true } if(isAdd){ - // 初始化平行配制配置列表 + // 初始化平行配制配制列表 if (!this.formData.paralleConfigs) { this.$set(this.formData, 'paralleConfigs', []); } - // 添加新的平行配制配置 + // 添加新的平行配制配制 this.formData.paralleConfigs.push({ paralleStepData: [], paralleTableFormData: [], @@ -461,7 +461,7 @@ export default { }); } }, - // 删除平行配制配置 + // 删除平行配制配制 deleteParalleConfig(index) { if(this.formData.paralleConfigs.length===1){ this.$message.error("至少需要1个"); diff --git a/src/views/business/comps/template/comps/lba/LBA006.vue b/src/views/business/comps/template/comps/lba/LBA006.vue index f83cd2c..918065a 100644 --- a/src/views/business/comps/template/comps/lba/LBA006.vue +++ b/src/views/business/comps/template/comps/lba/LBA006.vue @@ -67,7 +67,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -86,7 +86,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -257,18 +257,18 @@ export default { isAdd = true } if(isAdd){ - // 初始化平行配制配置列表 + // 初始化平行配制配制列表 if (!this.formData.paralleConfigs) { this.$set(this.formData, 'paralleConfigs', []); } - // 添加新的平行配制配置 + // 添加新的平行配制配制 this.formData.paralleConfigs.push({ showParalleConfig: true, uuid:getuuid() }); } }, - // 删除平行配制配置 + // 删除平行配制配制 deleteParalleConfig(index) { if(this.formData.paralleConfigs.length===1){ this.$message.error("至少需要1个"); diff --git a/src/views/business/comps/template/comps/lba/LBA008.vue b/src/views/business/comps/template/comps/lba/LBA008.vue index 1ba72d0..beab7f9 100644 --- a/src/views/business/comps/template/comps/lba/LBA008.vue +++ b/src/views/business/comps/template/comps/lba/LBA008.vue @@ -76,7 +76,7 @@ export default { tableStepColumns() { return getLBA008Config(this); }, - // 附件表单配置 + // 附件表单配制 getFjFormConfig() { return [ { @@ -91,7 +91,7 @@ export default { } ] }, - // 配置条件 + // 配制条件 storageFormConfig() { return [ { @@ -109,7 +109,7 @@ export default { } ]; }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -128,7 +128,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -185,7 +185,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/pcr/PCR005.vue b/src/views/business/comps/template/comps/pcr/PCR005.vue index 33d5f3e..794c161 100644 --- a/src/views/business/comps/template/comps/pcr/PCR005.vue +++ b/src/views/business/comps/template/comps/pcr/PCR005.vue @@ -80,7 +80,7 @@ export default { tableStepColumns() { return getPCR005Config(this); }, - // 附件表单配置 + // 附件表单配制 getFjFormConfig() { return [ { @@ -95,7 +95,7 @@ export default { } ] }, - // 配置条件 + // 配制条件 storageFormConfig() { return [ { @@ -113,7 +113,7 @@ export default { } ]; }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -132,7 +132,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -201,7 +201,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { @@ -328,7 +328,7 @@ export default { 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)) diff --git a/src/views/business/comps/template/comps/pcr/PCR007.vue b/src/views/business/comps/template/comps/pcr/PCR007.vue index cbc1aba..4d5e567 100644 --- a/src/views/business/comps/template/comps/pcr/PCR007.vue +++ b/src/views/business/comps/template/comps/pcr/PCR007.vue @@ -77,7 +77,7 @@ export default { tableStepColumns() { return getPCR007Config(this); }, - // 附件表单配置 + // 附件表单配制 getFjFormConfig() { return [ { @@ -92,7 +92,7 @@ export default { } ] }, - // 配置条件 + // 配制条件 storageFormConfig() { return [ { @@ -110,7 +110,7 @@ export default { } ]; }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -129,7 +129,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -163,7 +163,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/pcr/PCR008.vue b/src/views/business/comps/template/comps/pcr/PCR008.vue index a19777d..dc19e96 100644 --- a/src/views/business/comps/template/comps/pcr/PCR008.vue +++ b/src/views/business/comps/template/comps/pcr/PCR008.vue @@ -74,7 +74,7 @@ export default { tableStepColumns() { return getPCR008Config(this); }, - // 配置条件 + // 配制条件 storageFormConfig() { return [ { @@ -92,7 +92,7 @@ export default { } ]; }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -111,7 +111,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -168,7 +168,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/pcr/PCR009.vue b/src/views/business/comps/template/comps/pcr/PCR009.vue index 3a15a65..0973d20 100644 --- a/src/views/business/comps/template/comps/pcr/PCR009.vue +++ b/src/views/business/comps/template/comps/pcr/PCR009.vue @@ -76,7 +76,7 @@ export default { tableStepColumns() { return getPCR009Config(this); }, - // 附件表单配置 + // 附件表单配制 getFjFormConfig() { return [ { @@ -91,7 +91,7 @@ export default { } ] }, - // 配置条件 + // 配制条件 storageFormConfig() { return [ { @@ -109,7 +109,7 @@ export default { } ]; }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -128,7 +128,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -185,7 +185,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { @@ -307,7 +307,7 @@ export default { 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)) diff --git a/src/views/business/comps/template/comps/pcr/PCR010.vue b/src/views/business/comps/template/comps/pcr/PCR010.vue index 519da6d..609e792 100644 --- a/src/views/business/comps/template/comps/pcr/PCR010.vue +++ b/src/views/business/comps/template/comps/pcr/PCR010.vue @@ -76,7 +76,7 @@ export default { tableStepColumns() { return getPCR010Config(this); }, - // 配置条件 + // 配制条件 storageFormConfig() { return [ { @@ -94,7 +94,7 @@ export default { } ]; }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -113,7 +113,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -170,7 +170,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { @@ -282,7 +282,7 @@ export default { 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)) diff --git a/src/views/business/comps/template/comps/pcr/PCR011.vue b/src/views/business/comps/template/comps/pcr/PCR011.vue index bf61259..cb0aea3 100644 --- a/src/views/business/comps/template/comps/pcr/PCR011.vue +++ b/src/views/business/comps/template/comps/pcr/PCR011.vue @@ -76,7 +76,7 @@ export default { tableStepColumns() { return getPCR010Config(this); }, - // 配置条件 + // 配制条件 storageFormConfig() { return [ { @@ -94,7 +94,7 @@ export default { } ]; }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -113,7 +113,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -170,7 +170,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { @@ -282,7 +282,7 @@ export default { 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)) diff --git a/src/views/business/comps/template/comps/pcr/PCR012.vue b/src/views/business/comps/template/comps/pcr/PCR012.vue index 72c40e4..d0f31dc 100644 --- a/src/views/business/comps/template/comps/pcr/PCR012.vue +++ b/src/views/business/comps/template/comps/pcr/PCR012.vue @@ -62,7 +62,7 @@ export default { tableStepColumns() { return getPCR010Config(this); }, - // 配置条件 + // 配制条件 storageFormConfig() { return [ { @@ -80,7 +80,7 @@ export default { } ]; }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -99,7 +99,7 @@ export default { } ] }, - // 附件表单配置 + // 附件表单配制 getFjFormConfig() { return [ { @@ -114,7 +114,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -171,7 +171,7 @@ export default { } ] }, - // 数据文件表单配置 + // 数据文件表单配制 dataFormConfig() { return [ @@ -193,7 +193,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { @@ -256,7 +256,7 @@ export default { 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)) diff --git a/src/views/business/comps/template/comps/sp/Demo.vue b/src/views/business/comps/template/comps/sp/Demo.vue index 2a07927..802699c 100644 --- a/src/views/business/comps/template/comps/sp/Demo.vue +++ b/src/views/business/comps/template/comps/sp/Demo.vue @@ -193,7 +193,7 @@ export default { }, { type:"cellItem", - label:"配置时间", + label:"配制时间", config:{ startDate:{ label:"开始时间", diff --git a/src/views/business/comps/template/comps/sp/SP001.vue b/src/views/business/comps/template/comps/sp/SP001.vue index 648673f..4773b2d 100644 --- a/src/views/business/comps/template/comps/sp/SP001.vue +++ b/src/views/business/comps/template/comps/sp/SP001.vue @@ -57,7 +57,7 @@ export default { }, }, computed: { - // 配置条件 + // 配制条件 storageFormConfig() { return [ { @@ -75,7 +75,7 @@ export default { } ]; }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -94,7 +94,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { //毒理002没得方法编号和版本号 let baseConfig = this.sn=='DL002'? @@ -180,7 +180,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { @@ -309,7 +309,7 @@ export default { //生成resource let tmpResource = [] if (this.fillType === "actFill") { - //配置的试剂 + //配制的试剂 tmpResource.push({ mc: content.targetName, bh: content.targetCode + content.targetCodeSn, diff --git a/src/views/business/comps/template/comps/sp/SP0019.vue b/src/views/business/comps/template/comps/sp/SP0019.vue index f126607..8222126 100644 --- a/src/views/business/comps/template/comps/sp/SP0019.vue +++ b/src/views/business/comps/template/comps/sp/SP0019.vue @@ -83,11 +83,11 @@ export default { yqInfoColumns() { return getYqColumns(this); }, - // 配置条件 + // 配制条件 storageFormConfig() { return getStorageFormConfig(this); }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -106,7 +106,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return getBaseInfoFormConfig(this); }, diff --git a/src/views/business/comps/template/comps/sp/SP0020.vue b/src/views/business/comps/template/comps/sp/SP0020.vue index e0f4553..d2fde06 100644 --- a/src/views/business/comps/template/comps/sp/SP0020.vue +++ b/src/views/business/comps/template/comps/sp/SP0020.vue @@ -81,12 +81,12 @@ export default { synrFormConfig(){ return getSynrFormConfig(this); }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return getBaseInfoFormConfig('sp0020'); }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { diff --git a/src/views/business/comps/template/comps/sp/SP0021.vue b/src/views/business/comps/template/comps/sp/SP0021.vue index 5d6cd2c..99545ba 100644 --- a/src/views/business/comps/template/comps/sp/SP0021.vue +++ b/src/views/business/comps/template/comps/sp/SP0021.vue @@ -88,15 +88,15 @@ export default { }, }, computed: { - // 配置条件 + // 配制条件 storageFormConfig() { return getStorageFormConfig(this) }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return getRemarkFormConfig(this) }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return getBaseInfoFormConfig(this) }, @@ -155,7 +155,7 @@ export default { defaultInfo.stepData = ybsmDataList[0]?.stepData || [] } this.formData = { ...this.formData, ...this.getFilledFormData() }; - // 添加新的平行配制配置 + // 添加新的平行配制配制 this.formData.ybsmDataList.push(defaultInfo); }, onLoadExcelData(excelData) { @@ -229,7 +229,7 @@ export default { //生成resource let tmpResource = [] if (this.fillType === "actFill") { - //配置的试剂 + //配制的试剂 tmpResource.push({ mc: content.targetName, bh: content.targetCode + content.targetCodeSn, diff --git a/src/views/business/comps/template/comps/sp/SP003.vue b/src/views/business/comps/template/comps/sp/SP003.vue index c448464..46b7f6e 100644 --- a/src/views/business/comps/template/comps/sp/SP003.vue +++ b/src/views/business/comps/template/comps/sp/SP003.vue @@ -69,7 +69,7 @@ export default { }, computed: { - // 存储条件表单配置 + // 存储条件表单配制 storageFormConfig() { return [ { @@ -88,7 +88,7 @@ export default { } ]; }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -107,7 +107,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -191,7 +191,7 @@ export default { } ] }, - // 操作步骤表单配置 + // 操作步骤表单配制 stepFormConfig() { return [ { @@ -267,7 +267,7 @@ export default { } ] }, - // 步骤表格列配置 + // 步骤表格列配制 stepColumns() { return [ { diff --git a/src/views/business/comps/template/comps/sp/SP00456.vue b/src/views/business/comps/template/comps/sp/SP00456.vue index 4bb97d5..026f090 100644 --- a/src/views/business/comps/template/comps/sp/SP00456.vue +++ b/src/views/business/comps/template/comps/sp/SP00456.vue @@ -176,15 +176,15 @@ export default { jcbColumns() { return getJcbColumnsConfig(this); }, - // 存储条件表单配置 + // 存储条件表单配制 storageFormConfig() { return getStorageConditionFormConfig(this); }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return getRemarkFormConfig(); }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return getBaseInfoFormConfig(this); }, @@ -194,7 +194,7 @@ export default { paralleStepFormConfig1() { return getParalleStepFormConfig(this); }, - // 操作步骤表单配置 + // 操作步骤表单配制 ladderStepFormConfig() { return getLadderFormConfig(this); }, @@ -204,7 +204,7 @@ export default { paralleStepColumns1() { return getParallelColumnsConfig(this); }, - // 阶梯配置表格列配置 + // 阶梯配制表格列配制 ladderStepColumns() { return getLadderColumnsConfig(this); }, @@ -236,7 +236,7 @@ export default { this.handleUpdateCode(formData); }, 0); } - // 如果是PCR234,默认添加一个阶梯配置 并且不支持增删 + // 如果是PCR234,默认添加一个阶梯配制 并且不支持增删 if(this.isPcr234 &&!this.formData.ladderConfigs){ this.handleAddConfig("ladderConfigs"); } @@ -327,14 +327,14 @@ export default { }, //新增平行配制 handleAddConfig(configType) { - // 初始化平行配制配置列表 + // 初始化平行配制配制列表 if (!this.formData[configType]) { - // 新增配置的时候,把最新的formdata重新赋值一份,避免选板数据丢失的bug。 + // 新增配制的时候,把最新的formdata重新赋值一份,避免选板数据丢失的bug。 this.$set(this.formData, configType, []); // this.formData[configType] = []; } this.formData = { ...this.formData, ...this.getFilledFormData() }; - // 添加新的平行配制配置 + // 添加新的平行配制配制 this.formData[configType].push({ id: getuuid(), stepData: [], @@ -342,7 +342,7 @@ export default { }); justUpdateFilledFormData(); }, - // 删除阶梯配制配置 + // 删除阶梯配制配制 deleteConfig(type, con) { const configIndex = this.formData[type].findIndex(config => config.id === con.id); if (configIndex !== -1) { diff --git a/src/views/business/comps/template/comps/sp/SP007.vue b/src/views/business/comps/template/comps/sp/SP007.vue index 9270d4e..f71cfe9 100644 --- a/src/views/business/comps/template/comps/sp/SP007.vue +++ b/src/views/business/comps/template/comps/sp/SP007.vue @@ -54,11 +54,11 @@ export default { }, }, computed: { - // 配置条件 + // 配制条件 storageFormConfig() { return getStorageFormConfig(this); }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return getRemarkFormConfig(); }, @@ -66,11 +66,11 @@ export default { ybFormConfig() { return getYbFormConfig(); }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return getBaseInfoFormConfig(this); }, - // 附件表单配置 + // 附件表单配制 getFjFormConfig() { return getfjFormConfig(this); }, diff --git a/src/views/business/comps/template/comps/sp/SP008.vue b/src/views/business/comps/template/comps/sp/SP008.vue index 647d779..122ffeb 100644 --- a/src/views/business/comps/template/comps/sp/SP008.vue +++ b/src/views/business/comps/template/comps/sp/SP008.vue @@ -321,7 +321,7 @@ export default { let tableList = content.stepTableFormData if(tableList && tableList.length>0){ for(let i=0;i0){ for(let i=0;i0){ for(let i=0;i {{ $t(fieldItemLabel) }} - + {{ $t('template.common.deleteBtn') }} @@ -268,11 +268,11 @@ export default { } }, bodySelectChange(data) { - if(this.configType === "paralle"){//只有平行配置才需要更新体积 + if(this.configType === "paralle"){//只有平行配制才需要更新体积 this.paralleUpdateTargetStartSolutionVolume(data.item, data.headerSelectFields, data.dataSource); } }, - //平行配置更新体积 + //平行配制更新体积 paralleUpdateTargetStartSolutionVolume(item, headerSelectFields, dataSource) { const volumne = item.targetStartSolutionConcentration; const subTargetStartSolution = item.targetStartSolutionConcentrationPrecision; @@ -329,7 +329,7 @@ export default { "存储条件": stepStorageCondition || paralleStepStorageCondition, "配制日期": moment(startDate).format("YYYY-MM-DD"), "有效期至": moment(targetSolutionExpirationDate || expireDate).format("YYYY-MM-DD HH:mm"), - "配置者": lang === "zh_CN" ? nickName : name, + "配制者": lang === "zh_CN" ? nickName : name, //type==="subPackage"从分装打印过来的, //type==="row" 从列表上点过来的 "编号": type === "subPackage" ? printCode : (row.targetSolutionCode + row.subTargetSolutionCode), @@ -337,7 +337,7 @@ export default { console.log(printConfig, "printConfig") EventBus.$emit('showTagPrintDialog', { printConfig }) }, - //开始配置 + //开始配制 startConfig(val) { const { rowData } = val; let postData = { @@ -348,7 +348,7 @@ export default { } this.startConfigRequest(postData); }, - //配置完成 + //配制完成 configComplete(val) { const { rowData, headerSelectFields } = val; //计算实际目标溶液体积(实际起始溶液体积+实际稀释液体积) @@ -402,7 +402,7 @@ export default { callback.prevent('浓度单位与预制不符,请重新选择或申请废止并重新预制。'); } }, - //平行配置 table选择试剂确定弹窗 + //平行配制 table选择试剂确定弹窗 onTableRegentSubmit(data) { const { selectInfo, rowIndex, key, rowData } = data; const { row, selectedId } = selectInfo; diff --git a/src/views/business/comps/template/comps/xb/XB001.vue b/src/views/business/comps/template/comps/xb/XB001.vue index e609180..6c08c36 100644 --- a/src/views/business/comps/template/comps/xb/XB001.vue +++ b/src/views/business/comps/template/comps/xb/XB001.vue @@ -144,7 +144,7 @@ export default { } ] }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -163,7 +163,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { @@ -197,7 +197,7 @@ export default { } ] }, - // 附件表单配置 + // 附件表单配制 getFjFormConfig() { return [ { @@ -212,7 +212,7 @@ export default { } ] }, - // 操作步骤第一步表格配置 + // 操作步骤第一步表格配制 tableFirstColumns() { return [{ label: 'template.xb.xb001.fpc', @@ -241,7 +241,7 @@ export default { otherCode: "preOther2", }] }, - // 操作步骤第五步表格配置 + // 操作步骤第五步表格配制 tableSecondColumns() { return [ { diff --git a/src/views/business/comps/template/comps/yp/YP002.vue b/src/views/business/comps/template/comps/yp/YP002.vue index 7a6a875..a2933cc 100644 --- a/src/views/business/comps/template/comps/yp/YP002.vue +++ b/src/views/business/comps/template/comps/yp/YP002.vue @@ -44,7 +44,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -63,7 +63,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/yp/YP003.vue b/src/views/business/comps/template/comps/yp/YP003.vue index 3bc7b79..26c7117 100644 --- a/src/views/business/comps/template/comps/yp/YP003.vue +++ b/src/views/business/comps/template/comps/yp/YP003.vue @@ -77,7 +77,7 @@ export default { } ] }, - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -96,7 +96,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/yp/YP004.vue b/src/views/business/comps/template/comps/yp/YP004.vue index 49e14b7..df40d42 100644 --- a/src/views/business/comps/template/comps/yp/YP004.vue +++ b/src/views/business/comps/template/comps/yp/YP004.vue @@ -61,7 +61,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -80,7 +80,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/comps/yp/YP005.vue b/src/views/business/comps/template/comps/yp/YP005.vue index 486d7a9..1767946 100644 --- a/src/views/business/comps/template/comps/yp/YP005.vue +++ b/src/views/business/comps/template/comps/yp/YP005.vue @@ -66,7 +66,7 @@ export default { }, }, computed: { - // 备注表单配置 + // 备注表单配制 remarkConig() { return [ { @@ -85,7 +85,7 @@ export default { } ] }, - // 试验基本信息表单配置 + // 试验基本信息表单配制 baseInfoFormConfig() { return [ { diff --git a/src/views/business/comps/template/formConfig/PCRTableConfig.js b/src/views/business/comps/template/formConfig/PCRTableConfig.js index a47bc98..a660c7e 100644 --- a/src/views/business/comps/template/formConfig/PCRTableConfig.js +++ b/src/views/business/comps/template/formConfig/PCRTableConfig.js @@ -1,4 +1,4 @@ -// 阶梯配置表格列配置 +// 阶梯配制表格列配制 export const getLadderColumnsConfig = ($this, selectKey) => { return [ { @@ -153,7 +153,7 @@ export const getLadderColumnsConfig = ($this, selectKey) => { } ] } -// 平行配置表格列配置 +// 平行配制表格列配制 export const getParallelColumnsConfig = ($this) => { const sn = $this.sn let o = { @@ -362,7 +362,7 @@ export const getParallelColumnsConfig = ($this) => { ] } -//阶梯配置 +//阶梯配制 export const getLadderFormConfig = ($this) => { return [ { @@ -553,7 +553,7 @@ export const getStorageConditionFormConfig = ($this) => { ] } -//并行步骤配置 +//并行步骤配制 export const getParalleStepFormConfig = ($this) => { return [ { diff --git a/src/views/business/comps/template/formConfig/SWYPFXFFXYPZBBTableConfig.js b/src/views/business/comps/template/formConfig/SWYPFXFFXYPZBBTableConfig.js index 27072cd..84cb8a2 100644 --- a/src/views/business/comps/template/formConfig/SWYPFXFFXYPZBBTableConfig.js +++ b/src/views/business/comps/template/formConfig/SWYPFXFFXYPZBBTableConfig.js @@ -1,4 +1,4 @@ -// 生物样品分析方法学样品制备表-表格配置 +// 生物样品分析方法学样品制备表-表格配制 // selectKey:编号选择的数据源key // isXsy是否时稀释液:稀释液的名称不一样 // showKbjz 是否显示空白机制的列:生物样品分析方法学样品制备表(Matrix effect)-生物样品分析方法学样品制备表(基质效应) diff --git a/src/views/business/comps/template/formConfig/paralleAndLadderConfig.js b/src/views/business/comps/template/formConfig/paralleAndLadderConfig.js index 37bc319..9cf7c8c 100644 --- a/src/views/business/comps/template/formConfig/paralleAndLadderConfig.js +++ b/src/views/business/comps/template/formConfig/paralleAndLadderConfig.js @@ -37,24 +37,24 @@ const explainConfig = { //编号对应的数据字典code const optionsCode = { - SP004: 'business_sp_nbgzy', - SP005: 'business_sp_zkgzy', - SP006: 'business_sp_bzqxzkypzbb', - PCR002: 'business_pcr_gzy', - PCR003: 'business_pcr_fxbzqxzbb', - PCR004: 'business_pcr_fxzkypzbb', - GSP007:"",//GSP007是输入框 - PCR013:"business_pcr_fxffypzbb", - LBA005:"business_lba_ptjhbzqx_zkpx", - LBA007:"business_lba_ptjhfxyp", - ADA005:"business_ada_kyktzkyp", - ADA007:"business_ada_kyktffxyp", - } + SP004: 'business_sp_nbgzy', + SP005: 'business_sp_zkgzy', + SP006: 'business_sp_bzqxzkypzbb', + PCR002: 'business_pcr_gzy', + PCR003: 'business_pcr_fxbzqxzbb', + PCR004: 'business_pcr_fxzkypzbb', + GSP007: '', //GSP007是输入框 + PCR013: 'business_pcr_fxffypzbb', + LBA005: 'business_lba_ptjhbzqx_zkpx', + LBA007: 'business_lba_ptjhfxyp', + ADA005: 'business_ada_kyktzkyp', + ADA007: 'business_ada_kyktffxyp' +} -// 阶梯配置表格列配置 +// 阶梯配制表格列配制 export const getLadderColumnsConfig = ($this) => { - const dic = optionsCode[$this.sn] || 'business_sp_nbgzy'; - const mbryType = $this.sn === "GSP007"?"input":"select" + const dic = optionsCode[$this.sn] || 'business_sp_nbgzy' + const mbryType = $this.sn === 'GSP007' ? 'input' : 'select' return [ { label: 'template.sp.sp00456.mbrybh', @@ -223,11 +223,11 @@ export const getLadderColumnsConfig = ($this) => { } ] } -// 平行配置表格列配置 -export const getParallelColumnsConfig = ($this,sn) => { - let dic = optionsCode[$this.sn] || 'business_sp_nbgzy'; - if(sn === "LBA005"){ - dic = "business_lba_bqpx"; +// 平行配制表格列配制 +export const getParallelColumnsConfig = ($this, sn) => { + let dic = optionsCode[$this.sn] || 'business_sp_nbgzy' + if (sn === 'LBA005') { + dic = 'business_lba_bqpx' } return [ { @@ -457,7 +457,7 @@ export const getParallelColumnsConfig = ($this,sn) => { ] } -//阶梯配置 +//阶梯配制 export const getLadderFormConfig = ($this) => { const sn = $this.sn const defaultConfig = [ @@ -536,51 +536,50 @@ export const getLadderFormConfig = ($this) => { //试验基本信息 export const getBaseInfoFormConfig = ($this) => { const sn = $this.sn - const labArr = ['LBA005', 'LBA007','ADA005','ADA007'] + const labArr = ['LBA005', 'LBA007', 'ADA005', 'ADA007'] const isLba = labArr.includes(sn) - const isSp = sn.startsWith('SP')//是否是色谱 + const isSp = sn.startsWith('SP') //是否是色谱 return [ { type: 'cardItem', - config: isSp? - { - studyMc: { - label: 'template.common.testName', - type: 'input', - disabled: true - }, - studySn: { - label: 'template.common.testNumber', - type: 'input', - disabled: true - }, - methodCode: { - label: 'template.common.methodCode', - type: 'input', - fillType: 'preFill', - maxlength: 50 - }, - versionNum: { - label: 'template.common.versionNumber', - type: 'inputNumber', - fillType: 'preFill', - prepend: 'V', - maxlength: 50 - } - } - : - { - studyMc: { - label: 'template.common.testName', - type: 'input', - disabled: true - }, - studySn: { - label: 'template.common.testNumber', - type: 'input', - disabled: true - }, - } + config: isSp + ? { + studyMc: { + label: 'template.common.testName', + type: 'input', + disabled: true + }, + studySn: { + label: 'template.common.testNumber', + type: 'input', + disabled: true + }, + methodCode: { + label: 'template.common.methodCode', + type: 'input', + fillType: 'preFill', + maxlength: 50 + }, + versionNum: { + label: 'template.common.versionNumber', + type: 'inputNumber', + fillType: 'preFill', + prepend: 'V', + maxlength: 50 + } + } + : { + studyMc: { + label: 'template.common.testName', + type: 'input', + disabled: true + }, + studySn: { + label: 'template.common.testNumber', + type: 'input', + disabled: true + } + } }, { type: 'conditionItem', @@ -608,7 +607,7 @@ export const getBaseInfoFormConfig = ($this) => { } }, isSp - ?{ + ? { type: 'conditionItem', label: 'template.sp.sp00456.rqcz', config: { @@ -622,7 +621,7 @@ export const getBaseInfoFormConfig = ($this) => { } } } - :{} , + : {}, { type: 'cellItem', label: isLba @@ -681,7 +680,7 @@ export const getStorageConditionFormConfig = ($this) => { ] } -//平行步骤配置 +//平行步骤配制 export const getParalleStepFormConfig = ($this) => { const defaultConfig = [ { diff --git a/src/views/business/comps/template/formConfig/sp/SP0019.js b/src/views/business/comps/template/formConfig/sp/SP0019.js index be40b7f..ac2a221 100644 --- a/src/views/business/comps/template/formConfig/sp/SP0019.js +++ b/src/views/business/comps/template/formConfig/sp/SP0019.js @@ -1,156 +1,155 @@ export const getBaseInfoFormConfig = (formType) => { - return [ - { - type: 'cardItem', - config: { - studyMc: { - label: 'template.common.testName', - type: 'input', - disabled: true - }, - studySn: { - label: 'template.common.testNumber', - type: 'input', - disabled: true - }, - methodCode: { - label: 'template.common.methodCode', - type: 'input', - fillType: formType === 'sp0020' ? 'actFill' : 'preFill', - maxlength: 50 - }, - versionNum: { - label: 'template.common.versionNumber', - type: 'inputNumber', - fillType: formType === 'sp0020' ? 'actFill' : 'preFill', - prepend: 'V', - maxlength: 50 - }, - clpbh: { - label: '处理批编号', - type: 'input', - fillType: 'actFill', - maxlength: 50 - }, - fxpbh: { - label: '分析批编号', - type: 'input', - fillType: 'actFill', - maxlength: 50 - }, - } + return [ + { + type: 'cardItem', + config: { + studyMc: { + label: 'template.common.testName', + type: 'input', + disabled: true }, - ] + studySn: { + label: 'template.common.testNumber', + type: 'input', + disabled: true + }, + methodCode: { + label: 'template.common.methodCode', + type: 'input', + fillType: formType === 'sp0020' ? 'actFill' : 'preFill', + maxlength: 50 + }, + versionNum: { + label: 'template.common.versionNumber', + type: 'inputNumber', + fillType: formType === 'sp0020' ? 'actFill' : 'preFill', + prepend: 'V', + maxlength: 50 + }, + clpbh: { + label: '处理批编号', + type: 'input', + fillType: 'actFill', + maxlength: 50 + }, + fxpbh: { + label: '分析批编号', + type: 'input', + fillType: 'actFill', + maxlength: 50 + } + } + } + ] } -export const getStorageFormConfig = ($this)=>{ - return[ - { - type: 'step', - config: { - spzxh: { - label: '色谱柱型号', - type: 'select', - fillType: 'actFill', - options: $this.spzxhOptions, - filledCodes:['mc','bh'], - selectRemote: true, - - }, - } - }, - ] +export const getStorageFormConfig = ($this) => { + return [ + { + type: 'step', + config: { + spzxh: { + label: '色谱柱型号', + type: 'select', + fillType: 'actFill', + options: $this.spzxhOptions, + filledCodes: ['mc', 'bh'], + selectRemote: true + } + } + } + ] } //仪器信息 export const getYqColumns = ($this) => { - return [ - { - label: 'template.common.instrumentCode', - prop: "bh", - bodyType: "yq", - bodyFillType: 'actFill', - },//仪器编号 - { - label: 'template.common.instrumentName', - prop: "mc", - bodyType: "input", - bodyType: "input", - bodyDisabled: true, - bodyFillType: 'actFill', - },//仪器名称 - { - label: 'template.common.instrumentModel', - prop: "xh", - bodyType: "input", - bodyDisabled: true, - bodyFillType: 'actFill', - },//仪器型号 - - { - label: 'template.common.nextTestDate', - prop: "jzrq", - bodyType: "input", - bodyDisabled: true, - bodyFillType: 'actFill', - },//下次测试/校准/检定日期 - ] + return [ + { + label: 'template.common.instrumentCode', + prop: 'bh', + bodyType: 'yq', + bodyFillType: 'actFill' + }, //仪器编号 + { + label: 'template.common.instrumentName', + prop: 'mc', + bodyType: 'input', + bodyType: 'input', + bodyDisabled: true, + bodyFillType: 'actFill' + }, //仪器名称 + { + label: 'template.common.instrumentModel', + prop: 'xh', + bodyType: 'input', + bodyDisabled: true, + bodyFillType: 'actFill' + }, //仪器型号 + + { + label: 'template.common.nextTestDate', + prop: 'jzrq', + bodyType: 'input', + bodyDisabled: true, + bodyFillType: 'actFill' + } //下次测试/校准/检定日期 + ] } //溶液 export const getRyColumns = ($this) => { - return [ - { - label: '溶液类型', - prop: "rylx", - bodyType: "select", - otherCode:'rylxOther', - width:380, - bodyOptions: $this.getDictOptions('business_rylx'), - bodyFillType: 'preFill', - }, - { - label: '溶液名称(编号)', - prop: "rymc", - bodyType: "sj", - bodyFillType: 'actFill', - filledCodes:['mc','bh'], - }, - { - label: '配置日期', - prop: "pzrq", - bodyType: "input", - bodyDisabled: true, - bodyFillType: 'actFill', - }, - { - label: '失效日', - prop: "sxr", - bodyType: "input", - bodyDisabled: true, - bodyFillType: 'actFill', - }, - ] + return [ + { + label: '溶液类型', + prop: 'rylx', + bodyType: 'select', + otherCode: 'rylxOther', + width: 380, + bodyOptions: $this.getDictOptions('business_rylx'), + bodyFillType: 'preFill' + }, + { + label: '溶液名称(编号)', + prop: 'rymc', + bodyType: 'sj', + bodyFillType: 'actFill', + filledCodes: ['mc', 'bh'] + }, + { + label: '配制日期', + prop: 'pzrq', + bodyType: 'input', + bodyDisabled: true, + bodyFillType: 'actFill' + }, + { + label: '失效日', + prop: 'sxr', + bodyType: 'input', + bodyDisabled: true, + bodyFillType: 'actFill' + } + ] } //仪器平衡 export const getYqphFormConfig = () => { - return [ - { - type: 'checkboxList', - config: { - yqph: { - label: '仪器平衡', - type: 'checkboxTree', - fillType: 'actFill', - span:1, - options: [ - { label: '流动相平衡', value: '流动相平衡' }, - { label: '样品平衡', value: '样品平衡' }, - { label: '样品', value: '样品'}, - { label: '未平衡', value: '未平衡' } - ] - }, - } + return [ + { + type: 'checkboxList', + config: { + yqph: { + label: '仪器平衡', + type: 'checkboxTree', + fillType: 'actFill', + span: 1, + options: [ + { label: '流动相平衡', value: '流动相平衡' }, + { label: '样品平衡', value: '样品平衡' }, + { label: '样品', value: '样品' }, + { label: '未平衡', value: '未平衡' } + ] } - ] -} \ No newline at end of file + } + } + ] +} diff --git a/src/views/business/comps/template/formConfig/sp/SP0020.js b/src/views/business/comps/template/formConfig/sp/SP0020.js index 4bd1480..610149f 100644 --- a/src/views/business/comps/template/formConfig/sp/SP0020.js +++ b/src/views/business/comps/template/formConfig/sp/SP0020.js @@ -1,161 +1,155 @@ -// checkboxTree 类型的配置 +// checkboxTree 类型的配制 const getOptions = (sn) => { - let children = [ - { label: '储备液比对', value: '储备液比对' }, - { label: '标准曲线线性范围', value: '标准曲线线性范围' }, - { label: '准确度与精密度&灵敏度', value: '准确度与精密度&灵敏度' }, - { label: '残留', value: '残留' }, - { label: '选择性与特异性', value: '选择性与特异性' }, - { label: '基质效应', value: '基质效应' }, - { label: '提取回收率', value: '提取回收率' }, - { label: '溶血基质效应', value: '溶血基质效应' }, - { label: '批最大样本数', value: '批最大样本数' }, - { label: '基质样品', value: '基质样品' }, - { label: '基质样品长期冻存稳定性', value: '基质样品长期冻存稳定性' }, - { label: '反复冻融稳定性', value: '反复冻融稳定性' }, - { label: '稀释可靠性', value: '稀释可靠性' }, - { label: '处理后样品稳定性', value: '处理后样品稳定性' }, - { label: '进样重现性', value: '进样重现性' }, - { label: '全血稳定性', value: '全血稳定性' }, - { label: '储备液短期稳定性', value: '储备液短期稳定性' }, - { label: '储备液长期稳定性', value: '储备液长期稳定性' }, - { label: '工作液短期稳定性', value: '工作液短期稳定性' }, - { label: '工作液长期稳定性', value: '工作液长期稳定性' } - ]; - if (sn === 'PCR006') { - children = [ - { label: '基质效应', value: '基质效应' }, - { label: '选择性', value: '选择性' }, - { label: '特异性', value: '特异性' }, - { label: '方法耐用性', value: '方法耐用性' }, - { label: '精密度与准确性', value: '精密度与准确性' }, - { label: '检测限', value: '检测限' }, - { label: '提取精密度', value: '提取精密度' }, - { label: '提取前样品稳定性', value: '提取前样品稳定性' }, - { label: '提取后样品稳定性', value: '提取后样品稳定性' }, - { label: 'cDNA样品稳定性', value: 'cDNA样品稳定性' }, - { label: '方法适用性', value: '方法适用性' }, - { label: '基因组DNA残留测定', value: '基因组DNA残留测定' }, - { label: '稀释线性', value: '稀释线性' }, - { label: '反复动态稳定性', value: '反复动态稳定性' }, - { label: '标准工作液稳定性', value: '标准工作液稳定性' } - ] - } - - return [ - { - label: '方法学验证', - value: '方法学验证', - children - }, - { - label: '样品分析', - value: '样品分析', - children: [ - { label: '样品信息', value: '样品信息' } - ] - }, - { - label: '其他', - value: '其他', - children: [] - } + let children = [ + { label: '储备液比对', value: '储备液比对' }, + { label: '标准曲线线性范围', value: '标准曲线线性范围' }, + { label: '准确度与精密度&灵敏度', value: '准确度与精密度&灵敏度' }, + { label: '残留', value: '残留' }, + { label: '选择性与特异性', value: '选择性与特异性' }, + { label: '基质效应', value: '基质效应' }, + { label: '提取回收率', value: '提取回收率' }, + { label: '溶血基质效应', value: '溶血基质效应' }, + { label: '批最大样本数', value: '批最大样本数' }, + { label: '基质样品', value: '基质样品' }, + { label: '基质样品长期冻存稳定性', value: '基质样品长期冻存稳定性' }, + { label: '反复冻融稳定性', value: '反复冻融稳定性' }, + { label: '稀释可靠性', value: '稀释可靠性' }, + { label: '处理后样品稳定性', value: '处理后样品稳定性' }, + { label: '进样重现性', value: '进样重现性' }, + { label: '全血稳定性', value: '全血稳定性' }, + { label: '储备液短期稳定性', value: '储备液短期稳定性' }, + { label: '储备液长期稳定性', value: '储备液长期稳定性' }, + { label: '工作液短期稳定性', value: '工作液短期稳定性' }, + { label: '工作液长期稳定性', value: '工作液长期稳定性' } + ] + if (sn === 'PCR006') { + children = [ + { label: '基质效应', value: '基质效应' }, + { label: '选择性', value: '选择性' }, + { label: '特异性', value: '特异性' }, + { label: '方法耐用性', value: '方法耐用性' }, + { label: '精密度与准确性', value: '精密度与准确性' }, + { label: '检测限', value: '检测限' }, + { label: '提取精密度', value: '提取精密度' }, + { label: '提取前样品稳定性', value: '提取前样品稳定性' }, + { label: '提取后样品稳定性', value: '提取后样品稳定性' }, + { label: 'cDNA样品稳定性', value: 'cDNA样品稳定性' }, + { label: '方法适用性', value: '方法适用性' }, + { label: '基因组DNA残留测定', value: '基因组DNA残留测定' }, + { label: '稀释线性', value: '稀释线性' }, + { label: '反复动态稳定性', value: '反复动态稳定性' }, + { label: '标准工作液稳定性', value: '标准工作液稳定性' } ] -} - - - + } + return [ + { + label: '方法学验证', + value: '方法学验证', + children + }, + { + label: '样品分析', + value: '样品分析', + children: [{ label: '样品信息', value: '样品信息' }] + }, + { + label: '其他', + value: '其他', + children: [] + } + ] +} //试验内容 export const getSynrFormConfig = ($this) => { - return [ - { - type: 'checkboxList', - config: { - ffxyz: { - type: 'checkboxTree', - label: '方法学验证', - options: getOptions($this.sn), - span: 1, - fillType: "actFill" - }, - } - }, - ] + return [ + { + type: 'checkboxList', + config: { + ffxyz: { + type: 'checkboxTree', + label: '方法学验证', + options: getOptions($this.sn), + span: 1, + fillType: 'actFill' + } + } + } + ] } //仪器结果 export const getYqjgFormConfig = () => { - return [ - { - type: 'checkboxList', - config: { - jg: { - type: 'checkboxTree', - label: '结果', - options: [ - { label: '分析批接受', value: '分析批接受' }, - { label: '分析批拒绝', value: '分析批拒绝' }, - { label: '部分接受', value: '部分接受' }, - ], - span: 1, - fillType: "actFill" - }, - yzkcjg: { - type: 'textarea', - label: '验证考察结果', - span: 1, - fillType: "actFill", - maxlength: 1000, - rows: 5 - }, - } + return [ + { + type: 'checkboxList', + config: { + jg: { + type: 'checkboxTree', + label: '结果', + options: [ + { label: '分析批接受', value: '分析批接受' }, + { label: '分析批拒绝', value: '分析批拒绝' }, + { label: '部分接受', value: '部分接受' } + ], + span: 1, + fillType: 'actFill' }, - ] + yzkcjg: { + type: 'textarea', + label: '验证考察结果', + span: 1, + fillType: 'actFill', + maxlength: 1000, + rows: 5 + } + } + } + ] } //分析批数据文件 export const getFxpsjwjFormConfig = () => { - return [ - { - type: 'checkboxList', - config: { - fxpsjwjm: { - type: 'input', - label: '分析批数据文件名', - span: 1, - fillType: "actFill", - maxlength: 100, - }, - fxpsjlj: { - type: 'input', - label: '分析批数据路径', - span: 1, - fillType: "actFill", - maxlength: 150, - }, - } + return [ + { + type: 'checkboxList', + config: { + fxpsjwjm: { + type: 'input', + label: '分析批数据文件名', + span: 1, + fillType: 'actFill', + maxlength: 100 }, - ] + fxpsjlj: { + type: 'input', + label: '分析批数据路径', + span: 1, + fillType: 'actFill', + maxlength: 150 + } + } + } + ] } //采集日期 export const getCjrqFormConfig = () => { - return [ - { - type: 'cellItem', - config: { - cjksrq: { - type: 'datePicker', - label: '采集开始日期', - fillType: "actFill" - }, - cjjsrq: { - type: 'datePicker', - label: '采集结束日期', - fillType: "actFill" - }, - } + return [ + { + type: 'cellItem', + config: { + cjksrq: { + type: 'datePicker', + label: '采集开始日期', + fillType: 'actFill' }, - ] -} \ No newline at end of file + cjjsrq: { + type: 'datePicker', + label: '采集结束日期', + fillType: 'actFill' + } + } + } + ] +} diff --git a/src/views/business/comps/template/formConfig/xb/xb001.js b/src/views/business/comps/template/formConfig/xb/xb001.js index 764ec19..f10f685 100644 --- a/src/views/business/comps/template/formConfig/xb/xb001.js +++ b/src/views/business/comps/template/formConfig/xb/xb001.js @@ -1,361 +1,371 @@ -//操作第二步配置 +//操作第二步配制 export const getStepSecond = ($this) => { - return [{ - config:{ - text1:{ - label:"待测样品于", - type:"text", - }, - dcyb:{ - type:"input", - fillType:"preFill", - }, - text2:{ - label:"解冻完成后,分别使用移液器", - type:"text", - }, - yyqfirst:{ - type:"yq", - fillType:"actFill", - }, - text3:{ - label:"取待测血清预计", - type:"text", - }, - dcxqyj:{ - type:"inputNumber", - fillType:"preFill", - }, - dcxqyjdw:{ - type:"select", - options:$this.getDictOptions("business_tjdw"), - fillType:"preFill", - }, - text4:{ - label:"实际", - type:"text", - }, - dcxqsj:{ - type:"inputNumber", - fillType:"actFill", - compareTo:"dcxqyj", - copyFrom:"dcxqyj" - }, - dcxqsjdw:{ - type:"select", - options:$this.getDictOptions("business_tjdw"), - fillType:"actFill", - compareTo:"dcxqyjdw", - copyFrom:"dcxqyjdw" - }, - text5:{ - label:"加入稀释深孔板,再分别使用移液器", - type:"text", - }, - yyqsecond:{ - type:"yq", - fillType:"actFill", - }, - text6:{ - label:"取BBS", - type:"text", - }, - bbs:{ - type:"sj", - fillType:"actFill", - }, - text7:{ - label:"预计", - type:"text", - }, - bbsyj:{ - type:"inputNumber", - fillType:"preFill", - }, - bbsyjdw:{ - type:"select", - options:$this.getDictOptions("business_tjdw"), - fillType:"preFill", - }, - text8:{ - label:"实际", - type:"text", - }, - bbssj:{ - type:"inputNumber", - fillType:"actFill", - compareTo:"bbsyj", - copyFrom:"bbsyj" - }, - bbssjdw:{ - type:"select", - options:$this.getDictOptions("business_tjdw"), - fillType:"actFill", - compareTo:"bbsyjdw", - copyFrom:"bbsyjdw" - }, - text9:{ - label:"加入稀释深孔板,放在摇床上", - type:"text", - }, - yc:{ - type:"yq", - fillType:"actFill", - }, - text10:{ - label:"充分摇匀。", - type:"text", - }, + return [ + { + config: { + text1: { + label: '待测样品于', + type: 'text' + }, + dcyb: { + type: 'input', + fillType: 'preFill' + }, + text2: { + label: '解冻完成后,分别使用移液器', + type: 'text' + }, + yyqfirst: { + type: 'yq', + fillType: 'actFill' + }, + text3: { + label: '取待测血清预计', + type: 'text' + }, + dcxqyj: { + type: 'inputNumber', + fillType: 'preFill' + }, + dcxqyjdw: { + type: 'select', + options: $this.getDictOptions('business_tjdw'), + fillType: 'preFill' + }, + text4: { + label: '实际', + type: 'text' + }, + dcxqsj: { + type: 'inputNumber', + fillType: 'actFill', + compareTo: 'dcxqyj', + copyFrom: 'dcxqyj' + }, + dcxqsjdw: { + type: 'select', + options: $this.getDictOptions('business_tjdw'), + fillType: 'actFill', + compareTo: 'dcxqyjdw', + copyFrom: 'dcxqyjdw' + }, + text5: { + label: '加入稀释深孔板,再分别使用移液器', + type: 'text' + }, + yyqsecond: { + type: 'yq', + fillType: 'actFill' + }, + text6: { + label: '取BBS', + type: 'text' + }, + bbs: { + type: 'sj', + fillType: 'actFill' + }, + text7: { + label: '预计', + type: 'text' + }, + bbsyj: { + type: 'inputNumber', + fillType: 'preFill' + }, + bbsyjdw: { + type: 'select', + options: $this.getDictOptions('business_tjdw'), + fillType: 'preFill' + }, + text8: { + label: '实际', + type: 'text' + }, + bbssj: { + type: 'inputNumber', + fillType: 'actFill', + compareTo: 'bbsyj', + copyFrom: 'bbsyj' + }, + bbssjdw: { + type: 'select', + options: $this.getDictOptions('business_tjdw'), + fillType: 'actFill', + compareTo: 'bbsyjdw', + copyFrom: 'bbsyjdw' + }, + text9: { + label: '加入稀释深孔板,放在摇床上', + type: 'text' + }, + yc: { + type: 'yq', + fillType: 'actFill' + }, + text10: { + label: '充分摇匀。', + type: 'text' } - }] + } + } + ] } -//操作第三步配置 +//操作第三步配制 export const getStepThird = ($this) => { - return [{ - config:{ - text1:{ - label:"分别使用移液器", - type:"text", - }, - yyqfirst:{ - type:"yq", - fillType:"actFill", - }, - text2:{ - label:"取BBS", - type:"text", - }, - bbs:{ - type:"sj", - fillType:"actFill", - }, - text3:{ - label:"预计", - type:"text", - }, - bbsyj:{ - type:"inputNumber", - fillType:"preFill", - }, - bbsyjdw:{ - type:"select", - options:$this.getDictOptions("business_tjdw"), - fillType:"preFill", - }, - text4:{ - label:"实际", - type:"text", - }, - bbssj:{ - type:"inputNumber", - fillType:"actFill", - compareTo:"bbsyj", - copyFrom:"bbsyj" - }, - bbssjdw:{ - type:"select", - options:$this.getDictOptions("business_tjdw"), - fillType:"actFill", - compareTo:"bbsyjdw", - copyFrom:"bbsyjdw" - }, - text5:{ - label:"加入对照管中,再分别使用移液器", - type:"text", - }, - yyqsecond:{ - type:"yq", - fillType:"actFill", - }, - text6:{ - label:"取PEG-NaF", - type:"text", - }, - pegnaf:{ - type:"sj", - fillType:"actFill", - }, - text7:{ - label:"预计", - type:"text", - }, - pegnafyj:{ - type:"inputNumber", - fillType:"preFill", - }, - pegnafyjdw:{ - type:"select", - options:$this.getDictOptions("business_tjdw"), - fillType:"preFill", - }, - text8:{ - label:"实际", - type:"text", - }, - pegnafsj:{ - type:"inputNumber", - fillType:"actFill", - compareTo:"pegnafyj", - copyFrom:"pegnafyj" - }, - pegnafsjdw:{ - type:"select", - options:$this.getDictOptions("business_tjdw"), - fillType:"actFill", - compareTo:"pegnafyjdw", - copyFrom:"pegnafyjdw" - }, - text9:{ - label:"加入测试管中。", - type:"text", - }, + return [ + { + config: { + text1: { + label: '分别使用移液器', + type: 'text' + }, + yyqfirst: { + type: 'yq', + fillType: 'actFill' + }, + text2: { + label: '取BBS', + type: 'text' + }, + bbs: { + type: 'sj', + fillType: 'actFill' + }, + text3: { + label: '预计', + type: 'text' + }, + bbsyj: { + type: 'inputNumber', + fillType: 'preFill' + }, + bbsyjdw: { + type: 'select', + options: $this.getDictOptions('business_tjdw'), + fillType: 'preFill' + }, + text4: { + label: '实际', + type: 'text' + }, + bbssj: { + type: 'inputNumber', + fillType: 'actFill', + compareTo: 'bbsyj', + copyFrom: 'bbsyj' + }, + bbssjdw: { + type: 'select', + options: $this.getDictOptions('business_tjdw'), + fillType: 'actFill', + compareTo: 'bbsyjdw', + copyFrom: 'bbsyjdw' + }, + text5: { + label: '加入对照管中,再分别使用移液器', + type: 'text' + }, + yyqsecond: { + type: 'yq', + fillType: 'actFill' + }, + text6: { + label: '取PEG-NaF', + type: 'text' + }, + pegnaf: { + type: 'sj', + fillType: 'actFill' + }, + text7: { + label: '预计', + type: 'text' + }, + pegnafyj: { + type: 'inputNumber', + fillType: 'preFill' + }, + pegnafyjdw: { + type: 'select', + options: $this.getDictOptions('business_tjdw'), + fillType: 'preFill' + }, + text8: { + label: '实际', + type: 'text' + }, + pegnafsj: { + type: 'inputNumber', + fillType: 'actFill', + compareTo: 'pegnafyj', + copyFrom: 'pegnafyj' + }, + pegnafsjdw: { + type: 'select', + options: $this.getDictOptions('business_tjdw'), + fillType: 'actFill', + compareTo: 'pegnafyjdw', + copyFrom: 'pegnafyjdw' + }, + text9: { + label: '加入测试管中。', + type: 'text' } - }] + } + } + ] } -//操作第四步配置 +//操作第四步配制 export const getStepFourth = ($this) => { - return [{ - config:{ - text1:{ - label:"使用移液器", - type:"text", - }, - yyq:{ - type:"yq", - fillType:"actFill", - }, - text2:{ - label:"分别往对照管和测试管中各加入已稀释的待测血清预计", - type:"text", - }, - dcxqyj:{ - type:"inputNumber", - fillType:"preFill", - }, - dcxqyjdw:{ - type:"select", - options:$this.getDictOptions("business_tjdw"), - fillType:"preFill", - }, - text3:{ - label:"实际", - type:"text", - }, - dcxqsj:{ - type:"inputNumber", - fillType:"actFill", - compareTo:"dcxqyj", - copyFrom:"dcxqyj" - }, - dcxqsjdw:{ - type:"select", - options:$this.getDictOptions("business_tjdw"), - fillType:"actFill", - compareTo:"dcxqyjdw", - copyFrom:"dcxqyjdw" - } + return [ + { + config: { + text1: { + label: '使用移液器', + type: 'text' + }, + yyq: { + type: 'yq', + fillType: 'actFill' + }, + text2: { + label: '分别往对照管和测试管中各加入已稀释的待测血清预计', + type: 'text' + }, + dcxqyj: { + type: 'inputNumber', + fillType: 'preFill' + }, + dcxqyjdw: { + type: 'select', + options: $this.getDictOptions('business_tjdw'), + fillType: 'preFill' + }, + text3: { + label: '实际', + type: 'text' + }, + dcxqsj: { + type: 'inputNumber', + fillType: 'actFill', + compareTo: 'dcxqyj', + copyFrom: 'dcxqyj' + }, + dcxqsjdw: { + type: 'select', + options: $this.getDictOptions('business_tjdw'), + fillType: 'actFill', + compareTo: 'dcxqyjdw', + copyFrom: 'dcxqyjdw' } - }] + } + } + ] } -//操作第五步配置 +//操作第五步配制 export const getStepFivth = ($this) => { - return [{ - config:{ - text1:{ - label:"将以上缓冲液与血清放在摇床", - type:"text", - }, - yc:{ - type:"yq", - fillType:"actFill", - }, - text2:{ - label:"上充分混匀,置于孵育箱", - type:"text", - }, - fyx:{ - type:"yq", - fillType:"actFill", - }, - text3:{ - label:"中,设置预计温度", - type:"text", - }, - yjwd:{ - type:"inputNumber", - fillType:"preFill", - }, - text4:{ - label:"℃,实际温度", - type:"text", - }, - sjwd:{ - type:"inputNumber", - fillType:"actFill", - compareTo:"yjwd", - copyFrom:"yjwd" - }, - text5:{ - label:"℃,孵育", - type:"text", - }, - fysj:{ - type:"inputNumber", - fillType:"preFill", - }, - text6:{ - label:"小时。", - type:"text", - }, + return [ + { + config: { + text1: { + label: '将以上缓冲液与血清放在摇床', + type: 'text' + }, + yc: { + type: 'yq', + fillType: 'actFill' + }, + text2: { + label: '上充分混匀,置于孵育箱', + type: 'text' + }, + fyx: { + type: 'yq', + fillType: 'actFill' + }, + text3: { + label: '中,设置预计温度', + type: 'text' + }, + yjwd: { + type: 'inputNumber', + fillType: 'preFill' + }, + text4: { + label: '℃,实际温度', + type: 'text' + }, + sjwd: { + type: 'inputNumber', + fillType: 'actFill', + compareTo: 'yjwd', + copyFrom: 'yjwd' + }, + text5: { + label: '℃,孵育', + type: 'text' + }, + fysj: { + type: 'inputNumber', + fillType: 'preFill' + }, + text6: { + label: '小时。', + type: 'text' } - }] + } + } + ] } -//操作第六步配置 +//操作第六步配制 export const getStepSixth = ($this) => { - return [{ - config:{ - text1:{ - label:"孵育完成后,使用移液器", - type:"text", - }, - yyq:{ - type:"yq", - fillType:"actFill", - }, - text2:{ - label:"将对照管和测试管的溶液转移至对应的比色皿,用紫外分光光度计", - type:"text", - }, - zwfggdj:{ - type:"yq", - fillType:"actFill", - }, - text3:{ - label:",设置预计波长", - type:"text", - }, - yjbc:{ - type:"inputNumber", - fillType:"preFill", - }, - text4:{ - label:"nm,实际波长", - type:"text", - }, - sjbc:{ - type:"inputNumber", - fillType:"actFill", - compareTo:"yjbc", - copyFrom:"yjbc" - }, - text5:{ - label:"nm,测定其OD值。", - type:"text", - }, + return [ + { + config: { + text1: { + label: '孵育完成后,使用移液器', + type: 'text' + }, + yyq: { + type: 'yq', + fillType: 'actFill' + }, + text2: { + label: '将对照管和测试管的溶液转移至对应的比色皿,用紫外分光光度计', + type: 'text' + }, + zwfggdj: { + type: 'yq', + fillType: 'actFill' + }, + text3: { + label: ',设置预计波长', + type: 'text' + }, + yjbc: { + type: 'inputNumber', + fillType: 'preFill' + }, + text4: { + label: 'nm,实际波长', + type: 'text' + }, + sjbc: { + type: 'inputNumber', + fillType: 'actFill', + compareTo: 'yjbc', + copyFrom: 'yjbc' + }, + text5: { + label: 'nm,测定其OD值。', + type: 'text' } - }] -} \ No newline at end of file + } + } + ] +} diff --git a/src/views/business/comps/template/mixins/templateMixin.js b/src/views/business/comps/template/mixins/templateMixin.js index 8e7aee4..1e3d518 100644 --- a/src/views/business/comps/template/mixins/templateMixin.js +++ b/src/views/business/comps/template/mixins/templateMixin.js @@ -1,729 +1,805 @@ import moment from 'moment' -import { getLatestSn, getLatestSnArr } from '@/api/template'; -import { isValueEmpty, getStringWidth, getuuid } from '@/utils/index'; -import { isCommonUnit } from "@/utils/conTools"; -import { sj_subpackage, sj_startConfiguration, sj_configurationCompleted } from '@/api/business/sj/sj'; -import { convertConcentration } from "@/utils/conConverter";//浓度单位转换 -import { volumeConverter } from "@/utils/volConverter";//体积单位转换 +import { getLatestSn, getLatestSnArr } from '@/api/template' +import { isValueEmpty, getStringWidth, getuuid } from '@/utils/index' +import { isCommonUnit } from '@/utils/conTools' +import { + sj_subpackage, + sj_startConfiguration, + sj_configurationCompleted +} from '@/api/business/sj/sj' +import { convertConcentration } from '@/utils/conConverter' //浓度单位转换 +import { volumeConverter } from '@/utils/volConverter' //体积单位转换 import * as XLSX from 'xlsx' -import { EventBus } from "@/utils/eventBus"; +import { EventBus } from '@/utils/eventBus' export default { - dicts: [ - 'business_pztj', - 'business_cctj', - 'business_nddw', - 'business_tjdw', - 'business_zldw', - 'business_yxqdw', - 'business_rqcz', + dicts: [ + 'business_pztj', + 'business_cctj', + 'business_nddw', + 'business_tjdw', + 'business_zldw', + 'business_yxqdw', + 'business_rqcz', - 'business_sp_jmdyzqdyp', //色谱-编号-准确度与精密度 - 'business_sp_nbgzy', //色谱-编号-内标工作液 - 'business_sp_zkgzy', //色谱-编号-质控工作液 - 'business_sp_bqgzy', //色谱-编号-标曲工作液 - 'business_sp_bzqxzkypzbb', //色谱-编号-标准曲线/质控样品制备表 - 'business_sp_tqhsl', //色谱-编号-提取回收率 - 'business_sp_qxwdx', //色谱-编号-全血稳定性 - 'business_sp_cbyhgzywdx', //色谱-编号-储备液和工作液稳定性 - 'business_sp_rxjzxy', //色谱-编号-溶血基质效应 - 'business_sp_jzxy', //色谱-编号-基质效应 - 'business_sp_xzxytyx', //色谱-编号-选择性与特异性 - 'business_sp_zdybs', //色谱-编号-最大样本数 - 'business_sp_xskkx', //色谱-编号-稀释可靠性 - 'business_sp_cbydb', //色谱-编号-储备液对比 - 'business_pcr_gzy', // PCR-编号-工作液 + 'business_sp_jmdyzqdyp', //色谱-编号-准确度与精密度 + 'business_sp_nbgzy', //色谱-编号-内标工作液 + 'business_sp_zkgzy', //色谱-编号-质控工作液 + 'business_sp_bqgzy', //色谱-编号-标曲工作液 + 'business_sp_bzqxzkypzbb', //色谱-编号-标准曲线/质控样品制备表 + 'business_sp_tqhsl', //色谱-编号-提取回收率 + 'business_sp_qxwdx', //色谱-编号-全血稳定性 + 'business_sp_cbyhgzywdx', //色谱-编号-储备液和工作液稳定性 + 'business_sp_rxjzxy', //色谱-编号-溶血基质效应 + 'business_sp_jzxy', //色谱-编号-基质效应 + 'business_sp_xzxytyx', //色谱-编号-选择性与特异性 + 'business_sp_zdybs', //色谱-编号-最大样本数 + 'business_sp_xskkx', //色谱-编号-稀释可靠性 + 'business_sp_cbydb', //色谱-编号-储备液对比 + 'business_pcr_gzy', // PCR-编号-工作液 - 'business_lba_jg', // LBA006-结果 - 'business_cftj', // 存放条件 - 'business_yplx', // 样品类型 - 'business_sydd', // 毒理-Ames实验地点 - 'business_dl_ameswrqk', // 毒理-Ames污染情况 - 'business_dl_amescltj', // 毒理-Ames处理条件 - 'business_dl_amesbjjt', // 毒理-Ames背景菌苔 - 'business_dl_amescdqk', // 毒理-Ames沉淀情况 - 'business_dl_xbmc', // 毒理-Ames细胞名称 - 'business_dl_qsxjbltj', // 毒理-暴露条件 - 'business_rylx', // 溶液类型 - 'business_xbzb', // 细胞组别 - 'business_xblx', // 细胞类型 - 'business_pytj', // 毒理-培养条件 - 'business_fstj', // 毒理-复苏条件 + 'business_lba_jg', // LBA006-结果 + 'business_cftj', // 存放条件 + 'business_yplx', // 样品类型 + 'business_sydd', // 毒理-Ames实验地点 + 'business_dl_ameswrqk', // 毒理-Ames污染情况 + 'business_dl_amescltj', // 毒理-Ames处理条件 + 'business_dl_amesbjjt', // 毒理-Ames背景菌苔 + 'business_dl_amescdqk', // 毒理-Ames沉淀情况 + 'business_dl_xbmc', // 毒理-Ames细胞名称 + 'business_dl_qsxjbltj', // 毒理-暴露条件 + 'business_rylx', // 溶液类型 + 'business_xbzb', // 细胞组别 + 'business_xblx', // 细胞类型 + 'business_pytj', // 毒理-培养条件 + 'business_fstj', // 毒理-复苏条件 - 'business_dsfs', //动技-递送方式 - 'business_knj', //动技-抗凝剂 - 'business_fhlr', //动技-复核内容 - 'business_fhfw', //动技-复核范围 + 'business_dsfs', //动技-递送方式 + 'business_knj', //动技-抗凝剂 + 'business_fhlr', //动技-复核内容 + 'business_fhfw', //动技-复核范围 - 'business_dwzs', // 动物种属 - 'business_cjdd', // 采集地点 - 'business_zpdd', // 制片地点 - 'business_cjbw', // 制片部位 - 'business_qywz', // 取样位置 + 'business_dwzs', // 动物种属 + 'business_cjdd', // 采集地点 + 'business_zpdd', // 制片地点 + 'business_cjbw', // 制片部位 + 'business_qywz', // 取样位置 - 'business_lba_ptjhbzqx_zkpx', // LBA-编号-配体结合分析标准曲线LBA005-质控平行 - 'business_lba_bqpx', //LBA-编号-配体结合分析标准曲线LBA005-标曲平行 - 'business_lba_ptjhfxyp', // LBA-编号-配体结合分析方法学样品制备表LBA007 - 'business_ada_kyktzkyp', // ADA-编号-抗药抗体质控样品配制记录表ADA005 - 'business_ada_kyktffxyp', // ADA-编号-抗药抗体方法学样品制备表ADA007 - 'business_dl_uav', // 毒理-紫外照射操作记录表-UVA-DL023 - 'business_pcr_fxffypzbb', //PCR-编号-分析方法学样品制备表 - 'business_dl_xbx', //毒理-紫外照射操作记录表-细胞系 - 'business_dl_dwzs', //毒理-紫外照射操作记录表-动物种属 - ], - props: { - templateData: { - type: Object, - default: () => { } - } - }, - watch: { - templateData: { - immediate: true, - deep: true, - handler(v) { - if (v) { - const { - studySubjectId, - studyId, - studyMc, - studySn, - templateMc, - templateMcEn, - templateId, - templateSn, - startDate, - submittedCodes, - bdmc, - endDate, - id - } = v - if (v.resource) { - //type 类型:1:试剂;3:给药制剂;5:麻精药;7:供试品 9:细胞;11:细菌 - //试验试剂信息 试剂 - // this.resource = _.filter(JSON.parse(v.resource), function (o) { - // return o.type == 1 || o.elnType == 1 - // }) - // //试验物资信息 供试品、给药制剂、麻精药 - // this.resourceWz = _.filter(JSON.parse(v.resource), function (o) { - // return o.type == 3 || o.type == 5 || o.type == 7 || o.elnType == 3|| o.elnType == 5 || o.elnType == 7 - // }) - //试验试剂信息 - this.resourceSj = _.filter(JSON.parse(v.resource), function (o) { - return o.type == 1 || o.elnType == 1 - }) - //供试品信息 - this.resourceGsp = _.filter(JSON.parse(v.resource), function (o) { - return o.type == 7 || o.elnType == 7 - }) - //给药制剂信息 - this.resourceGyzj = _.filter(JSON.parse(v.resource), function (o) { - return o.type == 3 || o.elnType == 3 - }) - //麻精药信息 - this.resourceMjy = _.filter(JSON.parse(v.resource), function (o) { - return o.type == 5 || o.elnType == 5 - }) - } - if (v.yqResource) { - //仪器信息 - this.yqResource = JSON.parse(v.yqResource) - } - this.product = v.product || null - if (v.bdnr) { - this.formData = { - ...JSON.parse(v.bdnr), - studySubjectId, - studyId, - studyMc, - studySn, - templateMc, - templateMcEn, - templateId, - templateSn, - startDate, - submittedCodes, - bdmc, - endDate, - id - } - } else { - this.formData = { - studySubjectId, - studyId, - studyMc, - studySn, - templateMc, - templateMcEn, - templateId, - templateSn, - submittedCodes, - startDate, - bdmc, - endDate, - id - } - } - const { effectivePeriod, effectivePeriodUnit, expireDate } = - this.formData - //实际填报的时候,如果有了开始时间,并且有有效周期,但是没有失效日,就计算失效日为开始时间+有效周期 - if ( - startDate && - this.fillType === 'actFill' && - effectivePeriod && - effectivePeriodUnit && - !expireDate - ) { - let end; - if (effectivePeriod === "NA" || effectivePeriodUnit === "NA") { - end = "NA"; - } else { - const start = moment(startDate) - const unit = effectivePeriodUnit === '天' ? 'days' : 'hours' - end = start - .add(Number(effectivePeriod), unit) - .format('YYYY-MM-DD HH:mm:ss') - } + 'business_lba_ptjhbzqx_zkpx', // LBA-编号-配体结合分析标准曲线LBA005-质控平行 + 'business_lba_bqpx', //LBA-编号-配体结合分析标准曲线LBA005-标曲平行 + 'business_lba_ptjhfxyp', // LBA-编号-配体结合分析方法学样品制备表LBA007 + 'business_ada_kyktzkyp', // ADA-编号-抗药抗体质控样品配制记录表ADA005 + 'business_ada_kyktffxyp', // ADA-编号-抗药抗体方法学样品制备表ADA007 + 'business_dl_uav', // 毒理-紫外照射操作记录表-UVA-DL023 + 'business_pcr_fxffypzbb', //PCR-编号-分析方法学样品制备表 + 'business_dl_xbx', //毒理-紫外照射操作记录表-细胞系 + 'business_dl_dwzs' //毒理-紫外照射操作记录表-动物种属 + ], + props: { + templateData: { + type: Object, + default: () => {} + } + }, + watch: { + templateData: { + immediate: true, + deep: true, + handler(v) { + if (v) { + const { + studySubjectId, + studyId, + studyMc, + studySn, + templateMc, + templateMcEn, + templateId, + templateSn, + startDate, + submittedCodes, + bdmc, + endDate, + id + } = v + if (v.resource) { + //type 类型:1:试剂;3:给药制剂;5:麻精药;7:供试品 9:细胞;11:细菌 + //试验试剂信息 试剂 + // this.resource = _.filter(JSON.parse(v.resource), function (o) { + // return o.type == 1 || o.elnType == 1 + // }) + // //试验物资信息 供试品、给药制剂、麻精药 + // this.resourceWz = _.filter(JSON.parse(v.resource), function (o) { + // return o.type == 3 || o.type == 5 || o.type == 7 || o.elnType == 3|| o.elnType == 5 || o.elnType == 7 + // }) + //试验试剂信息 + this.resourceSj = _.filter(JSON.parse(v.resource), function (o) { + return o.type == 1 || o.elnType == 1 + }) + //供试品信息 + this.resourceGsp = _.filter(JSON.parse(v.resource), function (o) { + return o.type == 7 || o.elnType == 7 + }) + //给药制剂信息 + this.resourceGyzj = _.filter(JSON.parse(v.resource), function (o) { + return o.type == 3 || o.elnType == 3 + }) + //麻精药信息 + this.resourceMjy = _.filter(JSON.parse(v.resource), function (o) { + return o.type == 5 || o.elnType == 5 + }) + } + if (v.yqResource) { + //仪器信息 + this.yqResource = JSON.parse(v.yqResource) + } + this.product = v.product || null + if (v.bdnr) { + this.formData = { + ...JSON.parse(v.bdnr), + studySubjectId, + studyId, + studyMc, + studySn, + templateMc, + templateMcEn, + templateId, + templateSn, + startDate, + submittedCodes, + bdmc, + endDate, + id + } + } else { + this.formData = { + studySubjectId, + studyId, + studyMc, + studySn, + templateMc, + templateMcEn, + templateId, + templateSn, + submittedCodes, + startDate, + bdmc, + endDate, + id + } + } + const { effectivePeriod, effectivePeriodUnit, expireDate } = + this.formData + //实际填报的时候,如果有了开始时间,并且有有效周期,但是没有失效日,就计算失效日为开始时间+有效周期 + if ( + startDate && + this.fillType === 'actFill' && + effectivePeriod && + effectivePeriodUnit && + !expireDate + ) { + let end + if (effectivePeriod === 'NA' || effectivePeriodUnit === 'NA') { + end = 'NA' + } else { + const start = moment(startDate) + const unit = effectivePeriodUnit === '天' ? 'days' : 'hours' + end = start + .add(Number(effectivePeriod), unit) + .format('YYYY-MM-DD HH:mm:ss') + } - this.formData = { ...this.formData, expireDate: end } - } - console.log(this.formData, 'formData from templateData') - this.setTemplateData(v) - } - } - } - }, - data() { - return { - formData: {}, - templateDetail: {}, - product: null,//产物:1:试剂;3:给药制剂;5:麻精药 - resource: [], //试验试剂信息--弃用 - resourceWz: [], //物资信息--弃用 + this.formData = { ...this.formData, expireDate: end } + } + console.log(this.formData, 'formData from templateData') + this.setTemplateData(v) + } + } + } + }, + data() { + return { + formData: {}, + templateDetail: {}, + product: null, //产物:1:试剂;3:给药制剂;5:麻精药 + resource: [], //试验试剂信息--弃用 + resourceWz: [], //物资信息--弃用 - resourceSj: [],//试验试剂信息 - resourceGsp: [],//供试品信息 - resourceGyzj: [],//给药制剂信息 - resourceMjy: [],//麻精药信息 + resourceSj: [], //试验试剂信息 + resourceGsp: [], //供试品信息 + resourceGyzj: [], //给药制剂信息 + resourceMjy: [], //麻精药信息 - yqResource: [], //仪器信息 - jcbList: [], //检测板信息 - xbxj: [], //细胞细菌信息 + yqResource: [], //仪器信息 + jcbList: [], //检测板信息 + xbxj: [], //细胞细菌信息 + resourceTmp: [], //试验试剂信息提交用 + yqResourceTmp: [], //仪器信息提交用 + jcbListTmp: [], //检测板信息提交用 + xbxjTmp: [], //细胞细菌信息提交用 + sjColumns: [ + { label: 'template.common.reagentName', prop: 'mc' }, //名称 + { label: 'template.common.reagentCode', prop: 'bh' }, //编号 + { label: 'template.common.reagentNo', prop: 'ph' }, //批号 试剂,供试品才有 + { label: 'template.common.concentration', prop: 'ndz' }, //浓度 + { label: 'template.common.source', prop: 'ly' }, //来源 + { label: 'template.common.reagentExpireDate', prop: 'sxrq' } //失效日期 + ], + gspColumns: [ + { label: 'template.common.wzName', prop: 'mc' }, //名称 + { label: 'template.common.wzCode', prop: 'bh' }, //编号 + { label: 'template.common.reagentNo', prop: 'ph' }, //批号 试剂,供试品才有 + { label: 'template.common.wzSource', prop: 'ly' }, //来源 + { label: 'template.common.wzConcentration', prop: 'ndz' }, //浓度 + { label: 'template.common.wzExpireDate', prop: 'sxrq' } //失效日期 + ], + gyzjColumns: [ + { label: 'template.common.wzName', prop: 'mc' }, //名称 + { label: 'template.common.wzCode', prop: 'bh' }, //编号 + { label: 'template.common.wzSource', prop: 'ly' }, //来源 + { label: 'template.common.wzConcentration', prop: 'ndz' }, //浓度 + { label: 'template.common.wzExpireDate', prop: 'sxrq' } //失效日期 + ], + mjyColumns: [ + { label: 'template.common.wzName', prop: 'mc' }, //名称 + { label: 'template.common.wzCode', prop: 'bh' }, //编号 + { label: 'template.common.wzSource', prop: 'ly' }, //来源 + { label: 'template.common.wzConcentration', prop: 'ndz' }, //浓度 + { label: 'template.common.wzExpireDate', prop: 'sxrq' } //失效日期 + ], + //弃用 + sysjColumns: [ + { label: 'template.common.reagentName', prop: 'mc' }, //名称 + { label: 'template.common.reagentCode', prop: 'bh' }, //编号 + { label: 'template.common.reagentNo', prop: 'ph' }, //批号 试剂,供试品才有 + { label: 'template.common.concentration', prop: 'ndz' }, //浓度 + { label: 'template.common.source', prop: 'ly' }, //来源 + { label: 'template.common.reagentExpireDate', prop: 'sxrq' } //失效日期 + ], + //弃用 + sywzColumns: [ + { label: 'template.common.wzName', prop: 'mc' }, //名称 + { label: 'template.common.wzCode', prop: 'bh' }, //编号 + { label: 'template.common.wzSource', prop: 'ly' }, //来源 + { label: 'template.common.wzConcentration', prop: 'ndz' }, //浓度 + { label: 'template.common.wzExpireDate', prop: 'sxrq' } //失效日期 + ], + yqColumns: [ + { label: 'template.common.instrumentName', prop: 'mc' }, //仪器名称 + { label: 'template.common.instrumentModel', prop: 'xh' }, //仪器型号 + { label: 'template.common.instrumentCode', prop: 'bh' }, //仪器编号 + { label: 'template.common.nextTestDate', prop: 'jzrq' } //下次测试/校准/检定日期 + ] + } + }, + mounted() {}, + unmounted() { + this.setTemplateData({}) + }, + methods: { + // 只是更新已填写的表单数据,不触发校验 + justUpdateFilledFormData() { + const params = { + type: 'fieldChanged', + newRecord: null, + resourceList: null + } + EventBus.$emit('onModifyRecord', params) + }, + //试剂弹窗确认前 + onBeforeReagentSubmit(data) { + const { selectData, callback, key, formFields } = data + const { subTargetStartSolution, targetStartSolution } = formFields + const { nd } = selectData.row + const sjndArr = nd.split('/') + const ytndArr = targetStartSolution.split('/') + //判断选择的浓度单位和预制的浓度单位是否一致 + if ( + key === 'subStartSolution' && + !isCommonUnit(selectData.row.nddw, [subTargetStartSolution]) + ) { + //选择起始源溶液需要同步更新table的变更记录。 + callback.prevent('浓度单位与预制不符,请重新选择或申请废止并重新预制。') + } else if (nd === 'NA') { + callback.prevent('当前实际浓度为NA,请重新选择') + } else if (ytndArr.length !== sjndArr.length) { + callback.prevent('起始溶液浓度和目标溶液浓度格式不一致,请重新输入') + } + }, + getFormDataByTemplateData() { + let o = {} + const { bdnr } = this.templateData + if (bdnr) { + o = JSON.parse(bdnr) + } + return o + }, + //开始配制 + //postData: {bh: '123456'} + async startConfigRequest(postData) { + const res = await sj_startConfiguration(postData) + if (res.code === 200) { + this.$message.success('开始配制成功') + } else { + this.$message.error('开始配制失败') + } + }, + //完成配制 + async configCompleteRequest(postData) { + const res = await sj_configurationCompleted(postData) + if (res.code === 200) { + this.$message.success('完成配制成功') + } else { + this.$message.error('完成配制失败') + } + }, + //分装 + async subPackageRequest(postData) { + const res = await sj_subpackage(postData) + if (res.code === 200) { + this.$message.success('分装成功') + } else { + this.$message.error('分装失败') + } + }, + //获取打印配制 + getBasePrintConfig(data = {}) { + const { printCode, type, row = {} } = data + const { stepStorageCondition, startDate, expireDate } = this.formData + const { nickName, name } = this.$store.getters + const lang = this.$i18n.locale + const printConfig = { + 品名: '暂时还不知道品名是哪个字段', + 存储条件: stepStorageCondition, + 配制日期: moment(startDate).format('YYYY-MM-DD'), + 有效期至: moment(expireDate).format('YYYY-MM-DD HH:mm'), + 配制者: lang === 'zh_CN' ? nickName : name, + //type==="subPackage"从分装打印过来的, + //type==="row" 从列表上点过来的 + 编号: + type === 'subPackage' + ? printCode + : row.targetSolutionCode + row.subTargetSolutionCode + } + return printConfig + }, + async getLatestSn(count = 1) { + const res = await getLatestSn({ count }) + if (res.code === 200) { + return res.data + } + return [] + }, + //获取最新的多个编号 + async getLatestSnArr(params) { + const res = await getLatestSnArr(params) + if (res.code === 200) { + return res.data + } + return [] + }, + getResource() { + return this.resourceTmp + }, + getYqResource() { + return this.yqResourceTmp + }, + getJcbList() { + return this.jcbListTmp + }, + getXbxj() { + return this.xbxjTmp + }, + //根据ref数组获取直接formData + getFilledFormDataByRefs(refArr = []) { + let result = {} + refArr.map((ref) => { + const refData = this.$refs[ref]?.getFilledFormData() || {} + for (const [key, value] of Object.entries(refData)) { + let index = 0 + // 如果当前键是可能重复的字段,且结果对象中已经存在该键,则添加索引后缀 + if ( + (key === 'headerSelectFields' || key === 'stepTableFormData') && + result.hasOwnProperty(key) + ) { + // 为重复字段生成带索引的键名,从1开始(因为第一个组件不需要后缀) + const newKey = `${key}_${++index}` + result[newKey] = value + } else { + // 正常合并其他字段 + result[key] = value + } + } + }) + return result + }, + //统一校验form表单是否填写 + async validFormFields(refArr = []) { + let result = {} + const refs = refArr.map((ref) => { + let refData = {} + if (this.$refs[ref]) { + if (this.$refs[ref][0]) { + refData = this.$refs[ref][0]?.getFormData() || {} + } else { + refData = this.$refs[ref]?.getFormData() || {} + } + } + return refData + }) + const validFormData = await Promise.all(refs).catch((err) => { + // this.$message.error(err); + if (err.errorType && err.errorType === 'step') { + this.$message.error('请添加步骤') + return + } + this.$message.error('表单内容未填完,请填写后再提交') + }) + if (validFormData) { + validFormData.forEach((item) => { + for (const [key, value] of Object.entries(item)) { + let index = 0 + // 如果当前键是可能重复的字段,且结果对象中已经存在该键,则添加索引后缀 + if ( + (key === 'headerSelectFields' || key === 'stepTableFormData') && + result.hasOwnProperty(key) + ) { + // 为重复字段生成带索引的键名,从1开始(因为第一个组件不需要后缀) + const newKey = `${key}_${++index}` + result[newKey] = value + } else { + // 正常合并其他字段 + result[key] = value + } + } + }) + return result + } + return false + }, + //试验配制条件options + getDictOptions(dictType) { + return this.dict.type[dictType] || [] + }, - resourceTmp: [],//试验试剂信息提交用 - yqResourceTmp: [], //仪器信息提交用 - jcbListTmp: [], //检测板信息提交用 - xbxjTmp: [],//细胞细菌信息提交用 - sjColumns: [ - { label: 'template.common.reagentName', prop: "mc" },//名称 - { label: 'template.common.reagentCode', prop: "bh" },//编号 - { label: 'template.common.reagentNo', prop: "ph" },//批号 试剂,供试品才有 - { label: 'template.common.concentration', prop: "ndz" },//浓度 - { label: 'template.common.source', prop: "ly" },//来源 - { label: 'template.common.reagentExpireDate', prop: "sxrq" },//失效日期 - ], - gspColumns: [ - { label: 'template.common.wzName', prop: "mc" },//名称 - { label: 'template.common.wzCode', prop: "bh" },//编号 - { label: 'template.common.reagentNo', prop: "ph" },//批号 试剂,供试品才有 - { label: 'template.common.wzSource', prop: "ly" },//来源 - { label: 'template.common.wzConcentration', prop: "ndz" },//浓度 - { label: 'template.common.wzExpireDate', prop: "sxrq" },//失效日期 - ], - gyzjColumns: [ - { label: 'template.common.wzName', prop: "mc" },//名称 - { label: 'template.common.wzCode', prop: "bh" },//编号 - { label: 'template.common.wzSource', prop: "ly" },//来源 - { label: 'template.common.wzConcentration', prop: "ndz" },//浓度 - { label: 'template.common.wzExpireDate', prop: "sxrq" },//失效日期 - ], - mjyColumns: [ - { label: 'template.common.wzName', prop: "mc" },//名称 - { label: 'template.common.wzCode', prop: "bh" },//编号 - { label: 'template.common.wzSource', prop: "ly" },//来源 - { label: 'template.common.wzConcentration', prop: "ndz" },//浓度 - { label: 'template.common.wzExpireDate', prop: "sxrq" },//失效日期 - ], - //弃用 - sysjColumns: [ - { label: 'template.common.reagentName', prop: "mc" },//名称 - { label: 'template.common.reagentCode', prop: "bh" },//编号 - { label: 'template.common.reagentNo', prop: "ph" },//批号 试剂,供试品才有 - { label: 'template.common.concentration', prop: "ndz" },//浓度 - { label: 'template.common.source', prop: "ly" },//来源 - { label: 'template.common.reagentExpireDate', prop: "sxrq" },//失效日期 - ], - //弃用 - sywzColumns: [ - { label: 'template.common.wzName', prop: "mc" },//名称 - { label: 'template.common.wzCode', prop: "bh" },//编号 - { label: 'template.common.wzSource', prop: "ly" },//来源 - { label: 'template.common.wzConcentration', prop: "ndz" },//浓度 - { label: 'template.common.wzExpireDate', prop: "sxrq" },//失效日期 - ], - yqColumns: [ - { label: 'template.common.instrumentName', prop: "mc" },//仪器名称 - { label: 'template.common.instrumentModel', prop: "xh" },//仪器型号 - { label: 'template.common.instrumentCode', prop: "bh" },//仪器编号 - { label: 'template.common.nextTestDate', prop: "jzrq" },//下次测试/校准/检定日期 - ], - } - }, - mounted() { }, - unmounted() { - this.setTemplateData({}) - }, - methods: { - // 只是更新已填写的表单数据,不触发校验 - justUpdateFilledFormData() { - const params = { - type: "fieldChanged", - newRecord: null, - resourceList: null, - } - EventBus.$emit('onModifyRecord', params,) - }, - //试剂弹窗确认前 - onBeforeReagentSubmit(data) { - const { selectData, callback, key, formFields } = data; - const { subTargetStartSolution,targetStartSolution } = formFields; - const { nd } = selectData.row; - const sjndArr = nd.split('/'); - const ytndArr = targetStartSolution.split('/'); - //判断选择的浓度单位和预制的浓度单位是否一致 - if (key === "subStartSolution" && !isCommonUnit(selectData.row.nddw, [subTargetStartSolution])) {//选择起始源溶液需要同步更新table的变更记录。 - callback.prevent('浓度单位与预制不符,请重新选择或申请废止并重新预制。'); - }else if(nd === "NA") { - callback.prevent('当前实际浓度为NA,请重新选择'); - }else if(ytndArr.length !== sjndArr.length) { - callback.prevent('起始溶液浓度和目标溶液浓度格式不一致,请重新输入'); - } - }, - getFormDataByTemplateData() { - let o = {}; - const { bdnr } = this.templateData - if (bdnr) { - o = JSON.parse(bdnr) - } - return o; - }, - //开始配置 - //postData: {bh: '123456'} - async startConfigRequest(postData) { - const res = await sj_startConfiguration(postData) - if (res.code === 200) { - this.$message.success('开始配置成功') - } else { - this.$message.error('开始配置失败') - } - }, - //完成配置 - async configCompleteRequest(postData) { - const res = await sj_configurationCompleted(postData) - if (res.code === 200) { - this.$message.success('完成配置成功') - } else { - this.$message.error('完成配置失败') - } - }, - //分装 - async subPackageRequest(postData) { - const res = await sj_subpackage(postData) - if (res.code === 200) { - this.$message.success('分装成功') - } else { - this.$message.error('分装失败') - } - }, - //获取打印配置 - getBasePrintConfig(data = {}) { - const { printCode, type, row = {} } = data; - const { stepStorageCondition, startDate, expireDate } = this.formData;; - const { nickName, name } = this.$store.getters; - const lang = this.$i18n.locale; - const printConfig = { - "品名": "暂时还不知道品名是哪个字段", - "存储条件": stepStorageCondition, - "配制日期": moment(startDate).format("YYYY-MM-DD"), - "有效期至": moment(expireDate).format("YYYY-MM-DD HH:mm"), - "配置者": lang === "zh_CN" ? nickName : name, - //type==="subPackage"从分装打印过来的, - //type==="row" 从列表上点过来的 - "编号": type === "subPackage" ? printCode : (row.targetSolutionCode + row.subTargetSolutionCode), - } - return printConfig - }, - async getLatestSn(count = 1) { - const res = await getLatestSn({ count }) - if (res.code === 200) { - return res.data - } - return [] - }, - //获取最新的多个编号 - async getLatestSnArr(params) { - const res = await getLatestSnArr(params) - if (res.code === 200) { - return res.data - } - return [] - }, - getResource() { - return this.resourceTmp - }, - getYqResource() { - return this.yqResourceTmp - }, - getJcbList() { - return this.jcbListTmp - }, - getXbxj() { - return this.xbxjTmp - }, - //根据ref数组获取直接formData - getFilledFormDataByRefs(refArr = []) { - let result = {} - refArr.map((ref) => { - const refData = this.$refs[ref]?.getFilledFormData() || {} - for (const [key, value] of Object.entries(refData)) { - let index = 0 - // 如果当前键是可能重复的字段,且结果对象中已经存在该键,则添加索引后缀 - if ( - (key === 'headerSelectFields' || key === 'stepTableFormData') && - result.hasOwnProperty(key) - ) { - // 为重复字段生成带索引的键名,从1开始(因为第一个组件不需要后缀) - const newKey = `${key}_${++index}` - result[newKey] = value - } else { - // 正常合并其他字段 - result[key] = value - } - } - }) - return result - }, - //统一校验form表单是否填写 - async validFormFields(refArr = []) { - let result = {} - const refs = refArr.map((ref) => { - let refData = {} - if (this.$refs[ref]) { - if (this.$refs[ref][0]) { - refData = this.$refs[ref][0]?.getFormData() || {} - } else { - refData = this.$refs[ref]?.getFormData() || {} - } - } - return refData - }) - const validFormData = await Promise.all(refs).catch((err) => { - // this.$message.error(err); - if (err.errorType && err.errorType === 'step') { - this.$message.error('请添加步骤') - return - } - this.$message.error('表单内容未填完,请填写后再提交') - }) - if (validFormData) { - validFormData.forEach((item) => { - for (const [key, value] of Object.entries(item)) { - let index = 0 - // 如果当前键是可能重复的字段,且结果对象中已经存在该键,则添加索引后缀 - if ( - (key === 'headerSelectFields' || key === 'stepTableFormData') && - result.hasOwnProperty(key) - ) { - // 为重复字段生成带索引的键名,从1开始(因为第一个组件不需要后缀) - const newKey = `${key}_${++index}` - result[newKey] = value - } else { - // 正常合并其他字段 - result[key] = value - } - } - }) - return result - } - return false - }, - //试验配制条件options - getDictOptions(dictType) { - return this.dict.type[dictType] || [] - }, + setTemplateData(data) { + this.$store.commit('template/SET_TEMPLATE_DATA', data) + }, + //统一处理删除行 + deleteRow(index, ref) { + if (ref) { + this.$refs[ref].deleteRow(index) + return + } + this.$refs.stepTableRef.deleteRow(index) + }, - setTemplateData(data) { - this.$store.commit('template/SET_TEMPLATE_DATA', data) - }, - //统一处理删除行 - deleteRow(index, ref) { - if (ref) { - this.$refs[ref].deleteRow(index); - return; - } - this.$refs.stepTableRef.deleteRow(index) - }, + //统一处理浓度校验异常 + onCommonVerifyNdException(formFields, data) { + const { callback, rowIndex, key, dataSource } = data + const keys = ['actStartSolutionVolume', 'actDiluentVolume'] + if (keys.includes(key)) { + const { targetAcSolution } = formFields + if (rowIndex === 0) { + //第一行的浓度取选择的溶液, + if (isValueEmpty(targetAcSolution)) { + callback.prevent('请先选择起始源溶液') + } + } else { + //非第一行的浓度取上一行的浓度 + const prevItem = dataSource[rowIndex - 1] + const prevConcentration = prevItem.actSolutionConcentration + if (!prevConcentration) { + callback.prevent('请先计算上一行的实际目标溶液浓度') + } + } + } + }, + //统一处理blur事件,因为有效周期和过期日期是相关的,所以需要在有效周期失焦时更新过期日期 + onHandleBlur(fields) { + const { + key, + codeSTD, + targetStartSolution, + subTargetStartSolution //预设起始源溶液浓度单位 + } = fields + const { startDate } = this.formData + if (key === 'codeSTD') { + //起始编号STD失焦时,更新stepDataSource + const arr = Array.from({ length: codeSTD }, (item, index) => ({ + actSolutionVolumePrecision: 3, //小数点精度默认为3 + actSolutionConcentrationPrecision: 3, //小数点精度默认为3 + targetDiluentVolumePrecision: 3, //小数点精度默认为3 + targetStartSolutionVolumePrecision: 3, //小数点精度默认为3 + targetSolutionCode: `CA-WS-STD${Number(codeSTD) - index}`, + id: getuuid(), + rowIndex: index + })) + this.$refs.stepTableRef.updateDataSource(arr) + } else if ( + key === 'targetStartSolution' || + key === 'subTargetStartSolution' + ) { + //起始溶液体积失焦时,更新目标溶液预计浓度 + const arr = this.$refs.stepTableRef?.getDataSource() + const { headerSelectFields, stepTableFormData = [] } = + this.$refs.stepTableRef?.getFilledFormData() + const params = { + subTargetStartSolution, + headerSelectFields, + dataSource: stepTableFormData + } + arr.forEach((item, rowIndex) => { + this.updateTargetStartSolutionVolume( + item, + targetStartSolution, + params + ) + }) + } + }, + //批量更新目标起始源溶液体积 + batchUpdateTargetStartSolutionVolume(arr, startConcentration, params) { + params.dataSource = arr + arr.forEach((item, rowIndex) => { + this.updateTargetStartSolutionVolume(item, startConcentration, params) + }) + }, + //统一处理table失焦事件 + onHandleTableBlur(params) { + const { rowIndex, colKey, value, item, dataSource, headerSelectFields } = + params + if ( + colKey === 'targetSolutionVolume' || + colKey === 'targetSolutionConcentration' || + colKey === 'targetStartSolutionVolumePrecision' || + colKey === 'targetDiluentVolumePrecision' + ) { + const volume = this.$refs.stepFormPackageRef?.getFormDataByKey( + 'targetStartSolution' + ) + const subTargetStartSolution = + this.$refs.stepFormPackageRef?.getFormDataByKey( + 'subTargetStartSolution' + ) + const params = { + subTargetStartSolution: subTargetStartSolution, + headerSelectFields, + dataSource + } + if (isValueEmpty(volume)) { + this.$message.error('请先选择预设起始源溶液浓度') + } else { + this.updateTargetStartSolutionVolume(item, volume, params) + } + } else if ( + colKey === 'actStartSolutionVolume' || + colKey === 'actDiluentVolume' + ) { + //实际起始溶液体积和实际目标溶液体积 + const { targetAcSolution, subTargetAcSolutionUnit } = + this.$refs.stepFormPackageRef?.getFilledFormData() //获取实际起始溶液浓度 + const { headerSelectFields } = + this.$refs.stepTableRef?.getFilledFormData() + const p = { + targetStartSolutionUnit: subTargetAcSolutionUnit, + headerSelectFields + } + let initNd = 0 + if (rowIndex === 0) { + initNd = targetAcSolution + } else { + initNd = dataSource[rowIndex - 1].actSolutionConcentration + } - //统一处理浓度校验异常 - onCommonVerifyNdException(formFields, data) { - const { callback, rowIndex, key, dataSource } = data; - const keys = [ - 'actStartSolutionVolume', - 'actDiluentVolume', - ] - if (keys.includes(key)) { - const { targetAcSolution } = formFields; - if (rowIndex === 0) {//第一行的浓度取选择的溶液, - if (isValueEmpty(targetAcSolution)) { - callback.prevent("请先选择起始源溶液") - } - } else { - //非第一行的浓度取上一行的浓度 - const prevItem = dataSource[rowIndex - 1] - const prevConcentration = prevItem.actSolutionConcentration; - if (!prevConcentration) { - callback.prevent("请先计算上一行的实际目标溶液浓度") - } - } - } + if (isValueEmpty(initNd)) { + console.log('initNd', initNd) + this.$message.error('请先选择起始源溶液') + return + } else { + const volResult = this.updateSjmbrynd(item, initNd, p) + if (!volResult) { + return + } + this.$refs.stepTableRef?.updateDataSourceByRowIndex( + rowIndex, + { + actSolutionVolume: volResult.actVol, + actSolutionConcentration: volResult.actNd + }, + 'blur' + ) + } + } + }, - }, - //统一处理blur事件,因为有效周期和过期日期是相关的,所以需要在有效周期失焦时更新过期日期 - onHandleBlur(fields) { - const { - key, - codeSTD, - targetStartSolution, - subTargetStartSolution,//预设起始源溶液浓度单位 - } = fields - const { startDate } = this.formData - if (key === 'codeSTD') { - //起始编号STD失焦时,更新stepDataSource - const arr = Array.from({ length: codeSTD }, (item, index) => ({ - actSolutionVolumePrecision: 3, //小数点精度默认为3 - actSolutionConcentrationPrecision: 3, //小数点精度默认为3 - targetDiluentVolumePrecision: 3, //小数点精度默认为3 - targetStartSolutionVolumePrecision: 3, //小数点精度默认为3 - targetSolutionCode: `CA-WS-STD${Number(codeSTD) - index}`, - id: getuuid(), - rowIndex: index, - })) - this.$refs.stepTableRef.updateDataSource(arr) - } else if (key === 'targetStartSolution' || key === 'subTargetStartSolution') { - //起始溶液体积失焦时,更新目标溶液预计浓度 - const arr = this.$refs.stepTableRef?.getDataSource(); - const { headerSelectFields, stepTableFormData = [] } = this.$refs.stepTableRef?.getFilledFormData(); - const params = { - subTargetStartSolution, - headerSelectFields, - dataSource: stepTableFormData, - } - arr.forEach((item, rowIndex) => { - this.updateTargetStartSolutionVolume( - item, - targetStartSolution, - params - ) - }) - } - }, - //批量更新目标起始源溶液体积 - batchUpdateTargetStartSolutionVolume(arr, startConcentration, params) { - params.dataSource = arr; - arr.forEach((item, rowIndex) => { - this.updateTargetStartSolutionVolume( - item, - startConcentration, - params - ) - }) - }, - //统一处理table失焦事件 - onHandleTableBlur(params) { - const { rowIndex, colKey, value, item, dataSource, headerSelectFields } = params - if ( - colKey === 'targetSolutionVolume' || - colKey === 'targetSolutionConcentration' || - colKey === 'targetStartSolutionVolumePrecision' || - colKey === 'targetDiluentVolumePrecision' - ) { - const volume = - this.$refs.stepFormPackageRef?.getFormDataByKey( - 'targetStartSolution' - ) - const subTargetStartSolution = - this.$refs.stepFormPackageRef?.getFormDataByKey( - 'subTargetStartSolution' - ) - const params = { - subTargetStartSolution: subTargetStartSolution, - headerSelectFields, - dataSource - } - if (isValueEmpty(volume)) { - this.$message.error('请先选择预设起始源溶液浓度') - } else { - this.updateTargetStartSolutionVolume(item, volume, params) - } - } else if ( - colKey === 'actStartSolutionVolume' || - colKey === 'actDiluentVolume' - ) { - //实际起始溶液体积和实际目标溶液体积 - const { targetAcSolution, subTargetAcSolutionUnit } = - this.$refs.stepFormPackageRef?.getFilledFormData() //获取实际起始溶液浓度 - const { headerSelectFields } = this.$refs.stepTableRef?.getFilledFormData(); - const p = { - targetStartSolutionUnit: subTargetAcSolutionUnit, - headerSelectFields - } - let initNd = 0; - if (rowIndex === 0) { - initNd = targetAcSolution; - } else { - initNd = dataSource[rowIndex - 1].actSolutionConcentration; - } + //计算目标溶液浓度 + calcNd(item, targetAcSolution, params) { + console.log(item, params, 'ppp') + // debugger + //targetStartSolutionUnit(实际起始源溶液浓度单位) + const { targetStartSolutionUnit, headerSelectFields } = params + const { + actStartSolutionVolumeUnit, + actSolutionVolumeUnit, + actDiluentVolumeUnit, + actSolutionConcentrationUnit + } = headerSelectFields + let initUnit = targetStartSolutionUnit + if (item.rowIndex > 0) { + initUnit = actSolutionConcentrationUnit + } + //actStartSolutionVolumeUnit(实际起始源溶液体积单位)actSolutionVolumeUnit(实际目标溶液体积单位) + //actDiluentVolumeUnit(实际稀释液体积单位)actSolutionConcentrationUnit(实际目标溶液浓度单位) + //实际源溶液浓度÷(实际终体积÷源溶液加入体积); + const precision = item.actSolutionConcentrationPrecision + const volPrecision = item.actSolutionVolumePrecision + //实际稀释液体积 + const actDiluentVolume = item.actDiluentVolume + //实际起始源溶液体积 + const actStartSolutionVolume = item.actStartSolutionVolume + if ( + isValueEmpty(actStartSolutionVolume) || + isValueEmpty(actDiluentVolume) || + isValueEmpty(initUnit) + ) { + return false + } + const converActDiluentVolume = volumeConverter.convert( + actDiluentVolume + actDiluentVolumeUnit, + actSolutionVolumeUnit + ) + const converActStartSolutionVolume = volumeConverter.convert( + actStartSolutionVolume + actStartSolutionVolumeUnit, + actSolutionVolumeUnit + ) + //实际源溶液加入体积+实际稀释液加入体积 + const actVol = ( + Number(converActDiluentVolume) + Number(converActStartSolutionVolume) + ).toFixed(volPrecision) + const targetStartVolUnit = actSolutionConcentrationUnit.split('/')[1] //先按照预设目标溶液浓度的单位标准 + const converActVol = volumeConverter.convert( + actVol + actSolutionVolumeUnit, + targetStartVolUnit + ) + const converActDiluentVolume1 = volumeConverter.convert( + actStartSolutionVolume + actStartSolutionVolumeUnit, + targetStartVolUnit + ) + const converArr = (targetAcSolution + '').split('/') + converArr.map((item) => { + return convertConcentration.convert( + item + initUnit, + actSolutionConcentrationUnit + ) + }) - if (isValueEmpty(initNd)) { - console.log("initNd", initNd) - this.$message.error('请先选择起始源溶液') - return - } else { - const volResult = this.updateSjmbrynd(item, initNd, p) - if (!volResult) { - return - } - this.$refs.stepTableRef?.updateDataSourceByRowIndex(rowIndex, { actSolutionVolume: volResult.actVol, actSolutionConcentration: volResult.actNd }, "blur") - } - } - }, + // const converTargetAcSolution = convertConcentration.convert(targetAcSolution + initUnit, actSolutionConcentrationUnit) + // 实际目标溶液浓度 = 实际源溶液浓度÷(实际终体积÷源溶液加入体积); + // const actNd = ( + // parseFloat(converTargetAcSolution) / ( + // parseFloat(converActVol) / parseFloat(converActDiluentVolume1) + // ) + // ).toFixed(precision) + const actNdArr = converArr.map((item) => { + return parseFloat( + (item / (converActVol / converActDiluentVolume1)).toFixed(precision) + ) + }) + // const nd = actNd === 'Infinity' ? 0 : Number(actNd) + console.log( + actNdArr, + targetAcSolution, + actStartSolutionVolume, + actVol, + 'actNd' + ) + // item.actSolutionConcentration = actNd === 'Infinity' ? 0 : actNd + return { actVol: Number(actVol), actNd: actNdArr.join('/') } + }, - //计算目标溶液浓度 - calcNd(item, targetAcSolution, params) { - console.log(item, params, "ppp") - // debugger - //targetStartSolutionUnit(实际起始源溶液浓度单位) - const { targetStartSolutionUnit, headerSelectFields } = params; - const { actStartSolutionVolumeUnit, actSolutionVolumeUnit, actDiluentVolumeUnit, actSolutionConcentrationUnit } = headerSelectFields; - let initUnit = targetStartSolutionUnit; - if (item.rowIndex > 0) { - initUnit = actSolutionConcentrationUnit; - } - //actStartSolutionVolumeUnit(实际起始源溶液体积单位)actSolutionVolumeUnit(实际目标溶液体积单位) - //actDiluentVolumeUnit(实际稀释液体积单位)actSolutionConcentrationUnit(实际目标溶液浓度单位) - //实际源溶液浓度÷(实际终体积÷源溶液加入体积); - const precision = item.actSolutionConcentrationPrecision - const volPrecision = item.actSolutionVolumePrecision; - //实际稀释液体积 - const actDiluentVolume = item.actDiluentVolume - //实际起始源溶液体积 - const actStartSolutionVolume = item.actStartSolutionVolume - if (isValueEmpty(actStartSolutionVolume) || isValueEmpty(actDiluentVolume) || isValueEmpty(initUnit)) { - return false - } - const converActDiluentVolume = volumeConverter.convert(actDiluentVolume + actDiluentVolumeUnit, actSolutionVolumeUnit) - const converActStartSolutionVolume = volumeConverter.convert(actStartSolutionVolume + actStartSolutionVolumeUnit, actSolutionVolumeUnit) - //实际源溶液加入体积+实际稀释液加入体积 - const actVol = ( - Number(converActDiluentVolume) + Number(converActStartSolutionVolume) - ).toFixed(volPrecision) - const targetStartVolUnit = actSolutionConcentrationUnit.split("/")[1];//先按照预设目标溶液浓度的单位标准 - const converActVol = volumeConverter.convert(actVol + actSolutionVolumeUnit, targetStartVolUnit) - const converActDiluentVolume1 = volumeConverter.convert(actStartSolutionVolume + actStartSolutionVolumeUnit, targetStartVolUnit) - const converArr = (targetAcSolution + '').split("/"); - converArr.map((item) => { - return convertConcentration.convert(item + initUnit, actSolutionConcentrationUnit) - }) + //计算并更新实际目标溶液浓度 先计算实际目标溶液体积再计算实际目标溶液浓度 + updateSjmbrynd(item, targetAcSolution, params) { + return this.calcNd(item, targetAcSolution, params) + }, + //更新起始溶液体积时,计算预设起始溶液体积和预设稀释液体积 + updateTargetStartSolutionVolume(item, volume, unitParams) { + const { rowIndex } = item + const { + subTargetStartSolution, + headerSelectFields, + dataSource = [] + } = unitParams + const { + targetSolutionConcentrationUnit, + targetSolutionVolumeUnit, + targetStartSolutionVolumeUnit, + targetDiluentVolumeUnit + } = headerSelectFields - // const converTargetAcSolution = convertConcentration.convert(targetAcSolution + initUnit, actSolutionConcentrationUnit) - // 实际目标溶液浓度 = 实际源溶液浓度÷(实际终体积÷源溶液加入体积); - // const actNd = ( - // parseFloat(converTargetAcSolution) / ( - // parseFloat(converActVol) / parseFloat(converActDiluentVolume1) - // ) - // ).toFixed(precision) - const actNdArr = converArr.map((item) => { - return parseFloat((item / (converActVol / converActDiluentVolume1) - ).toFixed(precision)) - }) - // const nd = actNd === 'Infinity' ? 0 : Number(actNd) - console.log(actNdArr, targetAcSolution, actStartSolutionVolume, actVol, "actNd") - // item.actSolutionConcentration = actNd === 'Infinity' ? 0 : actNd - return { actVol: Number(actVol), actNd: actNdArr.join("/") } - }, + let initNd = volume, + unit = subTargetStartSolution + //平行配制不会传dataSource; + if (rowIndex > 0 && dataSource.length > 0) { + initNd = dataSource[rowIndex - 1].targetSolutionConcentration + unit = targetSolutionConcentrationUnit + } + const precision = item.targetStartSolutionVolumePrecision || 0 + const precision1 = item.targetDiluentVolumePrecision || 0 + const concentration = item.targetSolutionConcentration + const targetVolume = item.targetSolutionVolume + if ( + isValueEmpty(concentration) || + isValueEmpty(targetVolume) || + isValueEmpty(unit) || + isValueEmpty(targetSolutionConcentrationUnit) || + isValueEmpty(targetSolutionVolumeUnit) || + isValueEmpty(targetStartSolutionVolumeUnit) || + isValueEmpty(targetDiluentVolumeUnit) + ) { + return + } + const targetStartVolUnit = targetSolutionConcentrationUnit.split('/')[1] //先按照预设目标溶液浓度的单位标准 + //将预设目标溶液体积转换为和预设目标溶液浓度单位的分母一样的单位再计算;如:预设目标溶液浓度单位为mg/mL,预设目标溶液体积单位为uL,则将预设目标溶液体积转换为mL + const convertTargetVol = volumeConverter.convert( + targetVolume + targetSolutionVolumeUnit, + targetStartVolUnit + ) + const convertTargetVol1 = volumeConverter.convert( + targetVolume + targetSolutionVolumeUnit, + targetStartSolutionVolumeUnit + ) - //计算并更新实际目标溶液浓度 先计算实际目标溶液体积再计算实际目标溶液浓度 - updateSjmbrynd(item, targetAcSolution, params) { - return this.calcNd(item, targetAcSolution, params) - }, - //更新起始溶液体积时,计算预设起始溶液体积和预设稀释液体积 - updateTargetStartSolutionVolume(item, volume, unitParams) { - const { rowIndex } = item - const { subTargetStartSolution, headerSelectFields, dataSource = [] } = unitParams - const { targetSolutionConcentrationUnit, targetSolutionVolumeUnit, targetStartSolutionVolumeUnit, targetDiluentVolumeUnit } = headerSelectFields - - let initNd = volume, unit = subTargetStartSolution; - //平行配置不会传dataSource; - if (rowIndex > 0 && dataSource.length > 0) { - initNd = dataSource[rowIndex - 1].targetSolutionConcentration; - unit = targetSolutionConcentrationUnit; - } - const precision = item.targetStartSolutionVolumePrecision || 0 - const precision1 = item.targetDiluentVolumePrecision || 0; - const concentration = item.targetSolutionConcentration - const targetVolume = item.targetSolutionVolume - if ( - isValueEmpty(concentration) || - isValueEmpty(targetVolume) || - isValueEmpty(unit) || - isValueEmpty(targetSolutionConcentrationUnit) || - isValueEmpty(targetSolutionVolumeUnit) || - isValueEmpty(targetStartSolutionVolumeUnit) || - isValueEmpty(targetDiluentVolumeUnit) - ) { - return; - } - const targetStartVolUnit = targetSolutionConcentrationUnit.split("/")[1];//先按照预设目标溶液浓度的单位标准 - //将预设目标溶液体积转换为和预设目标溶液浓度单位的分母一样的单位再计算;如:预设目标溶液浓度单位为mg/mL,预设目标溶液体积单位为uL,则将预设目标溶液体积转换为mL - const convertTargetVol = volumeConverter.convert(targetVolume + targetSolutionVolumeUnit, targetStartVolUnit) - const convertTargetVol1 = volumeConverter.convert(targetVolume + targetSolutionVolumeUnit, targetStartSolutionVolumeUnit) - - const initNdArr = (initNd + '').split("/"); - const transNdArr = initNdArr.map((con) => { - return convertConcentration.convert(con + unit, targetSolutionConcentrationUnit) - }) - const mbyjndArr = (concentration + '').split("/");//目标预计浓度 - if (mbyjndArr.length !== initNdArr.length) { - this.$message.error("起始溶液浓度和目标溶液浓度格式不一致,请重新输入") - return - } - //预设体积 - const ystjArr = mbyjndArr.map((con, index) => { - const ystj = Number((con * convertTargetVol) / (transNdArr[index] || transNdArr[0])) - const convertYsVol = volumeConverter.convert(ystj + targetStartVolUnit, targetStartSolutionVolumeUnit) - const xstj = (convertTargetVol1 - convertYsVol)//稀释体积 - return { qsrytj: convertYsVol, xstj } - }) - if (ystjArr.length > 0) { - const firstItem = ystjArr[0];//只取第一个计算 - item.targetStartSolutionVolume = Number((firstItem.qsrytj).toFixed(precision)); - item.targetDiluentVolume = Number((volumeConverter.convert(firstItem.xstj + targetStartSolutionVolumeUnit, targetDiluentVolumeUnit)).toFixed(precision1)); - } - - - }, - // 导出excel模板 - exportExcel(headerArray, title = '导出模板') { - this.$modal.loading() - const ws = XLSX.utils.aoa_to_sheet([headerArray]); - const colWidths = headerArray.map(cell => getStringWidth(cell) + 2); - ws['!cols'] = colWidths.map(width => ({ wch: width })); - const wb = XLSX.utils.book_new(); - XLSX.utils.book_append_sheet(wb, ws, 'Sheet1'); - XLSX.writeFile(wb, `${title}.xlsx`); - this.$modal.closeLoading() - }, - - } + const initNdArr = (initNd + '').split('/') + const transNdArr = initNdArr.map((con) => { + return convertConcentration.convert( + con + unit, + targetSolutionConcentrationUnit + ) + }) + const mbyjndArr = (concentration + '').split('/') //目标预计浓度 + if (mbyjndArr.length !== initNdArr.length) { + this.$message.error('起始溶液浓度和目标溶液浓度格式不一致,请重新输入') + return + } + //预设体积 + const ystjArr = mbyjndArr.map((con, index) => { + const ystj = Number( + (con * convertTargetVol) / (transNdArr[index] || transNdArr[0]) + ) + const convertYsVol = volumeConverter.convert( + ystj + targetStartVolUnit, + targetStartSolutionVolumeUnit + ) + const xstj = convertTargetVol1 - convertYsVol //稀释体积 + return { qsrytj: convertYsVol, xstj } + }) + if (ystjArr.length > 0) { + const firstItem = ystjArr[0] //只取第一个计算 + item.targetStartSolutionVolume = Number( + firstItem.qsrytj.toFixed(precision) + ) + item.targetDiluentVolume = Number( + volumeConverter + .convert( + firstItem.xstj + targetStartSolutionVolumeUnit, + targetDiluentVolumeUnit + ) + .toFixed(precision1) + ) + } + }, + // 导出excel模板 + exportExcel(headerArray, title = '导出模板') { + this.$modal.loading() + const ws = XLSX.utils.aoa_to_sheet([headerArray]) + const colWidths = headerArray.map((cell) => getStringWidth(cell) + 2) + ws['!cols'] = colWidths.map((width) => ({ wch: width })) + const wb = XLSX.utils.book_new() + XLSX.utils.book_append_sheet(wb, ws, 'Sheet1') + XLSX.writeFile(wb, `${title}.xlsx`) + this.$modal.closeLoading() + } + } } diff --git a/src/views/business/study/comp/tbbd/Xq.vue b/src/views/business/study/comp/tbbd/Xq.vue index 9cb2402..3f6ce25 100644 --- a/src/views/business/study/comp/tbbd/Xq.vue +++ b/src/views/business/study/comp/tbbd/Xq.vue @@ -362,7 +362,7 @@ export default { this.$modal.loading() // 1. 使用 html2pdf 手动构建 PDF,并获取底层的 jsPDF 实例 const pdf = await html2pdf() - .set(options) // 应用你的配置选项 + .set(options) // 应用你的配制选项 .from(pdfContent) // 指定 PDF 内容 .toPdf() // 转换为 PDF .get('pdf'); // 获取 jsPDF 实例 diff --git a/src/views/business/template/list.vue b/src/views/business/template/list.vue index 940812d..6922030 100644 --- a/src/views/business/template/list.vue +++ b/src/views/business/template/list.vue @@ -163,7 +163,7 @@ :placeholder="$t('form.placeholderSelect')" style="width:100%"> - + @@ -332,7 +332,7 @@ export default { bdpz(row) { this.saveSimpleLog({ name: row.name + '(' + row.showSn + ')', nameEn: row.name + '(' + row.showSn + ')', jcmc: '模板详情', jcmcEn: 'Function Detail' }) - this.tableDialog.title = '表单配置' + this.tableDialog.title = '表单配制' this.tableDialog.sn = row.sn this.tableDialog.templateData.bdmc =this.$i18n.locale === 'zh_CN'? row.name:row.nameEn this.tableDialog.templateData.templateId = row.id diff --git a/src/views/lblh/components/AutoSaveTextarea.vue b/src/views/lblh/components/AutoSaveTextarea.vue index 204d0fc..6fef04d 100644 --- a/src/views/lblh/components/AutoSaveTextarea.vue +++ b/src/views/lblh/components/AutoSaveTextarea.vue @@ -163,7 +163,7 @@ export default { type: String, default: '请输入内容...' }, - // 服务器配置 + // 服务器配制 serverConfig: { type: Object, default: () => ({}) diff --git a/src/views/lblh/index.vue b/src/views/lblh/index.vue index 1749672..ae07f8e 100644 --- a/src/views/lblh/index.vue +++ b/src/views/lblh/index.vue @@ -44,7 +44,7 @@

云端同步

1.失败操作加入离线队列

2.网络恢复时自动重试

-

3.失败重试策略(可配置重试等待延迟,以及重试次数,避免太多请求,造成服务器压力过大)

+

3.失败重试策略(可配制重试等待延迟,以及重试次数,避免太多请求,造成服务器压力过大)

+ diff --git a/src/views/system/dict/data.vue b/src/views/system/dict/data.vue index ee47cff..8b644d4 100644 --- a/src/views/system/dict/data.vue +++ b/src/views/system/dict/data.vue @@ -146,7 +146,7 @@ @pagination="getList" /> - + diff --git a/src/views/system/dict/index.vue b/src/views/system/dict/index.vue index 7b7adb3..5d60b8a 100644 --- a/src/views/system/dict/index.vue +++ b/src/views/system/dict/index.vue @@ -162,7 +162,7 @@ @pagination="getList" /> - + diff --git a/src/views/system/role/index.vue b/src/views/system/role/index.vue index 9e8ecf8..9c03ea9 100644 --- a/src/views/system/role/index.vue +++ b/src/views/system/role/index.vue @@ -198,7 +198,7 @@ @pagination="getList" /> - + diff --git a/src/views/system/user/index.vue b/src/views/system/user/index.vue index 9fd63fc..d4b42b3 100644 --- a/src/views/system/user/index.vue +++ b/src/views/system/user/index.vue @@ -136,7 +136,7 @@ - + diff --git a/src/views/tool/gen/index.vue b/src/views/tool/gen/index.vue index 79e8dcd..1cd3c55 100644 --- a/src/views/tool/gen/index.vue +++ b/src/views/tool/gen/index.vue @@ -314,7 +314,7 @@ export default { const tableId = row.tableId || this.ids[0] const tableName = row.tableName || this.tableNames[0] const params = { pageNum: this.queryParams.pageNum } - this.$tab.openPage("修改[" + tableName + "]生成配置", '/tool/gen-edit/index/' + tableId, params) + this.$tab.openPage("修改[" + tableName + "]生成配制", '/tool/gen-edit/index/' + tableId, params) }, /** 删除按钮操作 */ handleDelete(row) {