| | |
| | | <view class="main"> |
| | | <view class="header"> |
| | | <view class="titleFirst"> |
| | | 你好~<br/>欢迎来到安全教育平台</view> |
| | | 你好~<br/>欢迎来到体系合规化平台</view> |
| | | </view> |
| | | <!-- <view class="form-area"> --> |
| | | <u--form :model="form" ref="uForm" class="form" > |
| | |
| | | login(data).then(res => { |
| | | if (res.code === 200) { |
| | | t.isLogining = false; |
| | | //登录成功后 |
| | | //设置别名 |
| | | // jpushModule.setAlias({ |
| | | // 'alias': this.phone, |
| | | // 'sequence': 1 |
| | | // }) |
| | | |
| | | uni.setStorageSync("name", t.form.username); |
| | | uni.setStorageSync("pwd", t.form.password); |
| | | uni.setStorageSync("tk", res.data.token); |
| | | uni.setStorageSync("uid",res.data.id); |
| | | uni.setStorageSync('user', res.data); |
| | | // t.$store.commit('setRoleId', 'user_leader'); |
| | | uni.switchTab({ |
| | | url: '/pages/tabBar/firstPage/firstPage' |
| | | // uni.switchTab({ |
| | | // url: '/pages/tabBar/firstPage/firstPage' |
| | | // }) |
| | | uni.navigateTo({ |
| | | url: '/pages/menuPage/index' |
| | | }) |
| | | // } |
| | | }else{ |
| | | uni.showToast({ |
| | | icon: "none", |