Browse Source

feat:[模板管理][update]

luojie
luojie 4 weeks ago
parent
commit
45bca77e7f
8 changed files with 121 additions and 90 deletions
  1. +5
    -0
      src/components/Template/BaseInfoFormPackage.vue
  2. +17
    -6
      src/components/Template/CustomTable.vue
  3. +1
    -0
      src/components/Template/HandleFormItem.vue
  4. +14
    -2
      src/components/Template/mixins/operationMixins.js
  5. +79
    -78
      src/views/business/comps/template/comps/dl/DL022.vue
  6. +1
    -1
      src/views/business/comps/template/comps/sp/SP003.vue
  7. +2
    -3
      src/views/business/comps/template/comps/yp/YP005.vue
  8. +2
    -0
      src/views/business/comps/template/mixins/templateMixin.js

+ 5
- 0
src/components/Template/BaseInfoFormPackage.vue View File

@ -107,9 +107,11 @@
<span v-if="sItem.subType === 'text'" class="sub-text">{{ $t(sItem.subText) }}</span> <span v-if="sItem.subType === 'text'" class="sub-text">{{ $t(sItem.subText) }}</span>
<HandleFormItem class="ml-10" v-else-if="sItem.subType === 'button'" type="button" <HandleFormItem class="ml-10" v-else-if="sItem.subType === 'button'" type="button"
:item="getButtonItem(sItem)" :value="formFields[sItem.subKey]" :item="getButtonItem(sItem)" :value="formFields[sItem.subKey]"
:field-key="prefixKey + '_' + sItem.subKey"
@clickButton="(e, val, data) => handleClickButton(e, sItem, val, data, sItem.subKey)" /> @clickButton="(e, val, data) => handleClickButton(e, sItem, val, data, sItem.subKey)" />
<HandleFormItem class="ml-10" v-else-if="sItem.thirdType === 'button'" type="button" <HandleFormItem class="ml-10" v-else-if="sItem.thirdType === 'button'" type="button"
:item="getThirdButtonItem(sItem)" :value="formFields[sItem.thirdKey]" :item="getThirdButtonItem(sItem)" :value="formFields[sItem.thirdKey]"
:field-key="prefixKey + '_' + sItem.thirdKey"
@clickButton="(e, val, data) => handleClickButton(e, sItem, val, data, sItem.thirdKey)" /> @clickButton="(e, val, data) => handleClickButton(e, sItem, val, data, sItem.thirdKey)" />
</div> </div>
@ -255,6 +257,7 @@
<div v-else-if="sItem.subType === 'button'"> <div v-else-if="sItem.subType === 'button'">
<HandleFormItem class="ml-10" type="button" :item="getButtonItem(sItem)" <HandleFormItem class="ml-10" type="button" :item="getButtonItem(sItem)"
:value="formFields[sItem.subKey]" :value="formFields[sItem.subKey]"
:field-key="prefixKey + '_' + sItem.subKey"
@clickButton="(e, val, data) => handleClickButton(e, sItem, val, data, sItem.subKey)" /> @clickButton="(e, val, data) => handleClickButton(e, sItem, val, data, sItem.subKey)" />
</div> </div>
@ -276,6 +279,7 @@
<div v-if="isShowSub(sItem,'thirdType')"> <div v-if="isShowSub(sItem,'thirdType')">
<HandleFormItem class="ml-10" v-if="sItem.thirdType === 'button'" type="button" <HandleFormItem class="ml-10" v-if="sItem.thirdType === 'button'" type="button"
:item="getThirdButtonItem(sItem)" :value="formFields[sItem.thirdKey]" :item="getThirdButtonItem(sItem)" :value="formFields[sItem.thirdKey]"
:field-key="prefixKey + '_' + sItem.thirdKey"
@clickButton="(e, val, data) => handleClickButton(e, sItem, val, data, sItem.thirdKey)" /> @clickButton="(e, val, data) => handleClickButton(e, sItem, val, data, sItem.thirdKey)" />
</div> </div>
<div v-show="isShowOther(formFields[sItem.subKey])" class="flex flex1 ml-10"> <div v-show="isShowOther(formFields[sItem.subKey])" class="flex flex1 ml-10">
@ -324,6 +328,7 @@
:orange-bg="orangeBgFields[sItem.thirdKey]" /> :orange-bg="orangeBgFields[sItem.thirdKey]" />
<HandleFormItem class="ml-10" v-if="sItem.fourthType === 'button'" type="button" <HandleFormItem class="ml-10" v-if="sItem.fourthType === 'button'" type="button"
:item="getFourthButtonItem(sItem)" :value="formFields[sItem.fourthKey]" :item="getFourthButtonItem(sItem)" :value="formFields[sItem.fourthKey]"
:field-key="prefixKey + '_' + sItem.fourthKey"
@clickButton="(e, val, data) => handleClickButton(e, sItem, val, data, sItem.fourthKey)" /> @clickButton="(e, val, data) => handleClickButton(e, sItem, val, data, sItem.fourthKey)" />
</div> </div>

