[update] 国内标准新车型实施日期备注和在产车实施日期备注,修改新车型实施日期和在产车实施日期时同步更新这两个字段
This commit is contained in:
@@ -42,7 +42,7 @@ export default {
|
||||
this.checkedValue = []
|
||||
this.firstValue = null
|
||||
document.getElementById(this.fieldName).children[0].children[0].value = ''
|
||||
this.$emit('change', '')
|
||||
this.$emit('change', '', this.fieldName)
|
||||
} else {
|
||||
this.checkedValue = val.split(',')
|
||||
this.firstValue = this.checkedValue[0]
|
||||
@@ -105,7 +105,7 @@ export default {
|
||||
} else {
|
||||
this.checkedValue = []
|
||||
}
|
||||
this.$emit('change', this.checkedValue.join(','))
|
||||
this.$emit('change', this.checkedValue.join(','), this.fieldName)
|
||||
}
|
||||
this.$refs[this.fieldName].blur()
|
||||
this.open = open
|
||||
@@ -121,7 +121,7 @@ export default {
|
||||
if (!val) {
|
||||
this.firstValue = null
|
||||
this.checkedValue = []
|
||||
this.$emit('change', this.checkedValue.join(','))
|
||||
this.$emit('change', this.checkedValue.join(','), this.fieldName)
|
||||
}
|
||||
},
|
||||
getCurrentStyle (current) {
|
||||
@@ -157,7 +157,7 @@ export default {
|
||||
inputDom.addEventListener('focus', this.focusInput)
|
||||
})
|
||||
})
|
||||
this.$emit('change', this.checkedValue.join(','))
|
||||
this.$emit('change', this.checkedValue.join(','), this.fieldName)
|
||||
}
|
||||
// 点击日期弹出框中的确定按钮
|
||||
// handleOk () {
|
||||
|
||||
@@ -43,7 +43,8 @@
|
||||
class="box-input"
|
||||
v-model="formInline[item.dbFieldName]"
|
||||
:fieldName="item.dbFieldName"
|
||||
:disabled="disabled || disabledFieldList.includes(item.dbFieldName)" />
|
||||
:disabled="disabled || disabledFieldList.includes(item.dbFieldName)"
|
||||
@change="multipleDateChange"/>
|
||||
<!-- 5, 多行文本 -->
|
||||
<a-textarea v-else-if="item.fieldShowType === FieldType.TEXTAREA.value"
|
||||
:placeholder="$t('pleaseEnter')+item.dbFieldTxt"
|
||||
@@ -322,6 +323,14 @@ export default {
|
||||
default: () => {
|
||||
return []
|
||||
}
|
||||
},
|
||||
// 数据修改后需要同步更新该字段名后面加_remarks的字段的数据
|
||||
needSyncRemarksDataField: {
|
||||
type: Array,
|
||||
required: false,
|
||||
default: () => {
|
||||
return []
|
||||
}
|
||||
}
|
||||
},
|
||||
mounted () {
|
||||
@@ -764,6 +773,14 @@ export default {
|
||||
// this.formInline[value + '_by'] = id
|
||||
this.formInline = { ...this.formInline }
|
||||
},
|
||||
// 多选日期改变
|
||||
multipleDateChange (value, fieldName) {
|
||||
if (this.needSyncRemarksDataField.includes(fieldName)) {
|
||||
// 有关联字段需要更新
|
||||
this.formInline[fieldName + '_remarks'] = value
|
||||
this.formInline = { ...this.formInline }
|
||||
}
|
||||
},
|
||||
// 选择用户得到用户名
|
||||
userSelectNameChange (value, fieldName) {
|
||||
this.formInline[fieldName + '_dictText'] = value
|
||||
|
||||
Reference in New Issue
Block a user