|
@@ -50,15 +50,26 @@ Component({
|
|
|
],
|
|
|
},
|
|
|
methods: {
|
|
|
- onChange(event) {
|
|
|
- let active = event.detail,
|
|
|
- obj = this.data.tabbarList.find(v => v.name == active);
|
|
|
- wx.switchTab({
|
|
|
- url: obj.url
|
|
|
- });
|
|
|
- this.setData({
|
|
|
- active
|
|
|
- });
|
|
|
+ onChange({
|
|
|
+ detail
|
|
|
+ }) {
|
|
|
+ if (detail == "smartStore") {
|
|
|
+ let item = wx.getStorageSync('gridList').find(v => v.label == '营销物料');
|
|
|
+ if (!item) return wx.showToast({
|
|
|
+ title: `暂无进入‘营销物料’应用权限`,
|
|
|
+ icon: "none",
|
|
|
+ mask: true
|
|
|
+ })
|
|
|
+ getApp().globalData.evidence(item)
|
|
|
+ } else {
|
|
|
+ const obj = this.data.tabbarList.find(v => v.name == detail);
|
|
|
+ wx.switchTab({
|
|
|
+ url: obj.url
|
|
|
+ });
|
|
|
+ this.setData({
|
|
|
+ active: detail
|
|
|
+ });
|
|
|
+ }
|
|
|
},
|
|
|
init() {
|
|
|
const page = getCurrentPages().pop();
|