|
|
@ -493,11 +493,12 @@ export default { |
|
|
|
}, |
|
|
|
}, |
|
|
|
// 根据模板id获取样式 |
|
|
|
// 根据模板id获取样式 |
|
|
|
getStyle(set = 1) { |
|
|
|
getStyle(set = 1) { |
|
|
|
this.$post(`${this.api.theTemplateIdGetsTheStyle}?templateId=${this.form.templateId}`).then(({ data }) => { |
|
|
|
const { templateId } = this.form |
|
|
|
|
|
|
|
this.$post(`${this.api.theTemplateIdGetsTheStyle}?templateId=${templateId}`).then(({ data }) => { |
|
|
|
this.listStyle = data.listingTemplateTypes |
|
|
|
this.listStyle = data.listingTemplateTypes |
|
|
|
this.detailStyleId = data.detailsTypeOfTheTemplate |
|
|
|
this.detailStyleId = data.detailsTypeOfTheTemplate |
|
|
|
if (set) { |
|
|
|
if (set) { |
|
|
|
this.form.listStyleId = this.listStyle[1].id |
|
|
|
this.form.listStyleId = this.listStyle[templateId === 1 ? 1 : 0].id |
|
|
|
this.form.detailStyleId = this.detailStyleId[0].id |
|
|
|
this.form.detailStyleId = this.detailStyleId[0].id |
|
|
|
} |
|
|
|
} |
|
|
|
}).catch(err => {}) |
|
|
|
}).catch(err => {}) |
|
|
|