Commit 51ffb002 by 李伟康

commit 提交

1 parent efd4c9b7
......@@ -237,25 +237,22 @@ export default {
/**获取车型素材配置 */
uni.$api.boutiqueApi.getBoutiqueMaterialConfig({
merchantId: shopMerchantId
}).then(({ materials }) => {
}).then(({ materials, hidePackage }) => {
let boutiqueMediaConfig = {
M5: [],
M7: [],
M9: [],
}
materials.map(e => {
const configItems = [
{ key: 'packages', configIndex: 0 },
{ key: 'films', configIndex: 1 },
{ key: 'products', configIndex: 2 }
];
const configItems = [ ]
if(!hidePackage) configItems.push({ key: 'packages', configIndex: 0 })
configItems.push({ key: 'films', configIndex: 1 })
configItems.push({ key: 'products', configIndex: 2 })
configItems.map(item => {
if (e[item.key]?.length) {
boutiqueMediaConfig[e.carModelName].push({
...defaultConfig[item.configIndex],
list: e[item.key]
})
}
boutiqueMediaConfig[e.carModelName].push({
...defaultConfig[item.configIndex],
list: e[item.key]
})
})
})
this.carBannerList.map(e => {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!