|
@@ -12,10 +12,8 @@
|
|
|
<template #agree>
|
|
|
<editor v-model="form.agree" url="/files/point/config/upload" />
|
|
|
</template>
|
|
|
- <template #bottom_menu>
|
|
|
- <el-radio-group v-model="form.bottom_menu.is_use">
|
|
|
- <el-radio v-for="(item, index) in useList" :key="index" :label="item.value">{{ item.label }}</el-radio>
|
|
|
- </el-radio-group>
|
|
|
+ <template #bottom_title>
|
|
|
+ <data-form :span="24" :fields="testfields" v-model="form.bottom_title" labelWidth="auto" :isSave="false"> </data-form>
|
|
|
</template>
|
|
|
</data-form>
|
|
|
</div>
|
|
@@ -37,14 +35,17 @@ export default {
|
|
|
{ label: '购物赠送积分', model: 'buyPoint', custom: true },
|
|
|
{ label: '自动关闭订单时间', model: 'autoCloseOrder', custom: true },
|
|
|
// { label: '积分计划', model: 'pointPlan' },
|
|
|
- { label: '底部文字', model: 'bottom_title' },
|
|
|
+ { label: '底部文字', model: 'bottom_title', custom: true },
|
|
|
+ { label: '底部菜单', model: 'bottom_menu', custom: true },
|
|
|
{ label: '分享图片', model: 'share', type: 'upload', limit: 1, url: '/files/point/config/upload' },
|
|
|
{ label: '用户协议', model: 'agree', custom: true },
|
|
|
- { label: '底部菜单', model: 'bottom_menu', custom: true },
|
|
|
],
|
|
|
rules: {},
|
|
|
- form: { bottom_menu: {} },
|
|
|
- useList: [],
|
|
|
+ form: {},
|
|
|
+ testfields: [
|
|
|
+ { label: '是否使用', model: 'is_use', type: 'radio' },
|
|
|
+ { label: '菜单列表', model: 'list', custom: true },
|
|
|
+ ],
|
|
|
};
|
|
|
},
|
|
|
computed: {
|
|
@@ -62,16 +63,16 @@ export default {
|
|
|
const res = await this.fetch();
|
|
|
if (this.$checkRes(res)) {
|
|
|
this.$set(this, `form`, res.data);
|
|
|
- // if (this.form.config) {
|
|
|
- // this.form = {
|
|
|
- // ...this.form,
|
|
|
- // logo: this.form.config.logo,
|
|
|
- // buyPoint: this.form.config.buyPoint,
|
|
|
- // pointPlan: this.form.config.pointPlan,
|
|
|
- // share: this.form.config.share,
|
|
|
- // autoCloseOrder: this.form.config.autoCloseOrder,
|
|
|
- // };
|
|
|
- // }
|
|
|
+ if (this.form.config) {
|
|
|
+ this.form = {
|
|
|
+ ...this.form,
|
|
|
+ logo: this.form.config.logo,
|
|
|
+ buyPoint: this.form.config.buyPoint,
|
|
|
+ pointPlan: this.form.config.pointPlan,
|
|
|
+ share: this.form.config.share,
|
|
|
+ autoCloseOrder: this.form.config.autoCloseOrder,
|
|
|
+ };
|
|
|
+ }
|
|
|
}
|
|
|
},
|
|
|
async toSave({ data }) {
|