|
|
@@ -34,7 +34,7 @@ Page({
|
|
|
})
|
|
|
/* 首页宫格授权查询 */
|
|
|
if (wx.getStorageSync('userauth').length != 0) {
|
|
|
- let auth = getApp().globalData.queryPer.query(wx.getStorageSync('userauth'), ['营销工具'], ['通告', '推广素材', '商学院', '提报', '销售线索', '营销物料', '销售目标']),
|
|
|
+ let auth = getApp().globalData.queryPer.query(wx.getStorageSync('userauth'), ['营销工具'], ['通告', '推广素材', '商学院', '提报', '销售线索', '营销物料', '销售目标', '客户管理']),
|
|
|
gridList = [],
|
|
|
subassembly = [];
|
|
|
auth.forEach(v => {
|
|
|
@@ -109,6 +109,42 @@ Page({
|
|
|
apps: v.apps
|
|
|
})
|
|
|
break;
|
|
|
+ /* 二期应用分界线 */
|
|
|
+ case "客户管理":
|
|
|
+ v.apps.forEach(value => {
|
|
|
+ switch (value.name) {
|
|
|
+ //客户
|
|
|
+ case "wCustomer":
|
|
|
+ if (value.meta.auth.some(r => r.option == 'read')) gridList.push({
|
|
|
+ name: "客户",
|
|
|
+ path: "/packageA/setclient/index",
|
|
|
+ icon: "icon-kehu",
|
|
|
+ apps: {}
|
|
|
+ })
|
|
|
+ getApp().globalData.auth.wCustomer = {
|
|
|
+ options: value.meta.auth.map(a => a.option),
|
|
|
+ optionnames: value.meta.auth.map(a => a.optionname),
|
|
|
+ }
|
|
|
+ break;
|
|
|
+ //公海客户
|
|
|
+ case "wPublicCustomer":
|
|
|
+ if (value.meta.auth.some(r => r.option == 'read')) gridList.push({
|
|
|
+ name: "公海客户",
|
|
|
+ path: "/packageA/publicCustomer/index",
|
|
|
+ icon: "icon-xiaochengxutongxunlu",
|
|
|
+ apps: {}
|
|
|
+ })
|
|
|
+ getApp().globalData.auth.wPublicCustomer = {
|
|
|
+ options: value.meta.auth.map(a => a.option),
|
|
|
+ optionnames: value.meta.auth.map(a => a.optionname),
|
|
|
+ }
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ })
|
|
|
+ break;
|
|
|
+ default:
|
|
|
+ console.log(v)
|
|
|
+ break;
|
|
|
};
|
|
|
});
|
|
|
if (!['美大'].includes(this.data.site)) {
|
|
|
@@ -119,12 +155,7 @@ Page({
|
|
|
apps: {}
|
|
|
})
|
|
|
|
|
|
- gridList.push({
|
|
|
- name: "客户",
|
|
|
- path: "/packageA/setclient/index",
|
|
|
- icon: "icon-kehu",
|
|
|
- apps: {}
|
|
|
- })
|
|
|
+
|
|
|
|
|
|
gridList.push({
|
|
|
name: "项目商机",
|
|
|
@@ -146,30 +177,25 @@ Page({
|
|
|
apps: {}
|
|
|
})
|
|
|
gridList.push({
|
|
|
- name: "市场活动",
|
|
|
- path: "/packageA/activity/index",
|
|
|
- icon: "icon-xiaochengxutongxunlu",
|
|
|
- apps: {}
|
|
|
- }),
|
|
|
- gridList.push({
|
|
|
- name: "公海线索",
|
|
|
- path: "/packageA/publicClue/index",
|
|
|
- icon: "icon-xiaochengxu_xiaoshoumubiao",
|
|
|
- apps: {}
|
|
|
- })
|
|
|
- gridList.push({
|
|
|
- name: "竞争对手",
|
|
|
- path: "/packageA/opponent/index",
|
|
|
+ name: "市场活动",
|
|
|
+ path: "/packageA/activity/index",
|
|
|
icon: "icon-xiaochengxutongxunlu",
|
|
|
apps: {}
|
|
|
})
|
|
|
gridList.push({
|
|
|
- name: "公海客户",
|
|
|
- path: "/packageA/publicCustomer/index",
|
|
|
+ name: "公海线索",
|
|
|
+ path: "/packageA/publicClue/index",
|
|
|
+ icon: "icon-xiaochengxu_xiaoshoumubiao",
|
|
|
+ apps: {}
|
|
|
+ })
|
|
|
+ gridList.push({
|
|
|
+ name: "竞争对手",
|
|
|
+ path: "/packageA/opponent/index",
|
|
|
icon: "icon-xiaochengxutongxunlu",
|
|
|
apps: {}
|
|
|
})
|
|
|
|
|
|
+
|
|
|
gridList.push({
|
|
|
name: "销售预测",
|
|
|
path: "/packageA/salesForecasting/index",
|