|
@@ -11,8 +11,8 @@
|
|
|
custom-class="xl-dialog"
|
|
|
center
|
|
|
>
|
|
|
- <base-form ref="ruleForm" class="lib-edit" :data="formData" :is-inline="false" label-width="110px" :insertSlotArr="[9]">
|
|
|
- <div slot="OI9" class="scoped-other-form">
|
|
|
+ <base-form ref="ruleForm" class="lib-edit" :data="formData" :is-inline="false" label-width="110px" :insertSlotArr="[10]">
|
|
|
+ <div slot="OI10" class="scoped-other-form">
|
|
|
<el-form-item label="点位坐标" class="scoped-item-two item">
|
|
|
纬度N<el-input v-model="cObj.latitude" disabled />
|
|
|
经度E<el-input v-model="cObj.longitude" disabled />
|
|
@@ -73,13 +73,21 @@ export default {
|
|
|
const disabled = false
|
|
|
if (!params.pri_image) params.pri_image = 'http://img.honglounews.com/20210429034015-4091.png'
|
|
|
let remoteOptionsHouse = []
|
|
|
- if (params.estate_list && params.estate_list.length > 0) {
|
|
|
- params.estate_id_list = params.estate_list.map(item => {
|
|
|
+ if (params.estate_list && params.estate_list.duikou && params.estate_list.duikou.length > 0) {
|
|
|
+ params.estate_dk_list = params.estate_list.duikou.map(item => {
|
|
|
remoteOptionsHouse.push({ keyRO: item.estate_name, valRO: item.id })
|
|
|
return item.id
|
|
|
})
|
|
|
} else {
|
|
|
- params.estate_list = []
|
|
|
+ params.estate_dk_list = []
|
|
|
+ }
|
|
|
+ if (params.estate_list && params.estate_list.guihua && params.estate_list.guihua.length > 0) {
|
|
|
+ params.estate_gh_list = params.estate_list.guihua.map(item => {
|
|
|
+ remoteOptionsHouse.push({ keyRO: item.estate_name, valRO: item.id })
|
|
|
+ return item.id
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ params.estate_gh_list = []
|
|
|
}
|
|
|
if (params.school_type === '2') {
|
|
|
this.formData = [
|
|
@@ -92,7 +100,11 @@ export default {
|
|
|
{ label: '主图', key: 'pri_image', type: 'upload', class: 'c-2' },
|
|
|
{ label: '学区范围图', key: 'district_img', type: 'upload', class: 'c-2' },
|
|
|
{ label: '学区范围', key: 'district',type: 'textarea' },
|
|
|
- { label: '对口楼盘', key: 'estate_id_list', multiple: true, type: 'selectRemote',
|
|
|
+ { label: '对口楼盘', key: 'estate_dk_list', multiple: true, type: 'selectRemote',
|
|
|
+ remoteParams: { skey: 'estate_name', api: `house.admestatelist`, opKey: 'estate_name', opVal: 'id' },
|
|
|
+ remoteOptions: remoteOptionsHouse
|
|
|
+ },
|
|
|
+ { label: '规划楼盘', key: 'estate_gh_list', multiple: true, type: 'selectRemote',
|
|
|
remoteParams: { skey: 'estate_name', api: `house.admestatelist`, opKey: 'estate_name', opVal: 'id' },
|
|
|
remoteOptions: remoteOptionsHouse
|
|
|
},
|
|
@@ -112,7 +124,11 @@ export default {
|
|
|
{ label: '主图', key: 'pri_image', type: 'upload', class: 'c-2' },
|
|
|
{ label: '学区范围图', key: 'district_img', type: 'upload', class: 'c-2' },
|
|
|
{ label: '学区范围', key: 'district',type: 'textarea' },
|
|
|
- { label: '对口楼盘', key: 'estate_id_list', multiple: true, type: 'selectRemote',
|
|
|
+ { label: '对口楼盘', key: 'estate_dk_list', multiple: true, type: 'selectRemote',
|
|
|
+ remoteParams: { skey: 'estate_name', api: `house.admestatelist`, opKey: 'estate_name', opVal: 'id' },
|
|
|
+ remoteOptions: remoteOptionsHouse
|
|
|
+ },
|
|
|
+ { label: '规划楼盘', key: 'estate_gh_list', multiple: true, type: 'selectRemote',
|
|
|
remoteParams: { skey: 'estate_name', api: `house.admestatelist`, opKey: 'estate_name', opVal: 'id' },
|
|
|
remoteOptions: remoteOptionsHouse
|
|
|
},
|
|
@@ -132,10 +148,15 @@ export default {
|
|
|
const oldform = this.$refs.ruleForm.baseForm
|
|
|
const newForm = { ...oldform }
|
|
|
if (this.curObj.id) newForm.id = this.curObj.id
|
|
|
- if (newForm.estate_id_list && newForm.estate_id_list.length > 0) {
|
|
|
- newForm.estate_id_list = newForm.estate_id_list.join(',')
|
|
|
+ if (newForm.estate_dk_list && newForm.estate_dk_list.length > 0) {
|
|
|
+ newForm.estate_dk_list = newForm.estate_dk_list.join(',')
|
|
|
+ } else {
|
|
|
+ newForm.estate_dk_list = ''
|
|
|
+ }
|
|
|
+ if (newForm.estate_gh_list && newForm.estate_gh_list.length > 0) {
|
|
|
+ newForm.estate_gh_list = newForm.estate_gh_list.join(',')
|
|
|
} else {
|
|
|
- newForm.estate_id_list = ''
|
|
|
+ newForm.estate_gh_list = ''
|
|
|
}
|
|
|
newForm.longitude = this.cObj.longitude
|
|
|
newForm.latitude = this.cObj.latitude
|