Commit e006b8b8 by zhangquan

门店banner修复

1 parent c7a40420
...@@ -81,6 +81,7 @@ export default { ...@@ -81,6 +81,7 @@ export default {
publicityImgArr: [], publicityImgArr: [],
publicityImg: '', publicityImg: '',
channelImg: '', channelImg: '',
storeBannerImg: '',
channelChildName: '', channelChildName: '',
sort: '', sort: '',
channelImgArr: [], channelImgArr: [],
...@@ -156,10 +157,11 @@ export default { ...@@ -156,10 +157,11 @@ export default {
this.id ? (params.id = this.id) : this.merchantChannelId ? (params.merchantChannelId = this.merchantChannelId) : '' this.id ? (params.id = this.id) : this.merchantChannelId ? (params.merchantChannelId = this.merchantChannelId) : ''
this.$apis.channel[apis](params).then(res => { this.$apis.channel[apis](params).then(res => {
if (res.code == 0) { if (res.code == 0) {
this.channelForm = { ...res.data, posterImgArr: [], publicityImgArr: [], channelImgArr: [] } this.channelForm = { ...res.data, posterImgArr: [], publicityImgArr: [], channelImgArr: [], storeBannerImgArr:[] }
this.channelForm.posterImgArr.push(res.data.posterImg) //海报 this.channelForm.posterImgArr.push(res.data.posterImg) //海报
this.channelForm.publicityImgArr.push(res.data.publicityImg) //频道分享预览图 this.channelForm.publicityImgArr.push(res.data.publicityImg) //频道分享预览图
this.channelForm.channelImgArr.push(res.data.channelImg) //频道banner this.channelForm.channelImgArr.push(res.data.channelImg) //频道banner
this.channelForm.storeBannerImgArr.push(res.data.storeBannerImg) //门店频道banner图
if (!res.data.channelImg) this.diffChannelStyle() if (!res.data.channelImg) this.diffChannelStyle()
} }
}) })
...@@ -173,7 +175,6 @@ export default { ...@@ -173,7 +175,6 @@ export default {
this.$refs.ruleForm.clearValidate(val.key) this.$refs.ruleForm.clearValidate(val.key)
}, },
handleSave() { handleSave() {
console.log(this.channelForm, 'this.channelForm')
this.$refs.ruleForm1.validate(valid1 =>{ this.$refs.ruleForm1.validate(valid1 =>{
if(valid1){ if(valid1){
this.$refs.ruleForm.validate(valid => { this.$refs.ruleForm.validate(valid => {
...@@ -193,6 +194,7 @@ export default { ...@@ -193,6 +194,7 @@ export default {
publicityImg: this.channelForm.publicityImg, publicityImg: this.channelForm.publicityImg,
posterImg: this.channelForm.posterImg posterImg: this.channelForm.posterImg
} }
if (this.channelForm.channelType == 6) params.storeBannerImg = this.channelForm.storeBannerImg
if (this.channelForm.channelType == 1) params.channelStyle = this.channelForm.channelStyle if (this.channelForm.channelType == 1) params.channelStyle = this.channelForm.channelStyle
let apis = this.id ? 'updateChannel' : this.merchantChannelId ? 'updateMerchantChannel' : '' let apis = this.id ? 'updateChannel' : this.merchantChannelId ? 'updateMerchantChannel' : ''
this.id ? (params.id = this.id) : this.merchantChannelId ? (params.merchantChannelId = this.merchantChannelId) : '' this.id ? (params.id = this.id) : this.merchantChannelId ? (params.merchantChannelId = this.merchantChannelId) : ''
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!