更改自动更新

This commit is contained in:
hejin 2025-08-26 19:33:58 +08:00
parent 6c63f59aad
commit 9e88486e65
2 changed files with 6 additions and 2 deletions

View File

@ -16,6 +16,9 @@
"autoclose" : true,
"delay" : 0
},
"compatible" : {
"ignoreVersion" : true
},
/* */
"modules" : {},
/* */

View File

@ -182,12 +182,13 @@ export const useAppUpdate = defineStore('appUpdate', () => {
}
return newAppApi().then(({data:res}) => {
let appConfig = uni.getSystemInfoSync()
if (String(res.data.version) !== appConfig.appVersion) {
if (String(res.data.version) !== String(appConfig.appWgtVersion)) {
callback.value && callback.value()
loading.value = true
const downloadTask = uni.downloadFile({
url: res.data.apkUrl,
// url: res.data.apkUrl,
// url: 'https://114.132.197.85:26035/down/0JjTqTl4atsE.apk',
url: `${import.meta.env.VITE_APP_BASE_API}/web/downloadApk`,
success: res1 => {
loading.value = false
if (res1.statusCode===200) {