Commit 6096db50 authored by GuanHua's avatar GuanHua

fix: app企业商城装修问题修改

parent 2ab433ff
......@@ -120,16 +120,20 @@ const appMallEdit: React.FC<ShopPreviewPropsType> = (props) => {
}
switch(data.type) {
case 1:
param.idInList = data.recommend
getFn = PublicApi.postSearchMobileShopEnterpriseGetCommodityList
if(data.recommend && Array.isArray(data.recommend) && data.recommend.length > 0) {
param.idInList = data.recommend
getFn = PublicApi.postSearchMobileShopEnterpriseGetCommodityList
}
break
case 2:
param.idList = data.recommend
getFn = PublicApi.getTemplateWebMemberShopWebRecommendList
break
case 3:
param.idList = data.recommend
getFn = PublicApi.postSearchMobileShopEnterpriseGetCategoryBrand
if(data.recommend && Array.isArray(data.recommend) && data.recommend.length > 0) {
param.idList = data.recommend
getFn = PublicApi.postSearchMobileShopEnterpriseGetCategoryBrand
}
break
case 4:
param.idList = data.recommend
......@@ -142,8 +146,8 @@ const appMallEdit: React.FC<ShopPreviewPropsType> = (props) => {
message.destroy()
resolve(data.type === 3 ? res.data : res.data.data)
}).catch(() => {
resolve(undefined)
}) : resolve(undefined)
resolve([])
}) : resolve([])
})
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment