diff --git a/App.vue b/App.vue
index 50a39ac..86f486d 100644
--- a/App.vue
+++ b/App.vue
@@ -57,6 +57,27 @@
}
});
// #endif
+ uni.getSystemInfo({
+ success(res) {
+ if (res.platform == 'android') {
+ that.$u.api.apkCheck().then(res1 => {
+ if (res.appVersion < res1.version) {
+ uni.showModal({
+ title: "版本更新",
+ content: '有新的版本发布, 请下载新版本',
+ confirmText: '立即更新',
+ showCancel: false,
+ success: function(res2) {
+ if (res2.confirm) {
+ plus.runtime.openURL(res1.file)
+ }
+ }
+ });
+ }
+ })
+ }
+ }
+ })
// #ifdef APP-PLUS
uni.showLoading({
title: '自动登录中...',
@@ -64,10 +85,10 @@
})
uni.getStorage({
key: 'mySecret',
- success: function (res) {
+ success: function(res) {
let secret = res.data
- if(secret){
- that.$u.api.loginSecret(JSON.parse(secret)).then(res=>{
+ if (secret) {
+ that.$u.api.loginSecret(JSON.parse(secret)).then(res => {
that.$u.api.getUserInfo().then(res => {
that.$u.vuex('vuex_user', res)
// 修改资源请求地址
@@ -77,7 +98,7 @@
})
})
}
-
+
},
complete() {
uni.hideLoading()
diff --git a/common/http.api.js b/common/http.api.js
index ec834b2..be6e2cf 100644
--- a/common/http.api.js
+++ b/common/http.api.js
@@ -27,6 +27,7 @@ const install = (Vue, vm) => {
let unbindmp = (data = {}) => vm.$u.post('/system/user/unbind_wxmp/', data); //微信小程序解绑
let bindSecret = (data = {}) => vm.$u.post('/system/user/bind_secret/', data); //App密钥绑定
+ let apkCheck = ()=>vm.$u.get('/system/apk/'); //apk检查
let getDickey = (params = {}) => vm.$u.get('/system/dict/', params); //查询字典
@@ -92,6 +93,7 @@ const install = (Vue, vm) => {
unbindmp,
bindSecret,
loginSecret,
+ apkCheck,
userList,
deptList,
diff --git a/manifest.json b/manifest.json
index f3d149d..2df70f9 100644
--- a/manifest.json
+++ b/manifest.json
@@ -2,8 +2,8 @@
"name" : "曲阳金隅EHS",
"appid" : "__UNI__B00D419",
"description" : "曲阳金隅EHS",
- "versionName" : "1.0.0",
- "versionCode" : "100",
+ "versionName" : "1.00.01",
+ "versionCode" : 10001,
"transformPx" : false,
/* 5+App特有相关 */
"app-plus" : {
@@ -15,12 +15,8 @@
"delay" : 0
},
"modules" : {
- "OAuth" : {},
- "Payment" : {},
- "Push" : {},
- "Share" : {},
- "Speech" : {},
- "VideoPlayer" : {}
+ "VideoPlayer" : {},
+ "Push" : {}
},
/* 应用发布信息 */
"distribute" : {
@@ -63,7 +59,8 @@
},
/* ios打包配置 */
"ios" : {
- "UIBackgroundModes" : [ "audio" ]
+ "UIBackgroundModes" : [ "audio" ],
+ "dSYMs" : false
},
/* SDK配置 */
"sdkConfigs" : {
diff --git a/pages/home/home_.vue b/pages/home/home_.vue
index 3b9ec14..5602cdb 100644
--- a/pages/home/home_.vue
+++ b/pages/home/home_.vue
@@ -46,7 +46,7 @@
实时报警
-
+
查看更多
@@ -257,7 +257,7 @@
color: #5b5b5b;
overflow: hidden;
text-overflow: ellipsis;
- display: box;
+ display: flex;
display: -webkit-box;
line-clamp: 2;
-webkit-line-clamp: 2;