对接问题知识库
This commit is contained in:
+46
-11
@@ -10,7 +10,7 @@
|
||||
:visible="visible"
|
||||
style="height: 100%;overflow: auto;padding-bottom: 53px;">
|
||||
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
|
||||
<a-row :gutter="24">
|
||||
<a-row :gutter="24" v-if="title == $t('newlyAdded')">
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
@@ -20,6 +20,7 @@
|
||||
</div>
|
||||
<a-form-model-item class="itemModel" prop="applyMarket">
|
||||
<a-select :placeholder="$t('PleaseSelect')+$t('applicableMarket')"
|
||||
:disabled="false"
|
||||
v-model="formInline.applyMarket">
|
||||
<a-select-option v-for="(item, key) in applyMarketList"
|
||||
:key="key"
|
||||
@@ -33,6 +34,23 @@
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24" v-if="title == $t('edit')">
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="title-text-text"
|
||||
:title="$t('applicableMarket')">{{$t('applicableMarket')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel">
|
||||
<j-dict-select-tag class="box-input" v-model="formInline.applyMarket"
|
||||
:disabled="true"
|
||||
:placeholder="$t('PleaseSelect')+$t('applicableMarket')"
|
||||
:type="'select'"
|
||||
:triggerChange="false" :dictCode="'region'"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form-model>
|
||||
<div style="margin-bottom: 60px">
|
||||
<a-table
|
||||
@@ -143,15 +161,23 @@
|
||||
methods: {
|
||||
add() {
|
||||
this.visible = true
|
||||
this.$nextTick(() => {
|
||||
this.formInline = {}
|
||||
this.$refs.ruleForm.clearValidate()
|
||||
})
|
||||
this.title = this.$t('newlyAdded')
|
||||
this.replacePage()
|
||||
this.getApplyMarketList()
|
||||
},
|
||||
edit(row) {
|
||||
this.visible = true
|
||||
this.$nextTick(() => {
|
||||
this.formInline = row
|
||||
this.formInline = { ...this.formInline }
|
||||
this.$refs.ruleForm.clearValidate()
|
||||
})
|
||||
this.title = this.$t('edit')
|
||||
this.editReplacePage(row)
|
||||
this.getApplyMarketList()
|
||||
},
|
||||
getApplyMarketList() {
|
||||
getAction('/problemKnowledgeBase/countryCardManageReleaseEO/getApplyMarketList', {}).then((res) => {
|
||||
@@ -194,20 +220,29 @@
|
||||
this.$refs.ruleForm.validate(valid => {
|
||||
if (valid) {
|
||||
let url = ''
|
||||
let content = []
|
||||
if (this.title == this.$t('newlyAdded')) {
|
||||
url = this.url.add
|
||||
this.dataList.forEach(res => {
|
||||
content.push({
|
||||
countryCardTempId: res.id,
|
||||
description: res.description,
|
||||
content: res.content
|
||||
})
|
||||
})
|
||||
} else {
|
||||
url = this.url.edit
|
||||
this.dataList.forEach(res => {
|
||||
content.push({
|
||||
countryCardTempId: res.id,
|
||||
description: res.description,
|
||||
content: res.content,
|
||||
id: res.id
|
||||
})
|
||||
})
|
||||
}
|
||||
this.confirmLoading = true
|
||||
let content = []
|
||||
this.dataList.forEach(res => {
|
||||
content.push({
|
||||
countryCardTempId: res.id,
|
||||
description: res.description,
|
||||
content: res.content
|
||||
})
|
||||
})
|
||||
|
||||
let query = {
|
||||
countryCardManageReleaseDetailEOList: content,
|
||||
applyMarket: this.formInline.applyMarket
|
||||
@@ -240,7 +275,7 @@
|
||||
},
|
||||
editReplacePage(row) {
|
||||
this.loading = true
|
||||
getAction('/problemKnowledgeBase/countryCardManageReleaseDetailEO/list', { editReplacePage: row.id }).then((res) => {
|
||||
getAction('/problemKnowledgeBase/countryCardManageReleaseDetailEO/list', { countryCardManageReleaseId: row.id }).then((res) => {
|
||||
if (res.success) {
|
||||
this.dataList = res.result || []
|
||||
this.loading = false
|
||||
|
||||
Reference in New Issue
Block a user