|
@@ -178,7 +178,8 @@
|
|
import { scanVinLogQueryRoll, getScanVinLogList, getScanGetMaxQty }from '@/api/car.js'
|
|
import { scanVinLogQueryRoll, getScanVinLogList, getScanGetMaxQty }from '@/api/car.js'
|
|
import { shopBannerList } from '@/api/video.js'
|
|
import { shopBannerList } from '@/api/video.js'
|
|
import { getRewardRollList } from '@/api/rewardRule.js'
|
|
import { getRewardRollList } from '@/api/rewardRule.js'
|
|
- import { getShopStatus, getCartCount } from '@/api/cart.js'
|
|
|
|
|
|
+ import { getCartCount } from '@/api/cart.js'
|
|
|
|
+ import { getShopStatus, getShopUserParam } from '@/api/bizParam.js'
|
|
import { getShopCategory, getShopProductList } from '@/api/shop.js'
|
|
import { getShopCategory, getShopProductList } from '@/api/shop.js'
|
|
import { openWebView, clickTab, toAuthStore, clickBannerList, toLogin } from "@/utils/index.js"
|
|
import { openWebView, clickTab, toAuthStore, clickBannerList, toLogin } from "@/utils/index.js"
|
|
export default {
|
|
export default {
|
|
@@ -455,13 +456,31 @@
|
|
// 商城信息, flag: true 再次刷新,false 只加载一次
|
|
// 商城信息, flag: true 再次刷新,false 只加载一次
|
|
getHasShopping(flag){
|
|
getHasShopping(flag){
|
|
getShopStatus().then(res => {
|
|
getShopStatus().then(res => {
|
|
- this.hasShopiing = res.data && res.data.paramValue == 1
|
|
|
|
|
|
+ const hasShopiing = res.data && res.data.paramValue == 1
|
|
|
|
+ // 经销商开启商城
|
|
|
|
+ if(hasShopiing){
|
|
|
|
+ // 判断员工是否开启商城
|
|
|
|
+ this.getShopUserStatus(flag)
|
|
|
|
+ }else{
|
|
|
|
+ this.hasShopiing = false
|
|
|
|
+ this.$store.state.vuex_hasShopiing = this.hasShopiing
|
|
|
|
+ // 没有商城
|
|
|
|
+ this.showNoShopPage(flag)
|
|
|
|
+ // 查询红包活动
|
|
|
|
+ this.getRedPacketRule()
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ },
|
|
|
|
+ // 员工用户是否开启商城
|
|
|
|
+ getShopUserStatus(flag){
|
|
|
|
+ getShopUserParam({}).then(res=>{
|
|
|
|
+ const item = res.data
|
|
|
|
+ this.hasShopiing = item && item.paramMap && item.paramMap.mall_flag && item.paramMap.mall_flag.paramValue == 1
|
|
this.$store.state.vuex_hasShopiing = this.hasShopiing
|
|
this.$store.state.vuex_hasShopiing = this.hasShopiing
|
|
- // 有商城
|
|
|
|
if(this.hasShopiing){
|
|
if(this.hasShopiing){
|
|
|
|
+ // 判断员工是否开启商城
|
|
this.showShopPage(flag)
|
|
this.showShopPage(flag)
|
|
}else{
|
|
}else{
|
|
- // 没有商城
|
|
|
|
this.showNoShopPage(flag)
|
|
this.showNoShopPage(flag)
|
|
}
|
|
}
|
|
// 查询红包活动
|
|
// 查询红包活动
|