| | |
| | | <view>记住密码</view> |
| | | </view> |
| | | <view class="check-right"> |
| | | <switch checked color="#FFCC33" style="zoom:.5" @change="remberChange"/> |
| | | <switch :checked='remberPassword' color="#FFCC33" style="zoom:.5" @change="remberChange"/> |
| | | </view> |
| | | </view> |
| | | </view> |
| | |
| | | version: '', |
| | | showPassword: false, |
| | | value: '', |
| | | remberPassword: true, |
| | | url: { |
| | | ip: '', |
| | | port: '', |
| | |
| | | this.url = uni.getStorageSync('url') |
| | | this.baseUrl = uni.getStorageSync('baseUrl') |
| | | if (!this.user) { |
| | | this.user = {userName: '',password: '',} |
| | | this.user = {userName: '',password: ''} |
| | | } |
| | | if (!this.url) { |
| | | this.url = {ip: '',port: '',project: ''} |
| | | } |
| | | |
| | | // 手机端版本号 |
| | |
| | | this.showPassword = !this.showPassword; |
| | | }, |
| | | remberChange(e) { |
| | | console.log(e.detail); |
| | | this.remberPassword = !this.remberPassword |
| | | }, |
| | | // 设置窗口开启按钮 |
| | | settings() { |
| | |
| | | that.load.loading = true; |
| | | that.load.btnText = '登录中'; |
| | | uni.setStorageSync('token', res.data.token); |
| | | if(that.remberPassword){ |
| | | uni.setStorageSync('user', that.user); |
| | | }else{ |
| | | uni.removeStorageSync('user'); |
| | | } |
| | | setTimeout(() => { |
| | | uni.showToast({ |
| | | title: '登录成功' |