diff --git a/src/components/Template/BaseInfoFormPackage.vue b/src/components/Template/BaseInfoFormPackage.vue
index 2d788eb..8301b69 100644
--- a/src/components/Template/BaseInfoFormPackage.vue
+++ b/src/components/Template/BaseInfoFormPackage.vue
@@ -466,22 +466,30 @@ export default {
},
// 获取按钮项
getThirdButtonItem(sItem) {
- return {
+ const o =
+ {
...sItem,
key: sItem.thirdKey,
- disabled: sItem.thirdDisabled,
buttonName: sItem.thirdButtonName,
fillType: sItem.thirdFillType || sItem.fillType
}
+ if(sItem.hasOwnProperty("thirdDisabled")){
+ o.disabled = sItem.thirdDisabled;
+ }
+ return o;
},
getFourthButtonItem(sItem) {
- return {
+ const o =
+ {
...sItem,
key: sItem.fourthKey,
buttonName: sItem.fourthButtonName,
- disabled: sItem.fourthDisabled,
fillType: sItem.fourthFillType || sItem.fillType
}
+ if(sItem.hasOwnProperty("fourthDisabled")){
+ o.disabled = sItem.fourthDisabled;
+ }
+ return o;
},
// 处理fqyq变化
onFqyqChange(key, e) {
diff --git a/src/components/Template/Step.vue b/src/components/Template/Step.vue
index 87effb0..39cd8d8 100644
--- a/src/components/Template/Step.vue
+++ b/src/components/Template/Step.vue
@@ -10,7 +10,7 @@
-
@@ -71,6 +72,14 @@ export default {
default: 'preFill',
},
},
+ provide() {
+ return {
+ getMybhByIndex: (index) => {
+ const data = this.$refs[`formConfigStepFormPackageRef_${index}`][0].getFilledFormData()
+ return { mybh: data.targetCode + data.targetCodeSn, maxVolume: data.targetActVolume, maxVolumeUnit: data.targetActVolumeUnit }
+ }
+ }
+ },
computed: {
// 配制条件
storageFormConfig() {
diff --git a/src/views/business/comps/template/comps/gsp/GSP001.vue b/src/views/business/comps/template/comps/gsp/GSP001.vue
index 9458edd..7a0b367 100644
--- a/src/views/business/comps/template/comps/gsp/GSP001.vue
+++ b/src/views/business/comps/template/comps/gsp/GSP001.vue
@@ -35,6 +35,7 @@
:formData="formConfig" />
@@ -70,6 +71,14 @@ export default {
default: 'preFill',
},
},
+ provide() {
+ return {
+ getMybhByIndex: (index) => {
+ const data = this.$refs[`formConfigStepFormPackageRef_${index}`][0].getFilledFormData()
+ return { mybh: data.targetCode + data.targetCodeSn, maxVolume: data.targetActVolume, maxVolumeUnit: data.targetActVolumeUnit }
+ }
+ }
+ },
computed: {
// 配制条件
storageFormConfig() {
@@ -156,7 +165,7 @@ export default {
label: 'template.common.actualFill',
type: "select",
fillType: "actFill",
- otherCode: "actOther",otherCodeCompareTo: "preOther",
+ otherCode: "actOther", otherCodeCompareTo: "preOther",
multiple: true,
compareTo: "pre",
options: this.getDictOptions('business_pztj')
@@ -327,8 +336,8 @@ export default {
for (let i = 0; i < this.formData.formConfigs.length; i++) {
const formData = this.$refs[`formConfigStepFormPackageRef_${i}`][0].getFilledFormData();
const stepData = this.$refs[`formStepRef_${i}`][0].getFilledFormData();
- if(this.formData.startDate&&formData.effectivePeriod&&formData.effectivePeriodUnit){
- formData.expireDate=getExpireDate(this.formData.startDate, formData.effectivePeriod, formData.effectivePeriodUnit)
+ if (this.formData.startDate && formData.effectivePeriod && formData.effectivePeriodUnit) {
+ formData.expireDate = getExpireDate(this.formData.startDate, formData.effectivePeriod, formData.effectivePeriodUnit)
}
formConfigsData.push({
...formData,
diff --git a/src/views/business/comps/template/comps/gsp/GSP003.vue b/src/views/business/comps/template/comps/gsp/GSP003.vue
index 6c2261d..098ba5b 100644
--- a/src/views/business/comps/template/comps/gsp/GSP003.vue
+++ b/src/views/business/comps/template/comps/gsp/GSP003.vue
@@ -41,6 +41,7 @@
:formData="formConfig" />
@@ -76,6 +77,14 @@ export default {
default: 'preFill',
},
},
+ provide() {
+ return {
+ getMybhByIndex: (index) => {
+ const data = this.$refs[`formConfigStepFormPackageRef_${index}`][0].getFilledFormData()
+ return { mybh: data.targetCode + data.targetCodeSn, maxVolume: data.targetActVolume, maxVolumeUnit: data.targetActVolumeUnit }
+ }
+ }
+ },
computed: {
// 计算公式
calcFormConfig() {
diff --git a/src/views/business/comps/template/comps/gsp/GSP005.vue b/src/views/business/comps/template/comps/gsp/GSP005.vue
index e04add6..43ef846 100644
--- a/src/views/business/comps/template/comps/gsp/GSP005.vue
+++ b/src/views/business/comps/template/comps/gsp/GSP005.vue
@@ -40,13 +40,13 @@
onTableBeforeReagentZlSubmit(data, zlIndex, formZlConfig)"
@onRegentSubmit="(data) => onTableRegentZlSubmit(zlIndex, data)"
- @clickButton="(data) => onClickButtonZl(zlIndex, data)"
- :formData="formzlConfig" />
+ @clickButton="(data) => onClickButtonZl(zlIndex, data)" :formData="formzlConfig" />
+ :formIndex="zlIndex" formType="formZl" :prefixKey="'form_' + zlIndex">
{{ $t('template.gsp.GSP005.jspz') }}
@@ -69,12 +69,13 @@
onTableBeforeReagentRySubmit(data, ryIndex, formRyConfig)"
@onRegentSubmit="(data) => onTableRegentRySubmit(ryIndex, data)"
:formData="formryConfig" />
+ :formIndex="ryIndex" formType="formRy" :prefixKey="'form_' + ryIndex">
{{ $t('template.gsp.GSP005.jspz') }}
@@ -113,6 +114,20 @@ export default {
default: 'preFill',
},
},
+ provide() {
+ return {
+ getMybhByIndex: (index, type) => {
+ if (type === 'formZl') {
+ const data = this.$refs[`formZlConfigFormPackageRef_${index}`][0].getFilledFormData()
+ return { mybh: data.targetCode + data.targetCodeSn, maxVolume: data.targetActVolume, maxVolumeUnit: data.targetActVolumeUnit }
+
+ } else {
+ const data = this.$refs[`formRyConfigFormPackageRef_${index}`][0].getFilledFormData()
+ return { mybh: data.targetCode + data.targetCodeSn, maxVolume: data.targetActVolume, maxVolumeUnit: data.targetActVolumeUnit }
+ }
+ }
+ }
+ },
computed: {
// 备注表单配制
remarkConig() {
@@ -181,7 +196,7 @@ export default {
label: 'template.common.actualFill',
type: "select",
fillType: "actFill",
- otherCode: "actOther",otherCodeCompareTo: "preOther",
+ otherCode: "actOther", otherCodeCompareTo: "preOther",
multiple: true,
compareTo: "pre",
options: this.getDictOptions('business_pztj')
@@ -352,7 +367,7 @@ export default {
fourthType: "button",
fourthKey: "sywzsjclzButtonValue",
fourthFillType: "actFill",
- fourthButtonName:"获取值",
+ fourthButtonName: "获取值",
isClearForm: true,
thirdOptions: this.getDictOptions('business_zldw'),
maxlength: 10
@@ -631,8 +646,8 @@ export default {
}
},
methods: {
- onClickButtonZl(zlIndex, data){
- this.$refs[`formZlConfigFormPackageRef_${zlIndex}`][0].updateFormData('sywzsjclzValue', 1)
+ onClickButtonZl(zlIndex, data) {
+ this.$refs[`formZlConfigFormPackageRef_${zlIndex}`][0].updateFormData('sywzsjclzValue', 1)
},
//溶液开始配制
ryKspz(zlIndex) {
@@ -701,7 +716,7 @@ export default {
callback.prevent('浓度单位与预制不符,请重新选择或申请废止并重新预制。');
}
//溶剂编号/批号
- if (key === "rjbhphSub" && selectData.row.kcdw!==formFields.rjsjtjUnit) {
+ if (key === "rjbhphSub" && selectData.row.kcdw !== formFields.rjsjtjUnit) {
callback.prevent('浓度单位与预制不符,请重新选择或申请废止并重新预制。');
}
},
@@ -724,7 +739,7 @@ export default {
const { selectData, callback, key, formFields } = data;
debugger
//溶剂编号/批号
- if (key === "rjbhphSub" && selectData.row.kcdw!==formFields.rjsjtjUnit) {
+ if (key === "rjbhphSub" && selectData.row.kcdw !== formFields.rjsjtjUnit) {
callback.prevent('库存单位与预制不符,请重新选择或申请废止并重新预制。');
}
//试验物质编号/批号
diff --git a/src/views/business/comps/template/comps/gsp/GSP010.vue b/src/views/business/comps/template/comps/gsp/GSP010.vue
index f586835..41ac26b 100644
--- a/src/views/business/comps/template/comps/gsp/GSP010.vue
+++ b/src/views/business/comps/template/comps/gsp/GSP010.vue
@@ -32,6 +32,7 @@
:formData="formConfig" />
@@ -67,6 +68,14 @@ export default {
default: 'preFill',
},
},
+ provide() {
+ return {
+ getMybhByIndex: (index) => {
+ const data = this.$refs[`formConfigStepFormPackageRef_${index}`][0].getFilledFormData()
+ return { mybh: data.targetCode + data.targetCodeSn, maxVolume: data.targetActVolume, maxVolumeUnit: data.targetActVolumeUnit }
+ }
+ }
+ },
computed: {
// 备注表单配制
remarkConig() {
diff --git a/src/views/business/comps/template/comps/lba/LBA002.vue b/src/views/business/comps/template/comps/lba/LBA002.vue
index f64075c..6ef86c2 100644
--- a/src/views/business/comps/template/comps/lba/LBA002.vue
+++ b/src/views/business/comps/template/comps/lba/LBA002.vue
@@ -60,6 +60,11 @@ export default {
default: 'preFill',
},
},
+ provide() {
+ return {
+ getJcbData:()=>this.$refs.tableRef.getFilledFormData()
+ }
+ },
computed: {
// 备注表单配制
remarkConig() {