Commit 5702998a authored by 15011343103's avatar 15011343103

feat

parent 42ba02d2
......@@ -98,7 +98,6 @@ new Vue({
methods: {
// 心跳实时查询异步处理进度及信息
async checkProcess(_data) {
let data = _data;
if (!data) {
data = await new Promise((resolve) => {
......@@ -110,6 +109,10 @@ new Vue({
if (data && data.data_type == 'AI_QUEUE') {
// 更新队列任务列表
this.queueTasks = data.rows;
// 滚动到底部
this.$nextTick(() => {
this.scrollToBottom();
});
// 继续检查进度
await new Promise(resolve => setTimeout(resolve, 1000));
this.checkProcess();
......@@ -2422,6 +2425,15 @@ new Vue({
const seconds = String(date.getSeconds()).padStart(2, '0');
return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`;
},
scrollToBottom() {
this.$nextTick(() => {
const processContent = document.querySelector('.process-content');
if (processContent) {
processContent.scrollTop = processContent.scrollHeight;
}
});
},
},
beforeDestroy() {
......
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