Commit 5770d85f by linjinhong

fix:修改检查更新

parent b73b8ad8
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
"name": "JomallProductionAssistant", "name": "JomallProductionAssistant",
"productName": "JomallProductionAssistant", "productName": "JomallProductionAssistant",
"description": "", "description": "",
"version": "1.0.29", "version": "1.0.27",
"private": true, "private": true,
"scripts": { "scripts": {
"serve": "vue-cli-service serve", "serve": "vue-cli-service serve",
......
...@@ -202,7 +202,7 @@ export default { ...@@ -202,7 +202,7 @@ export default {
this.$refs.updateDialog.checkUpdate().then((data) => { this.$refs.updateDialog.checkUpdate().then((data) => {
if (data) { if (data) {
// 有新版本更新 // 有新版本更新
this.$refs.updateDialog.open(data); this.$refs.updateDialog.open(data, 2);
} else { } else {
this.$message.warning("已是最新版本"); this.$message.warning("已是最新版本");
} }
......
...@@ -117,14 +117,19 @@ export default { ...@@ -117,14 +117,19 @@ export default {
} }
} }
}, },
open(data) { open(data, type) {
// console.log("更新", data); // console.log("更新", data);
this.item = data; this.item = data;
this.visible = true; this.visible = true;
if (this.version == this.item.version) { if (this.version == this.item.version) {
setSkip(2); setSkip(2);
setSkipVersion("1.0"); setSkipVersion("1.0");
} }
if (type == 2) {
setSkip(2);
setSkipVersion("1.0");
}
}, },
skipUpdate() { skipUpdate() {
setSkip(1); setSkip(1);
...@@ -134,7 +139,6 @@ export default { ...@@ -134,7 +139,6 @@ export default {
getSkipValueFn() { getSkipValueFn() {
const isSkip = getSkipValue(); const isSkip = getSkipValue();
const version = getSkipVersion(); const version = getSkipVersion();
// console.log({ isSkip, version });
return { isSkip, version }; return { isSkip, version };
}, },
...@@ -145,7 +149,7 @@ export default { ...@@ -145,7 +149,7 @@ export default {
<template> <template>
<el-dialog <el-dialog
v-if=" v-if="
getSkipValueFn().isSkip === 2 && getSkipValueFn().version !== item.version getSkipValueFn().isSkip == 2 && getSkipValueFn().version !== item.version
" "
:show-close="item.forcedUpdate === 0" :show-close="item.forcedUpdate === 0"
destroy-on-close destroy-on-close
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment