From 05bbd59cf7e1ca6f0a364a573226971b98dc2e57 Mon Sep 17 00:00:00 2001 From: yujk <990961482@qq.com> Date: Thu, 14 Apr 2022 08:35:00 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/apply/approval/approval.js | 8 ++++---- pages/index/index.js | 1 + pages/index/index.wxml | 2 +- pages/index/index.wxss | 3 ++- 4 files changed, 8 insertions(+), 6 deletions(-) diff --git a/pages/apply/approval/approval.js b/pages/apply/approval/approval.js index 7553c2f..c18be7a 100644 --- a/pages/apply/approval/approval.js +++ b/pages/apply/approval/approval.js @@ -44,6 +44,7 @@ Page({ ], //事务总表对象 item:{}, + detpId:187, itemId:13, active:0, result:[], @@ -62,8 +63,7 @@ Page({ * 生命周期函数--监听页面加载 */ onLoad(options) { - this.setData({itemId:options.id}); - console.log(options) + this.setData({itemId:options.id,deptId:options.deptId}); //this.getApprovalItemList(); this.groupList(); this.townList(); @@ -256,7 +256,7 @@ Page({ }, groupList:function(){ let data = { - deptId : 187, + deptId : this.data.deptId, deptLevel:1 } UTIL.httpRequest(API.URL_GET_USERLIST,data ,{ @@ -270,7 +270,7 @@ Page({ }, villageList:function(){ let data = { - deptId : 187, + deptId : this.data.deptId, deptLevel:2 } UTIL.httpRequest(API.URL_GET_USERLIST,data ,{ diff --git a/pages/index/index.js b/pages/index/index.js index c9bfd9f..3736bad 100644 --- a/pages/index/index.js +++ b/pages/index/index.js @@ -276,6 +276,7 @@ Page({ success: (res) => { if (res.code == API.SUCCESS_CODE) { this.setData({userInfoObj:res.user}) + console.log(res.user); this.setData({region:res.user.deptName}) this.setData({item:JSON.stringify(res.user)}) this.getBookList() diff --git a/pages/index/index.wxml b/pages/index/index.wxml index 7d79f60..33c0ce4 100644 --- a/pages/index/index.wxml +++ b/pages/index/index.wxml @@ -11,7 +11,7 @@ {{userInfoObj.nickName}} - {{userInfoObj.remark}} + {{userInfoObj.roles.length>0?userInfoObj.roles[0].roleName:""}} diff --git a/pages/index/index.wxss b/pages/index/index.wxss index 1c90d02..6cc69ac 100644 --- a/pages/index/index.wxss +++ b/pages/index/index.wxss @@ -39,7 +39,7 @@ } .information_header .name_wrap .jobs{ margin-left: 18rpx; - width: 155rpx; + /* width: 155rpx; */ height: 40rpx; background: #5bae75; border:2rpx solid #2c8e68; @@ -49,6 +49,7 @@ font-size: 28rpx; justify-content: center; align-items: center; + padding: 0 20rpx; } .information_header .name_wrap .jobs .icon{ width: 26rpx; From 5ca55b30f25fea81421c73b96b9ee422aedd676f Mon Sep 17 00:00:00 2001 From: yujk <990961482@qq.com> Date: Fri, 15 Apr 2022 16:52:59 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/index/index.js | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/pages/index/index.js b/pages/index/index.js index ea9eca7..f9b9df5 100644 --- a/pages/index/index.js +++ b/pages/index/index.js @@ -305,7 +305,8 @@ Page({ /* 获取账套*/ getBookList:function(){ let d = { - loginDeptID : this.data.userInfoObj.loginDeptId + loginDeptID : this.data.userInfoObj.loginDeptId, + method:'GET' } UTIL.httpRequest(API.URL_GET_BOOKLISTBYDEPTID,d, { success: (res) => { @@ -331,7 +332,8 @@ Page({ bookName:this.data.bookList[e.detail.value].bookName }) let data={ - loginBookId:this.data.bookList[e.detail.value].id + loginBookId:this.data.bookList[e.detail.value].id, + method:'GET' } let _this = this UTIL.httpRequest(API.URL_GET_CHANGEBOOK,data, { @@ -453,7 +455,8 @@ Page({ bookId:"" }, () => { let data={ - loginDeptID : this.getRegionId('areas') + loginDeptID : this.getRegionId('areas'), + method:'GET' } let _this = this UTIL.httpRequest(API.URL_GET_CHANGEDEPT,data, { From df44a02efed11957a8341aa848254fd6decdba83 Mon Sep 17 00:00:00 2001 From: yujk <990961482@qq.com> Date: Fri, 15 Apr 2022 16:53:36 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/apply/approval/approval.js | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/pages/apply/approval/approval.js b/pages/apply/approval/approval.js index c18be7a..5db9ee3 100644 --- a/pages/apply/approval/approval.js +++ b/pages/apply/approval/approval.js @@ -64,6 +64,7 @@ Page({ */ onLoad(options) { this.setData({itemId:options.id,deptId:options.deptId}); + console.log(options); //this.getApprovalItemList(); this.groupList(); this.townList(); @@ -87,7 +88,8 @@ Page({ let d = { templateId : _this.data.item.templateId, orderByColumn:"id", - isAsc:"asc" + isAsc:"asc", + method:"GET" } UTIL.httpRequest(API.URL_GET_TEMPLATEDETAIL, d, { success: (r) => { @@ -168,7 +170,8 @@ Page({ let data={ dataType:0, pageNum:1, - pageSize:50 + pageSize:50, + method:"GET" } UTIL.httpRequest(API.URL_GET_TEMPLATELIST, data, { success: (res) => { @@ -178,7 +181,8 @@ Page({ let d = { templateId : res.rows[0].id, orderByColumn:"id", - isAsc:"asc" + isAsc:"asc", + method:"GET" } UTIL.httpRequest(API.URL_GET_TEMPLATEDETAIL, d, { success: (r) => { @@ -201,7 +205,8 @@ Page({ let data = { templateId : e.currentTarget.dataset.id, orderByColumn:"id", - isAsc:"asc" + isAsc:"asc", + method:"GET" } UTIL.httpRequest(API.URL_GET_TEMPLATEDETAIL, data, { success: (res) => { @@ -241,7 +246,8 @@ Page({ success: function (response) { let d = { deptId:response.data.data.deptId, - deptLevel:3 + deptLevel:3, + method:"GET" } UTIL.httpRequest(API.URL_GET_USERLIST,d,{ success: (res) => { @@ -257,7 +263,8 @@ Page({ groupList:function(){ let data = { deptId : this.data.deptId, - deptLevel:1 + deptLevel:1, + method:"GET" } UTIL.httpRequest(API.URL_GET_USERLIST,data ,{ success: (res) => { @@ -271,7 +278,8 @@ Page({ villageList:function(){ let data = { deptId : this.data.deptId, - deptLevel:2 + deptLevel:2, + method:"GET" } UTIL.httpRequest(API.URL_GET_USERLIST,data ,{ success: (res) => {