| | |
| | | <!-- logo --> |
| | | <view class="logo"> |
| | | <view class="logo-box"> |
| | | <image src="../../static/img/LkyLogo.jpg" mode="aspectFit"></image> |
| | | <image src="../../static/img/logo.png" mode="aspectFit"></image> |
| | | </view> |
| | | </view> |
| | | <view class="content"> |
| | |
| | | <view class="title">配置</view> |
| | | <view class="popup-item"> |
| | | <view class="popup-item-left">IP:</view> |
| | | <view class="popup-item-right"><input type="text" v-model="url.ip"></view> |
| | | <view class="popup-item-right"><input type="text" v-model="Lurl.ip"></view> |
| | | </view> |
| | | <view class="popup-item"> |
| | | <view class="popup-item-left">端口:</view> |
| | | <view class="popup-item-right"><input type="text" v-model="url.port"></view> |
| | | <view class="popup-item-right"><input type="text" v-model="Lurl.port"></view> |
| | | </view> |
| | | <view class="popup-item"> |
| | | <view class="popup-item-left">项目:</view> |
| | | <view class="popup-item-right"><input type="text" v-model="url.project"></view> |
| | | <view class="popup-item-right"><input type="text" v-model="Lurl.project"></view> |
| | | </view> |
| | | <view class="btn"> |
| | | <view class="btn-left" @click="close">取消</view> |
| | |
| | | showPassword: false, |
| | | value: '', |
| | | remberPassword: true, |
| | | url: { |
| | | Lurl: { |
| | | ip: '', |
| | | port: '', |
| | | project: '' |
| | |
| | | }, |
| | | onLoad() { |
| | | this.user = uni.getStorageSync('user') |
| | | this.url = uni.getStorageSync('url') |
| | | this.Lurl = uni.getStorageSync('Lurl') |
| | | this.baseUrl = uni.getStorageSync('baseUrl') |
| | | if (!this.user) { |
| | | this.user = {userName: '',password: ''} |
| | | } |
| | | if (!this.url) { |
| | | this.url = {ip: '',port: '',project: ''} |
| | | if (!this.Lurl) { |
| | | this.Lurl = {ip: '',port: '',project: ''} |
| | | } |
| | | }, |
| | | onShow () { |
| | |
| | | }, |
| | | // 保存ip |
| | | settingConfirm() { |
| | | this.baseUrl = "http://" + this.url.ip + ':' + this.url.port + '/' + this.url.project |
| | | this.baseUrl = "http://" + this.Lurl.ip + ':' + this.Lurl.port + '/' + this.Lurl.project |
| | | uni.setStorageSync('baseUrl', this.baseUrl); |
| | | uni.setStorageSync('url', this.url); |
| | | uni.setStorageSync('Lurl', this.Lurl); |
| | | this.$refs.inputDialog.close() |
| | | }, |
| | | onLogin() { |
| | |
| | | return |
| | | } |
| | | |
| | | let url = that.baseUrl + '/appVersion/checkUpdate/' + that.version + '/' + type |
| | | let Lurl = that.baseUrl + '/appVersion/checkUpdate/' + that.version + '/' + type |
| | | uni.request({ |
| | | url: url, |
| | | url: Lurl, |
| | | method: 'GET', |
| | | success(res) { |
| | | console.log(res); |