{% extends "base.html" %} {% block title %}TaskWatch - {{ task.name }}{% endblock %} {% block content %}

{{ task.name }}

ID: {{ task.id }} | {{ task.schedule_type }}: {{ task.schedule }}

任务信息

命令:{{ task.command }}
超时:{{ task.timeout }}s
重试:{{ task.retry }} 次
重试间隔:{{ task.retry_interval }}s
工作目录:{{ task.working_dir or '当前目录' }}
通知策略:{{ task.notify }}
标签:{{ task.tags or '-' }}
状态: {% if task.enabled %} 启用 {% else %} 禁用 {% endif %}
{{ stats.total_runs }}
总运行次数
{{ stats.success_rate }}%
成功率
{{ stats.avg_duration_ms }}ms
平均耗时

最近运行记录

查看全部日志
{% for run in recent_runs %} {% endfor %} {% if not recent_runs %} {% endif %}
Run ID 开始时间 状态 耗时 触发方式
{{ run.id }} {{ run.start_time[:19] if run.start_time else '-' }} {% if run.status == 'success' %} 成功 {% elif run.status == 'failed' %} 失败 {% elif run.status == 'timeout' %} 超时 {% elif run.status == 'running' %} 运行中 {% else %} {{ run.status }} {% endif %} {{ run.duration_display }} {{ run.trigger }}
暂无运行记录
{% endblock %} {% block scripts %} {% endblock %}