|
|
|
@@ -164,6 +164,7 @@ export default { |
|
|
|
defaultAvatarName:'Ghost', |
|
|
|
data:'', |
|
|
|
timer:null, |
|
|
|
timerFlag:false, |
|
|
|
}; |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
@@ -390,6 +391,13 @@ export default { |
|
|
|
return "Other" |
|
|
|
} |
|
|
|
}, |
|
|
|
intervalModelist(){ |
|
|
|
if(!this.timerFlag){ |
|
|
|
this.timer = setInterval(()=>{ |
|
|
|
this.getModelList() |
|
|
|
}, 10000); |
|
|
|
} |
|
|
|
}, |
|
|
|
getModelList(){ |
|
|
|
let countStatus = 0 |
|
|
|
try { |
|
|
|
@@ -430,10 +438,12 @@ export default { |
|
|
|
this.totalNum = res.data.count |
|
|
|
if(countStatus===this.tableData.length){ |
|
|
|
clearInterval(this.timer); |
|
|
|
this.timer=null |
|
|
|
this.timerFlag = false |
|
|
|
}else{ |
|
|
|
this.intervalModelist() |
|
|
|
this.timerFlag = true |
|
|
|
} |
|
|
|
// if(res.data.count===1 && res.data.data[0].VersionCount===1){ |
|
|
|
// location.reload() |
|
|
|
// } |
|
|
|
}).catch((err)=>{console.log(err)}) |
|
|
|
}catch (e) { |
|
|
|
console.log(e) |
|
|
|
@@ -478,9 +488,7 @@ export default { |
|
|
|
}, |
|
|
|
mounted() { |
|
|
|
this.submitId = document.getElementById("submitId") |
|
|
|
this.timer = setInterval(()=>{ |
|
|
|
this.getModelList() |
|
|
|
}, 10000); |
|
|
|
this.intervalModelist() |
|
|
|
this.url = location.href.split('show_model')[0] |
|
|
|
this.submitId.addEventListener("click", this.submit) |
|
|
|
this.url_create_newVersion = this.url + 'create_model' |
|
|
|
|