|
|
@ -40,6 +40,8 @@ |
|
|
</div> |
|
|
</div> |
|
|
<BaseInfoFormPackage fieldItemLabel="template.common.operationSteps" |
|
|
<BaseInfoFormPackage fieldItemLabel="template.common.operationSteps" |
|
|
:ref="`formZlConfigFormPackageRef_${zlIndex}`" :formConfig="formZlConfig" |
|
|
:ref="`formZlConfigFormPackageRef_${zlIndex}`" :formConfig="formZlConfig" |
|
|
|
|
|
@beforeReagentSubmit="(data) => onTableBeforeReagentZlSubmit(data, zlIndex, formZlConfig)" |
|
|
|
|
|
@onRegentSubmit="(data) => onTableRegentZlSubmit(zlIndex, data)" |
|
|
:formData="formzlConfig" /> |
|
|
:formData="formzlConfig" /> |
|
|
<Step class="mt-0 s-container" :ref="`formZlStepRef_${zlIndex}`" |
|
|
<Step class="mt-0 s-container" :ref="`formZlStepRef_${zlIndex}`" |
|
|
:formData="formzlConfig.stepData" :fieldItemLabel="$t('template.common.jtpz')" |
|
|
:formData="formzlConfig.stepData" :fieldItemLabel="$t('template.common.jtpz')" |
|
|
@ -66,6 +68,8 @@ |
|
|
</div> |
|
|
</div> |
|
|
<BaseInfoFormPackage fieldItemLabel="template.common.operationSteps" |
|
|
<BaseInfoFormPackage fieldItemLabel="template.common.operationSteps" |
|
|
:ref="`formRyConfigFormPackageRef_${ryIndex}`" :formConfig="formRyConfig" |
|
|
:ref="`formRyConfigFormPackageRef_${ryIndex}`" :formConfig="formRyConfig" |
|
|
|
|
|
@beforeReagentSubmit="(data) => onTableBeforeReagentRySubmit(data, ryIndex, formRyConfig)" |
|
|
|
|
|
@onRegentSubmit="(data) => onTableRegentRySubmit(ryIndex, data)" |
|
|
:formData="formryConfig" /> |
|
|
:formData="formryConfig" /> |
|
|
<Step class="mt-0 s-container" :ref="`formRyStepRef_${ryIndex}`" |
|
|
<Step class="mt-0 s-container" :ref="`formRyStepRef_${ryIndex}`" |
|
|
:formData="formryConfig.stepData" :fieldItemLabel="$t('template.common.jtpz')" |
|
|
:formData="formryConfig.stepData" :fieldItemLabel="$t('template.common.jtpz')" |
|
|
@ -95,6 +99,7 @@ import { EventBus } from "@/utils/eventBus"; |
|
|
import { uniqeResource } from "@/utils/calUnitTools"; |
|
|
import { uniqeResource } from "@/utils/calUnitTools"; |
|
|
import { debounce } from 'lodash-es' |
|
|
import { debounce } from 'lodash-es' |
|
|
import { duplicateResource, getExpireDate } from "@/utils/index.js"; |
|
|
import { duplicateResource, getExpireDate } from "@/utils/index.js"; |
|
|
|
|
|
import { isCommonUnit } from "@/utils/conTools"; |
|
|
|
|
|
|
|
|
export default { |
|
|
export default { |
|
|
name: "GSP005", |
|
|
name: "GSP005", |
|
|
@ -277,14 +282,14 @@ export default { |
|
|
pzkssj: { |
|
|
pzkssj: { |
|
|
label: 'template.gsp.GSP005.pzkssj', |
|
|
label: 'template.gsp.GSP005.pzkssj', |
|
|
type: "input", |
|
|
type: "input", |
|
|
bodyDisabled: true, |
|
|
|
|
|
|
|
|
disabled: true, |
|
|
fillType: "actFill", |
|
|
fillType: "actFill", |
|
|
maxlength: 20 |
|
|
maxlength: 20 |
|
|
}, |
|
|
}, |
|
|
pzjssj: { |
|
|
pzjssj: { |
|
|
label: 'template.gsp.GSP005.pzjssj', |
|
|
label: 'template.gsp.GSP005.pzjssj', |
|
|
type: "input", |
|
|
type: "input", |
|
|
bodyDisabled: true, |
|
|
|
|
|
|
|
|
disabled: true, |
|
|
fillType: "actFill", |
|
|
fillType: "actFill", |
|
|
maxlength: 20 |
|
|
maxlength: 20 |
|
|
}, |
|
|
}, |
|
|
@ -298,7 +303,7 @@ export default { |
|
|
sywzbhph: { |
|
|
sywzbhph: { |
|
|
label: 'template.gsp.GSP005.sywzbhph', |
|
|
label: 'template.gsp.GSP005.sywzbhph', |
|
|
type: "input", |
|
|
type: "input", |
|
|
subType: "input", |
|
|
|
|
|
|
|
|
subType: 'mix', |
|
|
subKey: "sywzbhphSub", |
|
|
subKey: "sywzbhphSub", |
|
|
fillType: "preFill", |
|
|
fillType: "preFill", |
|
|
subFillType: "actFill", |
|
|
subFillType: "actFill", |
|
|
@ -326,7 +331,8 @@ export default { |
|
|
subKey: "sywzyjclzUnit", |
|
|
subKey: "sywzyjclzUnit", |
|
|
fillType: "preFill", |
|
|
fillType: "preFill", |
|
|
subOptions: this.getDictOptions('business_zldw'), |
|
|
subOptions: this.getDictOptions('business_zldw'), |
|
|
maxlength: 10 |
|
|
|
|
|
|
|
|
maxlength: 10, |
|
|
|
|
|
selectTo: "sywzsjclzUnit",//下拉选择后,赋值到对应字段 |
|
|
}, |
|
|
}, |
|
|
sywzsjclz: { |
|
|
sywzsjclz: { |
|
|
label: 'template.gsp.GSP005.sywzsjclz', |
|
|
label: 'template.gsp.GSP005.sywzsjclz', |
|
|
@ -342,7 +348,7 @@ export default { |
|
|
label: 'template.gsp.GSP005.rjbhph', |
|
|
label: 'template.gsp.GSP005.rjbhph', |
|
|
type: "input", |
|
|
type: "input", |
|
|
fillType: "preFill", |
|
|
fillType: "preFill", |
|
|
subType: 'mix', |
|
|
|
|
|
|
|
|
subType: 'sj', |
|
|
subKey: 'rjbhphSub', |
|
|
subKey: 'rjbhphSub', |
|
|
subFillType: 'actFill', |
|
|
subFillType: 'actFill', |
|
|
maxlength: 20, |
|
|
maxlength: 20, |
|
|
@ -361,6 +367,7 @@ export default { |
|
|
fillType: "preFill", |
|
|
fillType: "preFill", |
|
|
subFillType: "preFill", |
|
|
subFillType: "preFill", |
|
|
subOptions: this.getDictOptions('business_tjdw'), |
|
|
subOptions: this.getDictOptions('business_tjdw'), |
|
|
|
|
|
selectTo: "rjsjtjUnit",//下拉选择后,赋值到对应字段 |
|
|
maxlength: 10 |
|
|
maxlength: 10 |
|
|
}, |
|
|
}, |
|
|
rjsjtj: { |
|
|
rjsjtj: { |
|
|
@ -457,14 +464,14 @@ export default { |
|
|
pzkssj: { |
|
|
pzkssj: { |
|
|
label: 'template.gsp.GSP005.pzkssj', |
|
|
label: 'template.gsp.GSP005.pzkssj', |
|
|
type: "input", |
|
|
type: "input", |
|
|
bodyDisabled: true, |
|
|
|
|
|
|
|
|
disabled: true, |
|
|
fillType: "actFill", |
|
|
fillType: "actFill", |
|
|
maxlength: 20 |
|
|
maxlength: 20 |
|
|
}, |
|
|
}, |
|
|
pzjssj: { |
|
|
pzjssj: { |
|
|
label: 'template.gsp.GSP005.pzjssj', |
|
|
label: 'template.gsp.GSP005.pzjssj', |
|
|
type: "input", |
|
|
type: "input", |
|
|
bodyDisabled: true, |
|
|
|
|
|
|
|
|
disabled: true, |
|
|
fillType: "actFill", |
|
|
fillType: "actFill", |
|
|
maxlength: 20 |
|
|
maxlength: 20 |
|
|
}, |
|
|
}, |
|
|
@ -478,7 +485,7 @@ export default { |
|
|
yrybhph: { |
|
|
yrybhph: { |
|
|
label: 'template.gsp.GSP005.yrybhph', |
|
|
label: 'template.gsp.GSP005.yrybhph', |
|
|
type: "input", |
|
|
type: "input", |
|
|
subType: "input", |
|
|
|
|
|
|
|
|
subType: 'mix', |
|
|
subKey: "yrybhphSub", |
|
|
subKey: "yrybhphSub", |
|
|
fillType: "preFill", |
|
|
fillType: "preFill", |
|
|
subFillType: "actFill", |
|
|
subFillType: "actFill", |
|
|
@ -501,6 +508,7 @@ export default { |
|
|
fillType: "preFill", |
|
|
fillType: "preFill", |
|
|
subFillType: "preFill", |
|
|
subFillType: "preFill", |
|
|
subOptions: this.getDictOptions('business_tjdw'), |
|
|
subOptions: this.getDictOptions('business_tjdw'), |
|
|
|
|
|
selectTo: "yrysjtjUnit",//下拉选择后,赋值到对应字段 |
|
|
maxlength: 10 |
|
|
maxlength: 10 |
|
|
}, |
|
|
}, |
|
|
yrysjtj: { |
|
|
yrysjtj: { |
|
|
@ -521,6 +529,7 @@ export default { |
|
|
fillType: "preFill", |
|
|
fillType: "preFill", |
|
|
subFillType: "preFill", |
|
|
subFillType: "preFill", |
|
|
subOptions: this.getDictOptions('business_nddw'), |
|
|
subOptions: this.getDictOptions('business_nddw'), |
|
|
|
|
|
selectTo: "yrysjndUnit",//下拉选择后,赋值到对应字段 |
|
|
maxlength: 10 |
|
|
maxlength: 10 |
|
|
}, |
|
|
}, |
|
|
yrysjnd: { |
|
|
yrysjnd: { |
|
|
@ -543,7 +552,7 @@ export default { |
|
|
label: 'template.gsp.GSP005.rjbhph', |
|
|
label: 'template.gsp.GSP005.rjbhph', |
|
|
type: "input", |
|
|
type: "input", |
|
|
fillType: "preFill", |
|
|
fillType: "preFill", |
|
|
subType: 'mix', |
|
|
|
|
|
|
|
|
subType: 'sj', |
|
|
subKey: 'rjbhphSub', |
|
|
subKey: 'rjbhphSub', |
|
|
subFillType: 'actFill', |
|
|
subFillType: 'actFill', |
|
|
maxlength: 20, |
|
|
maxlength: 20, |
|
|
@ -562,6 +571,7 @@ export default { |
|
|
fillType: "preFill", |
|
|
fillType: "preFill", |
|
|
subFillType: "preFill", |
|
|
subFillType: "preFill", |
|
|
subOptions: this.getDictOptions('business_tjdw'), |
|
|
subOptions: this.getDictOptions('business_tjdw'), |
|
|
|
|
|
selectTo: "rjsjtjUnit",//下拉选择后,赋值到对应字段 |
|
|
maxlength: 10 |
|
|
maxlength: 10 |
|
|
}, |
|
|
}, |
|
|
rjsjtj: { |
|
|
rjsjtj: { |
|
|
@ -604,6 +614,54 @@ export default { |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
methods: { |
|
|
methods: { |
|
|
|
|
|
// 溶液 |
|
|
|
|
|
onTableBeforeReagentRySubmit(data, zlIndex, formZlConfig) { |
|
|
|
|
|
const { selectData, callback, key, formFields } = data; |
|
|
|
|
|
//源溶剂编号/批号 |
|
|
|
|
|
if (key === "yrybhphSub" && !isCommonUnit(selectData.row.kcdw, [formFields.yrysjtjUnit])) { |
|
|
|
|
|
callback.prevent('库存单位与预制不符,请重新选择或申请废止并重新预制。'); |
|
|
|
|
|
} |
|
|
|
|
|
//溶剂编号/批号 |
|
|
|
|
|
if (key === "rjbhphSub" && !isCommonUnit(selectData.row.kcdw, [formFields.rjsjtjUnit])) { |
|
|
|
|
|
callback.prevent('库存单位与预制不符,请重新选择或申请废止并重新预制。'); |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
onTableRegentRySubmit(zlIndex, data) { |
|
|
|
|
|
if (data.key === 'yrybhphSub') { |
|
|
|
|
|
this.$refs[`formRyConfigFormPackageRef_${zlIndex}`][0].updateFormData('yrybhphSubType', data.selectInfo.selectType) |
|
|
|
|
|
this.$refs[`formRyConfigFormPackageRef_${zlIndex}`][0].updateFormData('yrybhphSubKcdw', data.selectInfo.row.kcdw) |
|
|
|
|
|
this.$refs[`formRyConfigFormPackageRef_${zlIndex}`][0].updateFormData('yrymc', data.selectInfo.row.mc) |
|
|
|
|
|
} |
|
|
|
|
|
if (data.key === 'rjbhphSub') { |
|
|
|
|
|
this.$refs[`formRyConfigFormPackageRef_${zlIndex}`][0].updateFormData('rjbhphSubType', data.selectInfo.selectType) |
|
|
|
|
|
this.$refs[`formRyConfigFormPackageRef_${zlIndex}`][0].updateFormData('rjbhphSubKcdw', data.selectInfo.row.kcdw) |
|
|
|
|
|
this.$refs[`formRyConfigFormPackageRef_${zlIndex}`][0].updateFormData('rjmc', data.selectInfo.row.mc) |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
// 质量 |
|
|
|
|
|
onTableBeforeReagentZlSubmit(data, zlIndex, formZlConfig) { |
|
|
|
|
|
const { selectData, callback, key, formFields } = data; |
|
|
|
|
|
//溶剂编号/批号 |
|
|
|
|
|
if (key === "rjbhphSub" && !isCommonUnit(selectData.row.kcdw, [formFields.rjsjtjUnit])) { |
|
|
|
|
|
callback.prevent('库存单位与预制不符,请重新选择或申请废止并重新预制。'); |
|
|
|
|
|
} |
|
|
|
|
|
//试验物质编号/批号 |
|
|
|
|
|
if (key === "sywzbhphSub" && !isCommonUnit(selectData.row.kcdw, [formFields.sywzsjclzUnit])) { |
|
|
|
|
|
callback.prevent('库存单位与预制不符,请重新选择或申请废止并重新预制。'); |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
onTableRegentZlSubmit(zlIndex, data) { |
|
|
|
|
|
if (data.key === 'sywzbhphSub') { |
|
|
|
|
|
this.$refs[`formZlConfigFormPackageRef_${zlIndex}`][0].updateFormData('sywzbhphSubType', data.selectInfo.selectType) |
|
|
|
|
|
this.$refs[`formZlConfigFormPackageRef_${zlIndex}`][0].updateFormData('sywzbhphSubKcdw', data.selectInfo.row.kcdw) |
|
|
|
|
|
this.$refs[`formZlConfigFormPackageRef_${zlIndex}`][0].updateFormData('sywzmcSub', data.selectInfo.row.mc) |
|
|
|
|
|
} |
|
|
|
|
|
if (data.key === 'rjbhphSub') { |
|
|
|
|
|
this.$refs[`formZlConfigFormPackageRef_${zlIndex}`][0].updateFormData('rjbhphSubType', data.selectInfo.selectType) |
|
|
|
|
|
this.$refs[`formZlConfigFormPackageRef_${zlIndex}`][0].updateFormData('rjbhphSubKcdw', data.selectInfo.row.kcdw) |
|
|
|
|
|
this.$refs[`formZlConfigFormPackageRef_${zlIndex}`][0].updateFormData('rjmc', data.selectInfo.row.mc) |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
//新增质量 |
|
|
//新增质量 |
|
|
handleAddFormZlConfig() { |
|
|
handleAddFormZlConfig() { |
|
|
if (!this.formData.formZlConfigs) { |
|
|
if (!this.formData.formZlConfigs) { |
|
|
|