| | |
| | | }) |
| | | }, |
| | | save(){ |
| | | let self = this |
| | | console.log(this.data.userInfo.mblNo,this.data.newTwo,this.data.info) |
| | | if(validator.checkValEmpty(this.data.info.oldPwd)){ |
| | | my.showToast({ |
| | |
| | | }); |
| | | return |
| | | } |
| | | let p = new Promise(function (re, rej) { |
| | | $api.ajax( |
| | | '/sib/user/updatePwd', |
| | | 'POST', |
| | | (res)=>{ |
| | | |
| | | my.showToast({ |
| | | content:'修改成功', |
| | | duration:3000, |
| | | success:()=>{ |
| | | re() |
| | | } |
| | | }) |
| | | }, |
| | | (err)=>{ |
| | | |
| | | }, |
| | | true, |
| | | { |
| | | newPwd: md5.hex_md5(this.data.userInfo.mblNo+this.data.info.newPwd), |
| | | oldPwd: md5.hex_md5(this.data.userInfo.mblNo+this.data.info.oldPwd) |
| | | newPwd: md5.hex_md5(self.data.userInfo.mblNo + self.data.info.newPwd), |
| | | oldPwd: md5.hex_md5(self.data.userInfo.mblNo + self.data.info.oldPwd) |
| | | } |
| | | ) |
| | | |
| | | }) |
| | | p.then(() => { |
| | | $api.ajax( |
| | | '/sib/xcx/login/logout', |
| | | 'POST', |
| | | res => { |
| | | my.removeStorageSync({ |
| | | key: 'sessionId', |
| | | }); |
| | | my.navigateTo({ |
| | | url: '/pages/index/index' |
| | | }); |
| | | }, |
| | | err => { |
| | | |
| | | }, |
| | | true |
| | | ) |
| | | }) |
| | | |
| | | } |
| | | }); |