|
|
|
@ -50,7 +50,21 @@ Component({
@@ -50,7 +50,21 @@ Component({
|
|
|
|
|
], |
|
|
|
|
userInfo: {}, |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
observers: { |
|
|
|
|
userInfo(val) { |
|
|
|
|
if (val.IsSuper === 0) { |
|
|
|
|
this.getCaseTip(); |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
lifetimes: { |
|
|
|
|
attached() { |
|
|
|
|
this.setData({ |
|
|
|
|
showEntryCase: false, |
|
|
|
|
notice: false, |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
/** |
|
|
|
|
* 组件的方法列表 |
|
|
|
|
*/ |
|
|
|
@ -59,6 +73,7 @@ Component({
@@ -59,6 +73,7 @@ Component({
|
|
|
|
|
const { index } = e.currentTarget.dataset; |
|
|
|
|
const tab = this.data.tabbar[index]; |
|
|
|
|
if (tab.custom) { |
|
|
|
|
this.handleClsoeCaseTip(); |
|
|
|
|
wx.navigateTo({ |
|
|
|
|
url: tab.path, |
|
|
|
|
}); |
|
|
|
@ -68,5 +83,28 @@ Component({
@@ -68,5 +83,28 @@ Component({
|
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
getCaseTip() { |
|
|
|
|
wx.ajax({ |
|
|
|
|
method: "GET", |
|
|
|
|
url: "?r=takeda/case/get-case-tip", |
|
|
|
|
data: {}, |
|
|
|
|
}).then((res) => { |
|
|
|
|
this.setData({ |
|
|
|
|
showEntryCase: res.tipStatus === 2, |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
handleClsoeCaseTip() { |
|
|
|
|
this.setData({ |
|
|
|
|
showEntryCase: false, |
|
|
|
|
}); |
|
|
|
|
wx.ajax({ |
|
|
|
|
method: "POST", |
|
|
|
|
url: "?r=takeda/case/visit-case-tip", |
|
|
|
|
data: {}, |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
export {}; |
|
|
|
|