|
|
@ -6,10 +6,10 @@ |
|
|
|
<!-- 模板预览 --> |
|
|
|
<!-- 模板预览 --> |
|
|
|
<div class="preview fl-l"> |
|
|
|
<div class="preview fl-l"> |
|
|
|
<a-carousel autoplay> |
|
|
|
<a-carousel autoplay> |
|
|
|
<template v-if="form.getFieldValue('style')"> |
|
|
|
<template> |
|
|
|
<div v-for="(item, index) in imageList" :key="index"> |
|
|
|
<div v-for="(item, index) in imageList" :key="index"> |
|
|
|
<img |
|
|
|
<img |
|
|
|
:src="`static/style/${form.getFieldValue('style')}/${item.name}${form.getFieldValue('style')}.png`" |
|
|
|
:src="`static/style/${form.getFieldValue('style') || 'default'}/${item.name}${form.getFieldValue('style')}.png`" |
|
|
|
/> |
|
|
|
/> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</template> |
|
|
|
</template> |
|
|
@ -20,7 +20,7 @@ |
|
|
|
<a-form :form="form" @submit="handleSubmit"> |
|
|
|
<a-form :form="form" @submit="handleSubmit"> |
|
|
|
<a-form-item label="页面风格" :labelCol="labelCol" :wrapperCol="wrapperCol"> |
|
|
|
<a-form-item label="页面风格" :labelCol="labelCol" :wrapperCol="wrapperCol"> |
|
|
|
<a-radio-group |
|
|
|
<a-radio-group |
|
|
|
v-decorator="['style', { rules: [{ required: true, message: '请选择页面风格' }]}]" |
|
|
|
v-decorator="['style', { rules: [{ required: false, message: '请选择页面风格' }]}]" |
|
|
|
> |
|
|
|
> |
|
|
|
<a-radio |
|
|
|
<a-radio |
|
|
|
v-for="(item, index) in pageStyle" |
|
|
|
v-for="(item, index) in pageStyle" |
|
|
@ -77,7 +77,7 @@ export default { |
|
|
|
.then(result => { |
|
|
|
.then(result => { |
|
|
|
console.log(result) |
|
|
|
console.log(result) |
|
|
|
// 当前记录 |
|
|
|
// 当前记录 |
|
|
|
this.record.style = result.data.detail.style || '' |
|
|
|
this.record.style = result.data.detail ? (result.data.detail.style || '') : '' |
|
|
|
// 设置默认值 |
|
|
|
// 设置默认值 |
|
|
|
this.setFieldsValue() |
|
|
|
this.setFieldsValue() |
|
|
|
}) |
|
|
|
}) |
|
|
|