|
@@ -27,13 +27,6 @@ Page({
|
|
|
}
|
|
|
})
|
|
|
console.log("详情", res)
|
|
|
- if (this.data.billData) {
|
|
|
- let userid = wx.getStorageSync('userMsg').userid;
|
|
|
- let item = this.data.billData;
|
|
|
- if (!item.team.some(v => v.userid == userid) && res.data.team.some(v => v.userid == userid)) wx.redirectTo({
|
|
|
- url: '/Eservice/workOrderDetail/index' + '?id=' + item.sa_workorderid,
|
|
|
- })
|
|
|
- }
|
|
|
this.setData({
|
|
|
billData: res.data
|
|
|
})
|
|
@@ -210,8 +203,27 @@ Page({
|
|
|
mask: true
|
|
|
});
|
|
|
if (res.code == '1') {
|
|
|
- this.mainData()
|
|
|
this.showTeamDialog()
|
|
|
+ api._post({
|
|
|
+ "id": 2025062416033402,
|
|
|
+ "content": {
|
|
|
+ "userid": wx.getStorageSync('userMsg').userid,
|
|
|
+ "sa_workorderid": this.data.billData.sa_workorderid,
|
|
|
+ },
|
|
|
+ }).then(res => {
|
|
|
+ console.log("查询权限", res)
|
|
|
+ if (res.code == 1) {
|
|
|
+ if (res.data.isteamleader || res.data.isworkleader) {
|
|
|
+ this.mainData()
|
|
|
+ } else {
|
|
|
+ wx.redirectTo({
|
|
|
+ url: '/Eservice/workOrderDetail/index?id=' + this.data.billData.sa_workorderid
|
|
|
+ })
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ this.mainData()
|
|
|
+ }
|
|
|
+ })
|
|
|
}
|
|
|
})
|
|
|
|