Commit b64ff9d2 authored by GuanHua's avatar GuanHua

feat:修改商城装修

parent e310c429
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
"core-js": "^3.6.5", "core-js": "^3.6.5",
"god": "^0.1.26", "god": "^0.1.26",
"lingxi-design": "^1.0.7", "lingxi-design": "^1.0.7",
"lingxi-design-ui": "^1.0.8", "lingxi-design-ui": "^1.0.9",
"lingxi-editor-core": "^1.0.6", "lingxi-editor-core": "^1.0.6",
"lingxi-web": "^1.0.6", "lingxi-web": "^1.0.6",
"lint-staged": "^10.0.7", "lint-staged": "^10.0.7",
...@@ -65,4 +65,4 @@ ...@@ -65,4 +65,4 @@
"ora": "^4.0.4", "ora": "^4.0.4",
"typescript": "^3.9.7" "typescript": "^3.9.7"
} }
} }
\ No newline at end of file
...@@ -36,6 +36,33 @@ export const SHOP_TYPES = [ ...@@ -36,6 +36,33 @@ export const SHOP_TYPES = [
name: "渠道积分商城" name: "渠道积分商城"
}, },
] ]
export enum LAYOUT_TYPE {
/**
* 企业商城
*/
mall = 'mall',
/**
* 店铺(店铺商城)
*/
shop = 'shop',
/**
* 渠道商城
*/
channel = 'channel',
/**
* 企业商城-积分商城
*/
scoreMall = 'scoreMall',
/**
* 店铺-积分兑换
*/
shopScoreMall = 'shopScoreMall',
/**
* 渠道商城-积分兑换
*/
channelScoreMall = 'channelScoreMall',
}
// 本地环境跳过权限校验 // 本地环境跳过权限校验
export const isDev = process.env.NODE_ENV === "development" export const isDev = process.env.NODE_ENV === "development"
......
export const menuData = [
{
"path": "/shop",
"name": "首页",
"key": "shopHome",
},
{
"path": "/commodity",
"name": "商品商城",
"key": "shopCommodity",
},
{
"path": "/purchaseOnline",
"name": "在线求购",
"key": "purchaseOnline",
},
{
"path": "/pointsMall",
"name": "积分商城",
"key": "shopPointsMall",
},
{
"path": "/shops",
"name": "店铺",
"key": "shops",
},
{
"path": "/shop/infomation",
"name": "资讯",
"key": "shopInfomation",
},
]
\ No newline at end of file
...@@ -6,6 +6,8 @@ import SettingPanel from '../settingsPanel' ...@@ -6,6 +6,8 @@ import SettingPanel from '../settingsPanel'
import config from '../configs' import config from '../configs'
import { topBarConfig, topAdvertConfig, headerConfig, mainNavConfig, bannerAdvertConfig, interactAdvertConfig, mallLayoutConfig, FindMoreConfig, InformationConfig, FooterConfig } from './defaultData' import { topBarConfig, topAdvertConfig, headerConfig, mainNavConfig, bannerAdvertConfig, interactAdvertConfig, mallLayoutConfig, FindMoreConfig, InformationConfig, FooterConfig } from './defaultData'
import Loading from './loading' import Loading from './loading'
import { LAYOUT_TYPE } from '@/constants'
import { menuData } from './defaultMenu'
import { PublicApi } from '@/services/api' import { PublicApi } from '@/services/api'
import styles from './index.less' import styles from './index.less'
...@@ -114,6 +116,11 @@ const MallEdit: React.FC<MallEditPropsType> = (props) => { ...@@ -114,6 +116,11 @@ const MallEdit: React.FC<MallEditPropsType> = (props) => {
} }
const getComponentsConfig = async () => { const getComponentsConfig = async () => {
// 导航栏
mainNavConfig[mainNavConfig.key].props.menuData = menuData
mainNavConfig[mainNavConfig.key].props.type = LAYOUT_TYPE.mall
mainNavConfig[mainNavConfig.key].props.categoryList = []
// 一号位广告 // 一号位广告
bannerAdvertConfig[bannerAdvertConfig.key].props.advertList = await findFirstAdvertsByType() bannerAdvertConfig[bannerAdvertConfig.key].props.advertList = await findFirstAdvertsByType()
// 二号位广告 // 二号位广告
......
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