|
@@ -5,13 +5,13 @@
|
|
|
:show-close="false"
|
|
|
:close-on-click-modal="false"
|
|
|
:visible.sync="isShow"
|
|
|
- :title="curObj.id ? '编辑银行利率' : '添加银行利率'"
|
|
|
+ :title="curObj.id ? '编辑活动' : '添加活动'"
|
|
|
:fullscreen="false"
|
|
|
- width="700px"
|
|
|
+ width="400px"
|
|
|
custom-class="xl-dialog"
|
|
|
center
|
|
|
>
|
|
|
- <base-form ref="ruleForm" class="lib-edit" :data="formData" :is-inline="false" label-width="100px">
|
|
|
+ <base-form ref="ruleForm" :data="formData" :is-inline="false" label-width="100px">
|
|
|
<div slot="footer" style="padding-top: 20px;">
|
|
|
<el-button class="xl-form-btn t2" @click="close">关 闭</el-button>
|
|
|
<el-button class="xl-form-btn t1" @click="close('confirm')">确定</el-button>
|
|
@@ -46,13 +46,13 @@ export default {
|
|
|
getDef() {
|
|
|
let params = { ...this.curObj }
|
|
|
this.formData = [
|
|
|
- { label: '银行名称', key: 'bank_name', class: 'c-2', rules: 1 },
|
|
|
- { label: '银行logo', key: 'pri_image', class: 'c-2', type: 'uploads', rules: 1 },
|
|
|
- { label: '一套利率', key: 'one_rate', class: 'c-2', rules: 1 },
|
|
|
- { label: '二套利率', key: 'two_rate', class: 'c-2', rules: 1 },
|
|
|
- { label: '文字颜色', key: 'colour', type: 'colorPicker'},
|
|
|
- { label: '预选1', key: 'option1', class: 'c-2'},
|
|
|
- { label: '预选2', key: 'option2', class: 'c-2'},
|
|
|
+ { label: '活动楼盘', key: 'estate_id', rules: 1, type: 'selectRemote', changeHandle: this.estateChange,
|
|
|
+ remoteParams: { skey: 'estate_name', api: `house.admestatelist`, opKey: 'estate_name', opVal: 'id' },
|
|
|
+ remoteOptions: [
|
|
|
+ { keyRO: params.estate_name, valRO: params.estate_id }
|
|
|
+ ]
|
|
|
+ },
|
|
|
+ { label: '备注', key: 'remark', rules: 1, type: 'textarea'},
|
|
|
]
|
|
|
this.setDefaultValue(params)
|
|
|
},
|
|
@@ -63,8 +63,8 @@ export default {
|
|
|
const oldform = this.$refs.ruleForm.baseForm
|
|
|
const newForm = { ...oldform }
|
|
|
if (this.curObj.id) newForm.id = this.curObj.id
|
|
|
- let apiStr = 'admbankrateadd'
|
|
|
- if (newForm.id) apiStr = 'admbankrateedit'
|
|
|
+ let apiStr = 'admactivityadd'
|
|
|
+ if (newForm.id) apiStr = 'admactivityedit'
|
|
|
this.$api.other[apiStr](newForm).then(data => {
|
|
|
this.$msgs(newForm.id ? '编辑成功' : '新增成功')
|
|
|
this.$emit('close', newForm)
|