From 3b3cb1ff241d2f29e8082e5ab5d30d962d5850b1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=80=97=E5=AD=90?= Date: Thu, 17 Oct 2024 12:09:00 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20CLI=E4=B8=8B=E4=B8=8D=E8=BF=90=E8=A1=8C?= =?UTF-8?q?=E9=98=9F=E5=88=97=E5=88=86=E5=8F=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- internal/data/task.go | 5 +++++ web/src/views/home/IndexView.vue | 18 ++++++++++++++++++ 2 files changed, 23 insertions(+) diff --git a/internal/data/task.go b/internal/data/task.go index cf1af955..58412319 100644 --- a/internal/data/task.go +++ b/internal/data/task.go @@ -57,6 +57,11 @@ func (r *taskRepo) Push(task *biz.Task) error { } func (r *taskRepo) DispatchWaiting() { + // cli下不处理 + if app.IsCli { + return + } + var tasks []biz.Task if err := app.Orm.Where("status = ?", biz.TaskStatusWaiting).Find(&tasks).Error; err != nil { app.Logger.Error("获取待处理任务失败", zap.Error(err)) diff --git a/web/src/views/home/IndexView.vue b/web/src/views/home/IndexView.vue index 7f2da70c..d854c512 100644 --- a/web/src/views/home/IndexView.vue +++ b/web/src/views/home/IndexView.vue @@ -132,6 +132,15 @@ const chartDisk = computed(() => { }, markLine: { data: [{ type: 'average', name: '平均值' }] + }, + lineStyle: { + color: 'rgb(247, 184, 81)' + }, + itemStyle: { + color: 'rgb(247, 184, 81)' + }, + areaStyle: { + color: 'rgb(247, 184, 81)' } }, { @@ -147,6 +156,15 @@ const chartDisk = computed(() => { }, markLine: { data: [{ type: 'average', name: '平均值' }] + }, + lineStyle: { + color: 'rgb(82, 169, 255)' + }, + itemStyle: { + color: 'rgb(82, 169, 255)' + }, + areaStyle: { + color: 'rgb(82, 169, 255)' } } ]