diff --git a/package-lock.json b/package-lock.json index 2ae6aa3..cca7405 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,5 +1,5 @@ { - "name": "baihu2", + "name": "baihu", "lockfileVersion": 3, "requires": true, "packages": { diff --git a/web/package-lock.json b/web/package-lock.json index 50d6a2d..602174d 100644 --- a/web/package-lock.json +++ b/web/package-lock.json @@ -22,7 +22,7 @@ "chart.js": "^4.5.1", "class-variance-authority": "^0.7.1", "clsx": "^2.1.1", - "cronstrue": "^3.13.0", + "cronstrue": "^3.14.0", "date-fns": "^4.1.0", "lucide-react": "^0.562.0", "lucide-vue-next": "^0.562.0", diff --git a/web/package.json b/web/package.json index dc9b1c7..d4bcb43 100644 --- a/web/package.json +++ b/web/package.json @@ -23,7 +23,7 @@ "chart.js": "^4.5.1", "class-variance-authority": "^0.7.1", "clsx": "^2.1.1", - "cronstrue": "^3.13.0", + "cronstrue": "^3.14.0", "date-fns": "^4.1.0", "lucide-react": "^0.562.0", "lucide-vue-next": "^0.562.0", diff --git a/web/src/components/LogDetailCard.vue b/web/src/components/LogDetailCard.vue index 2c89394..5b39a0a 100644 --- a/web/src/components/LogDetailCard.vue +++ b/web/src/components/LogDetailCard.vue @@ -2,13 +2,13 @@ import { ref } from 'vue' import { X, Trash2, Maximize2, CheckCircle2, XCircle, AlertCircle, Clock, Ban, - Zap as ZapIcon, Search + Zap as ZapIcon, Search, MinusCircle } from 'lucide-vue-next' import { Badge } from '@/components/ui/badge' import { Button } from '@/components/ui/button' import { Input } from '@/components/ui/input' import LogContent from './LogContent.vue' -import { TASK_STATUS } from '@/constants' +import { TASK_STATUS, TASK_STATUS_TEXT } from '@/constants' import type { TaskLog } from '@/api' interface Props { @@ -19,6 +19,8 @@ interface Props { isStopping?: boolean showClose?: boolean variant?: 'full' | 'simple' + emptyTitle?: string + emptyDescription?: string } const props = withDefaults(defineProps(), { @@ -28,7 +30,9 @@ const props = withDefaults(defineProps(), { loading: false, isStopping: false, showClose: true, - variant: 'full' + variant: 'full', + emptyTitle: undefined, + emptyDescription: undefined }) defineEmits<{ @@ -60,6 +64,8 @@ function getStatusBadgeClass(status: string) { return 'bg-orange-500/10 text-orange-600 border-orange-500/20 dark:bg-orange-500/20 dark:text-orange-400 dark:border-orange-500/30' case TASK_STATUS.CANCELLED: return 'bg-muted/50 text-muted-foreground border-muted-foreground/10' + case 'UNEXECUTED': + return 'bg-muted/30 text-muted-foreground/60 border-dashed border-muted-foreground/20 shadow-none' default: return 'bg-secondary text-secondary-foreground border-transparent' } @@ -75,10 +81,10 @@ function getStatusBadgeClass(status: string) { - {{ log.status }} + {{ TASK_STATUS_TEXT[log.status] || log.status }}