|
|
@@ -15,7 +15,7 @@
|
|
|
</view>
|
|
|
<view class="item_info">
|
|
|
<view class="" v-if="index==3">
|
|
|
- {{userinfo.current_version}}
|
|
|
+ {{ids}}
|
|
|
</view>
|
|
|
<view class="item_info_dian" v-if="index==3&&newversion">
|
|
|
|
|
|
@@ -38,7 +38,8 @@
|
|
|
username:""
|
|
|
},
|
|
|
tablist: ["个人中心", "监测日志", "监督记录","版本信息"],
|
|
|
- newversion:false
|
|
|
+ newversion:false,
|
|
|
+ ids:plus.runtime.version
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
@@ -54,20 +55,19 @@
|
|
|
const res = await this.$myRequest({
|
|
|
url: '/api/api_gateway?method=app.my.get_app_history',
|
|
|
data:{
|
|
|
- current_version:this.userinfo.current_version
|
|
|
+ current_version:this.ids
|
|
|
}
|
|
|
})
|
|
|
if(res.new_app.app_version){
|
|
|
- console.log(res.new_app.app_version.match(/\d+/g).join(""))
|
|
|
+ console.log(this.ids.match(/\d+/g).join(""))
|
|
|
var news = res.new_app.app_version.match(/\d+/g).join("")
|
|
|
- var old = this.userinfo.current_version.match(/\d+/g).join("")
|
|
|
+ var old = this.ids.match(/\d+/g).join("")
|
|
|
if(news > old){
|
|
|
this.newversion = true
|
|
|
}else{
|
|
|
this.newversion = false
|
|
|
}
|
|
|
}
|
|
|
- // this.userinfo = res
|
|
|
},
|
|
|
myskip(index) {
|
|
|
if (index == 0) {
|
|
|
@@ -85,7 +85,7 @@
|
|
|
});
|
|
|
}else if(index == 3){
|
|
|
uni.navigateTo({
|
|
|
- url: './version?id='+this.userinfo.current_version,
|
|
|
+ url: './version',
|
|
|
});
|
|
|
}
|
|
|
}
|