修改禅道已知bug
This commit is contained in:
@@ -27,7 +27,7 @@
|
|||||||
/>
|
/>
|
||||||
<a-table
|
<a-table
|
||||||
:columns="columns"
|
:columns="columns"
|
||||||
rowKey="id"
|
rowKey="serial_number"
|
||||||
:scroll="{x: 1500}"
|
:scroll="{x: 1500}"
|
||||||
:data-source="dataList"
|
:data-source="dataList"
|
||||||
:pagination="false"
|
:pagination="false"
|
||||||
@@ -132,7 +132,7 @@
|
|||||||
if (res.success) {
|
if (res.success) {
|
||||||
this.dataList = res.result.records
|
this.dataList = res.result.records
|
||||||
this.total = res.result.total
|
this.total = res.result.total
|
||||||
this.selectedRowKeys = this.standard[this.query.db_field_name + '_id'] ? this.standard[this.query.db_field_name + '_id'].split(',') : []
|
this.selectedRowKeys = this.standard[this.query.db_field_name] ? this.standard[this.query.db_field_name].split(',') : []
|
||||||
} else {
|
} else {
|
||||||
this.dataList = []
|
this.dataList = []
|
||||||
}
|
}
|
||||||
@@ -143,15 +143,16 @@
|
|||||||
},
|
},
|
||||||
handleSubmit() {
|
handleSubmit() {
|
||||||
let content = []
|
let content = []
|
||||||
let replace_standard_id = []
|
// let replace_standard_id = []
|
||||||
if (this.content && this.content.length > 0) {
|
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
|
||||||
this.content.forEach(res => {
|
let content = JSON.parse(JSON.stringify(this.selectedRowKeys))
|
||||||
content.push(res.serial_number)
|
// this.content.forEach(res => {
|
||||||
replace_standard_id.push(res.id)
|
// content.push(res.serial_number)
|
||||||
})
|
// replace_standard_id.push(res.id)
|
||||||
|
// })
|
||||||
this.$emit('input', content.join(','))
|
this.$emit('input', content.join(','))
|
||||||
this.$emit('change', this.query.db_field_name, replace_standard_id.join(','))
|
// this.$emit('change', this.query.db_field_name, replace_standard_id.join(','))
|
||||||
this.$emit('changecontent', this.content)
|
// this.$emit('changecontent', this.content)
|
||||||
this.visible = false
|
this.visible = false
|
||||||
} else {
|
} else {
|
||||||
this.$message.warning(this.$t('selectLeastOne'))
|
this.$message.warning(this.$t('selectLeastOne'))
|
||||||
@@ -161,15 +162,16 @@
|
|||||||
this.$emit('input', event.target.value)
|
this.$emit('input', event.target.value)
|
||||||
},
|
},
|
||||||
onSelectChange(value) {
|
onSelectChange(value) {
|
||||||
|
console.log(value)
|
||||||
this.selectedRowKeys = value
|
this.selectedRowKeys = value
|
||||||
this.content = []
|
// this.content = []
|
||||||
value.forEach(val => {
|
// value.forEach(val => {
|
||||||
this.dataList.forEach((res) => {
|
// this.dataList.forEach((res) => {
|
||||||
if (res.id === val) {
|
// if (res.id === val) {
|
||||||
this.content.push(res)
|
// this.content.push(res)
|
||||||
}
|
// }
|
||||||
})
|
// })
|
||||||
})
|
// })
|
||||||
},
|
},
|
||||||
searchQuery(queryParam) {
|
searchQuery(queryParam) {
|
||||||
let queryParamQuery = JSON.parse(JSON.stringify(queryParam))
|
let queryParamQuery = JSON.parse(JSON.stringify(queryParam))
|
||||||
|
|||||||
@@ -163,7 +163,6 @@
|
|||||||
</div>
|
</div>
|
||||||
<a-form-model-item class="itemModel" :prop="item.db_field_name">
|
<a-form-model-item class="itemModel" :prop="item.db_field_name">
|
||||||
<Standardselection :query="item"
|
<Standardselection :query="item"
|
||||||
@change="StandardselectionChange"
|
|
||||||
:disabled="disabled"
|
:disabled="disabled"
|
||||||
:standard="formInline"
|
:standard="formInline"
|
||||||
v-model="formInline[item.db_field_name]"/>
|
v-model="formInline[item.db_field_name]"/>
|
||||||
@@ -473,10 +472,10 @@
|
|||||||
this.type = 'add'
|
this.type = 'add'
|
||||||
this.getForm()
|
this.getForm()
|
||||||
},
|
},
|
||||||
StandardselectionChange(value, id) {
|
// StandardselectionChange(value, id) {
|
||||||
this.formInline[value + '_id'] = id
|
// this.formInline[value + '_id'] = id
|
||||||
this.formInline = { ...this.formInline }
|
// this.formInline = { ...this.formInline }
|
||||||
},
|
// },
|
||||||
PersonnelSelectionChange(value, id) {
|
PersonnelSelectionChange(value, id) {
|
||||||
this.formInline[value + '_id'] = id
|
this.formInline[value + '_id'] = id
|
||||||
this.formInline = { ...this.formInline }
|
this.formInline = { ...this.formInline }
|
||||||
|
|||||||
@@ -169,8 +169,6 @@
|
|||||||
</div>
|
</div>
|
||||||
<a-form-model-item class="itemModel" :prop="item.db_field_name">
|
<a-form-model-item class="itemModel" :prop="item.db_field_name">
|
||||||
<Standardselection :query="item"
|
<Standardselection :query="item"
|
||||||
@changecontent='changeContent'
|
|
||||||
@change="StandardselectionChange"
|
|
||||||
:disabled="disabled"
|
:disabled="disabled"
|
||||||
:standard="formInline"
|
:standard="formInline"
|
||||||
v-model="formInline[item.db_field_name]"/>
|
v-model="formInline[item.db_field_name]"/>
|
||||||
@@ -1128,19 +1126,19 @@
|
|||||||
this.type = 'add'
|
this.type = 'add'
|
||||||
|
|
||||||
},
|
},
|
||||||
changeContent(val) {
|
// changeContent(val) {
|
||||||
this.standardSelectionContent = val
|
// this.standardSelectionContent = val
|
||||||
},
|
// },
|
||||||
StandardselectionChange(value, id) {
|
// StandardselectionChange(value, id) {
|
||||||
// todo
|
// todo
|
||||||
// this.valueItem = value
|
// this.valueItem = value
|
||||||
// if(this.formInline[value] !== undefined) {
|
// if(this.formInline[value] !== undefined) {
|
||||||
// this.formArrayName = this.formInline[value].split(',')
|
// this.formArrayName = this.formInline[value].split(',')
|
||||||
// this.formArrayId = id.split(',')
|
// this.formArrayId = id.split(',')
|
||||||
// }
|
// }
|
||||||
this.formInline[value + '_id'] = id
|
// this.formInline[value + '_id'] = id
|
||||||
this.formInline = { ...this.formInline }
|
// this.formInline = { ...this.formInline }
|
||||||
},
|
// },
|
||||||
PersonnelSelectionChange(value, id) {
|
PersonnelSelectionChange(value, id) {
|
||||||
this.formInline[value + '_id'] = id
|
this.formInline[value + '_id'] = id
|
||||||
this.formInline = { ...this.formInline }
|
this.formInline = { ...this.formInline }
|
||||||
|
|||||||
@@ -629,10 +629,10 @@
|
|||||||
this.$refs.ruleForm.validateField([value])
|
this.$refs.ruleForm.validateField([value])
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
StandardselectionChange(value, id) {
|
// StandardselectionChange(value, id) {
|
||||||
this.formInline[value + '_id'] = id
|
// this.formInline[value + '_id'] = id
|
||||||
this.formInline = { ...this.formInline }
|
// this.formInline = { ...this.formInline }
|
||||||
},
|
// },
|
||||||
dateChange(item) {
|
dateChange(item) {
|
||||||
this.formInline[item.db_field_name] = this.formInline[item.db_field_name] ? moment(this.formInline[item.db_field_name]).format('YYYY-MM-DD') : ''
|
this.formInline[item.db_field_name] = this.formInline[item.db_field_name] ? moment(this.formInline[item.db_field_name]).format('YYYY-MM-DD') : ''
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user