Commit 51ffb002 by 李伟康

commit 提交

1 parent efd4c9b7
...@@ -237,25 +237,22 @@ export default { ...@@ -237,25 +237,22 @@ export default {
/**获取车型素材配置 */ /**获取车型素材配置 */
uni.$api.boutiqueApi.getBoutiqueMaterialConfig({ uni.$api.boutiqueApi.getBoutiqueMaterialConfig({
merchantId: shopMerchantId merchantId: shopMerchantId
}).then(({ materials }) => { }).then(({ materials, hidePackage }) => {
let boutiqueMediaConfig = { let boutiqueMediaConfig = {
M5: [], M5: [],
M7: [], M7: [],
M9: [], M9: [],
} }
materials.map(e => { materials.map(e => {
const configItems = [ const configItems = [ ]
{ key: 'packages', configIndex: 0 }, if(!hidePackage) configItems.push({ key: 'packages', configIndex: 0 })
{ key: 'films', configIndex: 1 }, configItems.push({ key: 'films', configIndex: 1 })
{ key: 'products', configIndex: 2 } configItems.push({ key: 'products', configIndex: 2 })
];
configItems.map(item => { configItems.map(item => {
if (e[item.key]?.length) {
boutiqueMediaConfig[e.carModelName].push({ boutiqueMediaConfig[e.carModelName].push({
...defaultConfig[item.configIndex], ...defaultConfig[item.configIndex],
list: e[item.key] list: e[item.key]
}) })
}
}) })
}) })
this.carBannerList.map(e => { 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!