diff --git a/templates/auto_pt/downloading.html b/templates/auto_pt/downloading.html index 742e167..be4f051 100644 --- a/templates/auto_pt/downloading.html +++ b/templates/auto_pt/downloading.html @@ -54,139 +54,173 @@ {# 复制HASH#} 暂停刷新 {# 开始刷新#} - 开始刷新 + 3S 5S + 10S 15S - 30S - 60S - -
- - - - - - - - - {# #} - - - - - + + {# #} + + {# #} + + + {# #} + + {# #} + {# #} + {# #} + {# #} + @@ -308,7 +342,14 @@ {color: '#1989fa', percentage: 80}, {color: '#6f7ad3', percentage: 100} ], - selected_rows: [] + selected_rows: [], + categoryFilters: [ + { + text: '未分类', + value: '' + } + ], + server_state: {} }, beforeMount() { }, @@ -372,6 +413,8 @@ ).then(res => { console.log(res.data) this.get_downloading(this.downloader_id) + clearInterval(this.timer) + this.timer = null this.$message({ type: 'success', message: '指令发送成功!!' @@ -438,7 +481,19 @@ ).then(res => { {#console.log(res.data.data.torrents)#} if (res.data.code === 0) { + // 获取种子 this.torrents = res.data.data.torrents + // 获取分类列表 + let categories = res.data.data.categories + // 任务状态过滤器数据 + for (let x in res.data.data.categories) { + {#console.log(download_state[x])#} + this.categoryFilters.push({ + 'text': x, + 'value': x + }) + } + this.server_state = res.data.data.server_state //this.$message({ // type: 'success', // message: '任务加载成功!!' @@ -473,7 +528,7 @@ index = Math.floor(Math.log(srcsize) / Math.log(1024)); var size = srcsize / Math.pow(1024, index); size = size.toFixed(2);//保留的小数位数 - return size + unitArr[index]; + return size + ' ' + unitArr[index]; }, // 格式化进度 handlePercent(row, column, cellValue, index) {