+ 17
- 6
src/components/Template/CustomTable.vue View File

@ -98,6 +98,7 @@
@blur="onBlur(rowIndex, col.prop, $event)" @copy="onCopy(rowIndex, col)" @blur="onBlur(rowIndex, col.prop, $event)" @copy="onCopy(rowIndex, col)"
class="body-input" :item="getBodyItem(col, rowIndex)" class="body-input" :item="getBodyItem(col, rowIndex)"
v-model="row[col.prop]" v-model="row[col.prop]"
:ref = "col.prop+rowIndex"
@change="onBodyValueChange(rowIndex, colIndex, $event, row, col.bodyType)" @change="onBodyValueChange(rowIndex, colIndex, $event, row, col.bodyType)"
:error="hasError(rowIndex, colIndex, col.prop)" :error="hasError(rowIndex, colIndex, col.prop)"
@update:error="onErrorUpdate(rowIndex, colIndex, col.prop, $event)" @update:error="onErrorUpdate(rowIndex, colIndex, col.prop, $event)"
@ -208,6 +209,7 @@
:fieldItemLabel="fieldItemLabel" :type="col.bodySubType" :fieldItemLabel="fieldItemLabel" :type="col.bodySubType"
@blur="onSubBlur(rowIndex, col.bodySubKey, $event)" @blur="onSubBlur(rowIndex, col.bodySubKey, $event)"
@copy="onCopy(rowIndex, col)" :item="getBodySubItem(col)" @copy="onCopy(rowIndex, col)" :item="getBodySubItem(col)"
v-model="row[col.bodySubKey]" v-model="row[col.bodySubKey]"
@change="onBodySubValueChange(rowIndex, colIndex, $event, row, col.bodySubType)" @change="onBodySubValueChange(rowIndex, colIndex, $event, row, col.bodySubType)"
:error="hasError(rowIndex, colIndex, col.bodySubKey)" :error="hasError(rowIndex, colIndex, col.bodySubKey)"
@ -222,7 +224,7 @@
<template v-else-if="col.bodySubType === 'button'"> <template v-else-if="col.bodySubType === 'button'">
<HandleFormItem class="ml-10" type="button" :item="getBodyButtonItem(col, rowIndex)" <HandleFormItem class="ml-10" type="button" :item="getBodyButtonItem(col, rowIndex)"
:value="row[col.bodySubKey]" :value="row[col.bodySubKey]"
@clickButton="(e, data) => handleClickButton(e, data, col.bodySubKey, rowIndex, colIndex)" />
@clickButton="(e,val, data) => handleClickButton(e, data, col.bodySubKey, rowIndex, colIndex)" />
</template> </template>
<div class="flex flex1" v-else-if="isRegent(col, 'bodySubType')"> <div class="flex flex1" v-else-if="isRegent(col, 'bodySubType')">
<HandleFormItem :fieldKey="prefixKey + '_' + col.bodySubKey + '_' + row.id" <HandleFormItem :fieldKey="prefixKey + '_' + col.bodySubKey + '_' + row.id"
@ -238,7 +240,7 @@
<template v-if="col.bodyThirdType === 'button'"> <template v-if="col.bodyThirdType === 'button'">
<HandleFormItem class="ml-10" type="button" :item="getBodyThirdButtonItem(col, rowIndex)" <HandleFormItem class="ml-10" type="button" :item="getBodyThirdButtonItem(col, rowIndex)"
:value="row[col.bodyThirdKey]" :value="row[col.bodyThirdKey]"
@clickButton="(e, data) => handleClickButton(e, data, col.bodyThirdKey, rowIndex, colIndex)" />
@clickButton="(e,val, data) => handleClickButton(e, data, col.bodyThirdKey, rowIndex, colIndex)" />
</template> </template>
</div> </div>
</div> </div>
@ -523,7 +525,6 @@ export default {
}, },
// //
handleClickable(col, rowIndex, colIndex, row) { handleClickable(col, rowIndex, colIndex, row) {
console.log("clickable", rowIndex, colIndex, col, row)
if (this.templateFillType !== 'actFill') { if (this.templateFillType !== 'actFill') {
return return
} }
@ -537,7 +538,6 @@ export default {
}, },
onHeaderRegentSubmit(data, inputValue, colIndex, headerIndex) { onHeaderRegentSubmit(data, inputValue, colIndex, headerIndex) {
this.headerFields[`${colIndex}_${headerIndex}`] = inputValue; this.headerFields[`${colIndex}_${headerIndex}`] = inputValue;
console.log("onHeaderRegentSubmit", data, inputValue, colIndex, headerIndex, this.headerFields)
this.$emit("onHeaderRegentSubmit", { selectInfo: data, headerIndex, colIndex, headerFields: this.headerFields }) this.$emit("onHeaderRegentSubmit", { selectInfo: data, headerIndex, colIndex, headerFields: this.headerFields })
}, },
@ -938,7 +938,7 @@ export default {
item.checkboxLabel = this.$t(col.checkboxLabel); item.checkboxLabel = this.$t(col.checkboxLabel);
} }
if (col.bodyType === "operableInput" ) { if (col.bodyType === "operableInput" ) {
if(currentItem.isComplete){
if(currentItem.isComplete || this.templateFillType !== 'actFill'){
item.disabled = true; item.disabled = true;
}else{ }else{
item.disabled = false; item.disabled = false;
@ -1017,10 +1017,21 @@ export default {
this.checkCompareToOnDataLoad(); this.checkCompareToOnDataLoad();
}, },
// autoUpdateRecord // autoUpdateRecord
updateDataSourceByRowIndex(rowIndex, data) {
updateDataSourceByRowIndex(rowIndex, data,updateFieldsInfo={}) {
const {signData,updateFields = []} = updateFieldsInfo;
this.oldLocalDataSource = JSON.parse(JSON.stringify(this.localDataSource)); this.oldLocalDataSource = JSON.parse(JSON.stringify(this.localDataSource));
this.localDataSource[rowIndex] = { ...this.localDataSource[rowIndex], ...data }; this.localDataSource[rowIndex] = { ...this.localDataSource[rowIndex], ...data };
this.localDataSource = [...this.localDataSource]; this.localDataSource = [...this.localDataSource];
console.log(signData,"signData")
if(signData && signData.remark){
updateFields.map((key)=>{
const ref = this.$refs[key+rowIndex];
if(ref){
ref[0].handleUpdateRecord(signData, { oldValue: this.oldLocalDataSource[rowIndex][key], inputValue: data[key] });
}
})
}
this.checkCompareToOnDataLoad(); this.checkCompareToOnDataLoad();
// justUpdateFilledFormData(); // justUpdateFilledFormData();
}, },

+ 1
- 0
src/components/Template/HandleFormItem.vue View File

@ -6,6 +6,7 @@
<el-input <el-input
v-if="type === 'input'" :maxlength="item.maxlength || 50" :disabled="getDisabled()" v-if="type === 'input'" :maxlength="item.maxlength || 50" :disabled="getDisabled()"
:class="getFillTypeStyle() + (orangeBg ? ' orange-bg' : '')" @blur="onBlur" :class="getFillTypeStyle() + (orangeBg ? ' orange-bg' : '')" @blur="onBlur"
type = "textarea" :autosize="{ minRows: 1, maxRows: 6 }" resize = "none"
:placeholder="getPlaceholder()" v-model="inputValue" @input="onInputChange" @change="onInputChange" /> :placeholder="getPlaceholder()" v-model="inputValue" @input="onInputChange" @change="onInputChange" />
<el-input v-else-if="type === 'textarea'" :maxlength="item.maxlength || 1000" :disabled="getDisabled()" <el-input v-else-if="type === 'textarea'" :maxlength="item.maxlength || 1000" :disabled="getDisabled()"
:class="getFillTypeStyle() + (orangeBg ? ' orange-bg' : '')" type="textarea" show-word-limit :class="getFillTypeStyle() + (orangeBg ? ' orange-bg' : '')" type="textarea" show-word-limit

+ 14
- 2
src/components/Template/mixins/operationMixins.js View File

@ -63,9 +63,21 @@ export default {
}, },
// 删除行 // 删除行
deleteRow(index) { deleteRow(index) {
const { columnsData } = this.columns;
const { row } = this;
const filledRowData = {};
columnsData.map((item) => {
filledRowData[item.prop] = row[item.prop];
if (item.bodySubKey && (item.bodySubType !== "button")) {
filledRowData[item.bodySubKey] = row[item.bodySubKey];
}
if (item.otherCode) {
filledRowData[item.otherCode] = row[item.otherCode];
}
})
const isFilled = Object.values(filledRowData).every((item) => !!item);
this.deleteIndex = index; this.deleteIndex = index;
if (this.templateFillType === "actFill") {
if (this.templateFillType === "actFill" && isFilled) {
EventBus.$emit('showEditSignDialog', { uuid: this.uuid }); EventBus.$emit('showEditSignDialog', { uuid: this.uuid });
} else { } else {
this.sureDelete(); this.sureDelete();

+ 79
- 78
src/views/business/comps/template/comps/dl/DL022.vue View File

@ -14,19 +14,20 @@
<!-- 观察情况 --> <!-- 观察情况 -->
<div class="template-form-item"> <div class="template-form-item">
<BaseInfoFormPackage ref="swypyjInfoRef" fieldItemLabel="template.common.operationSteps" <BaseInfoFormPackage ref="swypyjInfoRef" fieldItemLabel="template.common.operationSteps"
:formConfig="stepFormConfig" @blur="onHandleBlur"
:formData="formData" @onRegentSubmit="onRegentSubmit" />
:formConfig="stepFormConfig" @blur="onHandleBlur" :formData="formData"
@onRegentSubmit="onRegentSubmit" />
<div style="color:#999;font-size:14px;"> <div style="color:#999;font-size:14px;">
畸变类型以代号填写断片(b)裂隙(g)互换及射体(t)环状染色体(r)多倍体(p)双着丝点染色体(d)内复制(e)染色体碎化(z)缺失(l)粘着(s)微小体(m) 畸变类型以代号填写断片(b)裂隙(g)互换及射体(t)环状染色体(r)多倍体(p)双着丝点染色体(d)内复制(e)染色体碎化(z)缺失(l)粘着(s)微小体(m)
</div> </div>
<CustomTable :ref="`tableRef`" :columns="tableColumns" :formData="tableFormData" <CustomTable :ref="`tableRef`" :columns="tableColumns" :formData="tableFormData"
operationWidth="120px" :prefixKey="`table`" fieldItemLabel="template.dl.dl022.jbqk" operationWidth="120px" :prefixKey="`table`" fieldItemLabel="template.dl.dl022.jbqk"
@onAddRow = "onAddRow" @blur="handleClickButton"
:showAddRow="fillType === 'actFill'" :showOperation="fillType === 'actFill'">
@onAddRow="onAddRow" @blur="handleClickButton" :showAddRow="fillType === 'actFill'"
:showOperation="fillType === 'actFill'">
<template slot="operation" slot-scope="{ row, rowIndex, columns }"> <template slot="operation" slot-scope="{ row, rowIndex, columns }">
<TableOpertaionDelete :row="row" :rowIndex="rowIndex" :columns="columns" <TableOpertaionDelete :row="row" :rowIndex="rowIndex" :columns="columns"
@deleteRow="deleteRow"></TableOpertaionDelete> @deleteRow="deleteRow"></TableOpertaionDelete>
<button v-if="fillType === 'actFill'" class="edit-button" @click="onEditClick(row, rowIndex)">
<button v-if="fillType === 'actFill'" class="edit-button"
@click="onEditClick(row, rowIndex)">
{{ row.isComplete ? '编辑' : '完成' }} {{ row.isComplete ? '编辑' : '完成' }}
</button> </button>
</template> </template>
@ -66,13 +67,13 @@ export default {
}, },
}, },
computed: { computed: {
//
tableFormData() {
return {
stepTableFormData: this.formData.stepTableFormData || [],
headerSelectFields: {}
}
},
//
tableFormData() {
return {
stepTableFormData: this.formData.stepTableFormData || [],
headerSelectFields: {}
}
},
// //
remarkConig() { remarkConig() {
return [ return [
@ -175,7 +176,7 @@ export default {
bodyFillType: 'actFill', bodyFillType: 'actFill',
width: 200, width: 200,
disabled: true, disabled: true,
bodyDisabled: true,
bodyDisabled: true,
}, { }, {
label: 'template.dl.dl022.lxjbs', label: 'template.dl.dl022.lxjbs',
prop: 'lxjbs', prop: 'lxjbs',
@ -183,7 +184,7 @@ export default {
bodyFillType: 'actFill', bodyFillType: 'actFill',
width: 200, width: 200,
disabled: true, disabled: true,
bodyDisabled: true,
bodyDisabled: true,
}, { }, {
label: 'template.dl.dl022.dbtjbs', label: 'template.dl.dl022.dbtjbs',
prop: 'dbtjbs', prop: 'dbtjbs',
@ -191,7 +192,7 @@ export default {
bodyFillType: 'actFill', bodyFillType: 'actFill',
width: 200, width: 200,
disabled: true, disabled: true,
bodyDisabled: true,
bodyDisabled: true,
}, { }, {
label: 'template.dl.dl022.nfzjbs', label: 'template.dl.dl022.nfzjbs',
prop: 'nfzjbs', prop: 'nfzjbs',
@ -199,7 +200,7 @@ export default {
bodyFillType: 'actFill', bodyFillType: 'actFill',
width: 200, width: 200,
disabled: true, disabled: true,
bodyDisabled: true,
bodyDisabled: true,
}, { }, {
label: 'template.dl.dl022.jblx', label: 'template.dl.dl022.jblx',
prop: 'jblx', prop: 'jblx',
@ -213,96 +214,96 @@ export default {
data() { data() {
return { return {
formData: {}, formData: {},
uuid:getuuid(),//id
currentItem: {},
currentRowIndex: -1,
uuid: getuuid(),//id
currentItem: {},
currentRowIndex: -1,
}; };
}, },
watch: {
watch: {
formData: { formData: {
immediate: true, immediate: true,
handler(v) { handler(v) {
console.log('formData==============',v);
console.log('formData==============', v);
} }
}, },
}, },
mounted() {
EventBus.$on('onEditSignCallback', this.handleEditSignCallback);
},
unmounted() {
mounted() {
EventBus.$on('onEditSignCallback', this.handleEditSignCallback);
},
unmounted() {
EventBus.$off('onEditSignCallback', this.handleEditSignCallback); EventBus.$off('onEditSignCallback', this.handleEditSignCallback);
}, },
methods: { methods: {
//
handleClickButton(e, rowIndex) {
console.log('formData==============',e,rowIndex,this.formData);
if(this.formData.stepTableFormData&&this.formData.stepTableFormData.length>0){
const list = this.formData.stepTableFormData;
list.map((item, index) => {
let jblxList = item.jblx;
if(jblxList&&jblxList.length>0){
item.jgjxjbs = this.calculateJgjxjbs(jblxList);
}
})
//
handleClickButton(e, rowIndex) {
console.log('formData==============', e, rowIndex, this.formData);
if (this.formData.stepTableFormData && this.formData.stepTableFormData.length > 0) {
const list = this.formData.stepTableFormData;
list.map((item, index) => {
let jblxList = item.jblx;
if (jblxList && jblxList.length > 0) {
item.jgjxjbs = this.calculateJgjxjbs(jblxList);
}
})
// 使 $set formData CustomTable
this.$set(this.formData, this.formData)
}
// 使 $set formData CustomTable
this.$set(this.formData, this.formData)
}
}, },
//
calculateJgjxjbs(jblxList,countCodes) {
if (!jblxList || jblxList.length === 0) return 0
//
// const countCodes = ['b', 't', 'r', 'd', 'z', 'l', 's', 'm']
//
calculateJgjxjbs(jblxList, countCodes) {
if (!jblxList || jblxList.length === 0) return 0
//
// const countCodes = ['b', 't', 'r', 'd', 'z', 'l', 's', 'm']
let count = 0
let count = 0
for (const it of jblxList) {
if (it.value) {
const val = String(it.value).toLowerCase()
// 1
for (const code of countCodes) {
if (val.includes(code)) {
count++
}
}
}
}
return count
},
handleEditSignCallback(data){
for (const it of jblxList) {
if (it.value) {
const val = String(it.value).toLowerCase()
// 1
for (const code of countCodes) {
if (val.includes(code)) {
count++
}
}
}
}
return count
},
handleEditSignCallback(data) {
if (data.uuid === this.uuid) { if (data.uuid === this.uuid) {
this.handleEdit(); this.handleEdit();
} }
}, },
handleEdit(){
const {currentItem, currentRowIndex} = this;
handleEdit() {
const { currentItem, currentRowIndex } = this;
currentItem.isComplete = !currentItem.isComplete; currentItem.isComplete = !currentItem.isComplete;
this.$refs.tableRef.updateDataSourceByRowIndex(currentRowIndex, currentItem) this.$refs.tableRef.updateDataSourceByRowIndex(currentRowIndex, currentItem)
}, },
// / // /
onEditClick(item, rowIndex) { onEditClick(item, rowIndex) {
const { jblx=[] } = item;
const { jblx = [] } = item;
const flag = jblx.every(it => !!it.value) const flag = jblx.every(it => !!it.value)
if(!item.isComplete && !flag){
if (!item.isComplete && !flag) {
this.$message.error('畸变类型还未填写完,请填写完成后再操作') this.$message.error('畸变类型还未填写完,请填写完成后再操作')
return return
} }
item.jgjxjbs = this.calculateJgjxjbs(jblx,['b', 't', 'r', 'd', 'z', 'l', 's', 'm'])
item.lxjbs = this.calculateJgjxjbs(jblx,['g'])
item.dbtjbs = this.calculateJgjxjbs(jblx,['p'])
item.nfzjbs = this.calculateJgjxjbs(jblx,['e'])
item.jgjxjbs = this.calculateJgjxjbs(jblx, ['b', 't', 'r', 'd', 'z', 'l', 's', 'm'])
item.lxjbs = this.calculateJgjxjbs(jblx, ['g'])
item.dbtjbs = this.calculateJgjxjbs(jblx, ['p'])
item.nfzjbs = this.calculateJgjxjbs(jblx, ['e'])
EventBus.$emit('showEditSignDialog', { uuid: this.uuid }); EventBus.$emit('showEditSignDialog', { uuid: this.uuid });
this.currentItem = item; this.currentItem = item;
this.currentRowIndex = rowIndex; this.currentRowIndex = rowIndex;
this.$refs.tableRef.updateDataSourceByRowIndex(rowIndex, item)
this.$refs.tableRef.updateDataSourceByRowIndex(rowIndex, item)
}, },
// //
onAddRow() { onAddRow() {
this.$refs.tableRef.addRow({ this.$refs.tableRef.addRow({
jblx: [{value: undefined}],
jblx: [{ value: undefined }],
}) })
}, },
onFormSelect(fields) { onFormSelect(fields) {
@ -386,14 +387,14 @@ export default {
} }
</script> </script>
<style rel="stylesheet/scss" lang="scss"> <style rel="stylesheet/scss" lang="scss">
.edit-button{
color: #409eff;
font-size: 13px;
border-radius: 3px;
padding: 5px 9px;
cursor: pointer;
border-color: transparent;
background: transparent;
margin: 0 0 5px 10px !important;
.edit-button {
color: #409eff;
font-size: 13px;
border-radius: 3px;
padding: 5px 9px;
cursor: pointer;
border-color: transparent;
background: transparent;
margin: 0 0 5px 10px !important;
} }
</style> </style>

+ 1
- 1
src/views/business/comps/template/comps/sp/SP003.vue View File

@ -277,7 +277,7 @@ export default {
bodySubType: "span", bodySubType: "span",
bodySubKey: "subTargetSolutionCode", bodySubKey: "subTargetSolutionCode",
bodyFillType: "preFill", bodyFillType: "preFill",
width: 140,
width: 280,
myCodeFields: ["targetSolutionCode", "subTargetSolutionCode"],// myCodeFields: ["targetSolutionCode", "subTargetSolutionCode"],//
maxVolumeField: "actSolutionVolume",// maxVolumeField: "actSolutionVolume",//
maxVolumeFieldUnit: "actSolutionVolumeUnit",// maxVolumeFieldUnit: "actSolutionVolumeUnit",//

+ 2
- 3
src/views/business/comps/template/comps/yp/YP005.vue View File

@ -206,7 +206,7 @@ export default {
timeArr[0] = startTime timeArr[0] = startTime
this.$refs.tableRef.updateDataSourceByRowIndex(rowIndex,{ this.$refs.tableRef.updateDataSourceByRowIndex(rowIndex,{
qxsj: timeArr.join('~'), qxsj: timeArr.join('~'),
})
},{signData:data,updateFields:['qxsj']})
// this.$nextTick(() => { // this.$nextTick(() => {
// // // //
@ -219,12 +219,11 @@ export default {
// }) // })
} }
if(key === "endBtn"){ if(key === "endBtn"){
debugger
let endTime = moment().format("YYYY/MM/DD HH:mm") let endTime = moment().format("YYYY/MM/DD HH:mm")
timeArr[1] = endTime timeArr[1] = endTime
this.$refs.tableRef.updateDataSourceByRowIndex(rowIndex,{ this.$refs.tableRef.updateDataSourceByRowIndex(rowIndex,{
qxsj: timeArr.join('~'), qxsj: timeArr.join('~'),
})
},{signData:data,updateFields:['qxsj']})
// this.$nextTick(() => { // this.$nextTick(() => {
// // // //

+ 2
- 0
src/views/business/comps/template/mixins/templateMixin.js View File

@ -581,7 +581,9 @@ export default {
} else { } else {
initNd = dataSource[rowIndex - 1].actSolutionConcentration; initNd = dataSource[rowIndex - 1].actSolutionConcentration;
} }
if (isValueEmpty(initNd)) { if (isValueEmpty(initNd)) {
console.log("initNd",initNd)
this.$message.error('请先选择起始源溶液') this.$message.error('请先选择起始源溶液')
return return
} else { } else {

Loading…
Cancel
Save