|
@@ -2,16 +2,14 @@
|
|
|
<view class="page-container uni-column">
|
|
|
<view class="uni-row" style="align-items: center;margin:8rpx 0 16rpx 0">
|
|
|
<image class="logo" src="../../static/images/logo.png" @click="handleShowGear" />
|
|
|
- <uni-icons v-if="showGear > 4" class="icon-gear" type="gear-filled" size="60"
|
|
|
- @click="toggle('top')"></uni-icons>
|
|
|
+ <uni-icons v-if="showGear > 4" class="icon-gear" type="gear-filled" size="60" @click="toggle('top')"></uni-icons>
|
|
|
</view>
|
|
|
<view class="title uni-row" v-if="loggedUsers.length > 0">
|
|
|
<text>点击头像切换用户</text>
|
|
|
</view>
|
|
|
<!-- 输入框示例 -->
|
|
|
<uni-popup ref="inputDialog" type="dialog" style="z-index: 2;">
|
|
|
- <uni-popup-dialog ref="inputClose" mode="input" title="手动设置" placeholder="请输入管理员密码"
|
|
|
- @confirm="dialogInputConfirm"></uni-popup-dialog>
|
|
|
+ <uni-popup-dialog ref="inputClose" mode="input" title="手动设置" placeholder="请输入管理员密码" @confirm="dialogInputConfirm"></uni-popup-dialog>
|
|
|
</uni-popup>
|
|
|
<!-- 弹出层 -->
|
|
|
<uni-popup ref="popup" background-color="#fff" style="z-index: 1;">
|
|
@@ -101,6 +99,7 @@
|
|
|
const userInfo = ref({})
|
|
|
const users = ref([])
|
|
|
const nickName = ref('')
|
|
|
+ const useInnerUrl = ref(true)
|
|
|
const baseUrl = ref(null)
|
|
|
const showGear = ref(0)
|
|
|
const appInfo = ref({})
|
|
@@ -112,9 +111,10 @@
|
|
|
const showInputDialog = ref(0)
|
|
|
|
|
|
onLoad(() => {
|
|
|
+ //uni.clearStorageSync();
|
|
|
initBaseUrl();
|
|
|
// getUser();
|
|
|
- setTimeout(doCheckUpdata, 500);
|
|
|
+ !useInnerUrl.value && setTimeout(doCheckUpdata, 500)
|
|
|
})
|
|
|
|
|
|
onReady(() => {
|
|
@@ -124,7 +124,6 @@
|
|
|
function doCheckUpdata() {
|
|
|
checkUpdate().then(res => {
|
|
|
updateFlag.value = res;
|
|
|
- console.log(res)
|
|
|
if (!res) {
|
|
|
uni.showModal({
|
|
|
title: '更新',
|
|
@@ -146,12 +145,10 @@
|
|
|
appInfo.value = res;
|
|
|
}
|
|
|
});
|
|
|
- console.log(appInfo.value);
|
|
|
// false 版本号不一致,更新,true不需要更新
|
|
|
let flag = getAppInfoListByType(path.checkAppURL, {
|
|
|
type: appInfo.value.osName
|
|
|
}).then(res => {
|
|
|
- console.log(res);
|
|
|
newAppInfo.value = res.rows[0];
|
|
|
if (res.rows[0]) {
|
|
|
return appInfo.value.appWgtVersion === newAppInfo.value.versionName;
|
|
@@ -164,8 +161,6 @@
|
|
|
|
|
|
function update() {
|
|
|
upgrade.downloadInstallApp(path.updateAppURL + newAppInfo.value.url);
|
|
|
- console.log(newAppInfo.value)
|
|
|
- console.log(path.updateAppURL + newAppInfo.value.url)
|
|
|
}
|
|
|
|
|
|
function init() {
|
|
@@ -173,7 +168,6 @@
|
|
|
success: function(res) {
|
|
|
for (let i = 0; i < res.keys.length; i++) {
|
|
|
let storagekey = res.keys[i];
|
|
|
- console.log(storagekey)
|
|
|
uni.getStorage({
|
|
|
key: storagekey,
|
|
|
success: function(res) {
|
|
@@ -204,10 +198,10 @@
|
|
|
|
|
|
function initBaseUrl() {
|
|
|
let urlList = {
|
|
|
- baseUrl: path.baseURL,
|
|
|
- checkAppURL: path.checkAppURL,
|
|
|
- updateAppURL: path.updateAppURL,
|
|
|
- furnaceNoURL: path.furnaceNoURL
|
|
|
+ baseUrl: useInnerUrl ? path.innerURL : path.baseURL,
|
|
|
+ checkAppURL: useInnerUrl ? '' : path.checkAppURL,
|
|
|
+ updateAppURL: useInnerUrl ? path.innerUpdateAppURL : path.updateAppURL,
|
|
|
+ furnaceNoURL: useInnerUrl ? path.innerFurnaceNoURL : path.furnaceNoURL
|
|
|
}
|
|
|
uni.getStorage({
|
|
|
key: 'baseUrl',
|
|
@@ -313,7 +307,6 @@
|
|
|
}
|
|
|
|
|
|
const handleLongPressUser = (user) => {
|
|
|
- console.log(user)
|
|
|
uni.showModal({
|
|
|
title: '提示', // 标题
|
|
|
content: '是否删除此账号', // 提示内容
|