Admin.UI/src/views/admin/task/index.vue
(开头部分) 8KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
<template>
<my-container v-loading="pageLoading">
<!--查询-->
<template #header>
<el-form class="ad-form-query" :inline="true" :model="filter" @submit.native.prevent>
<el-form-item>
<el-input
v-model="filter.topic"
placeholder="任务名称"
clearable
@keyup.enter.native="onSearch"
>
<template #prefix>
<i class="el-input__icon el-icon-search" />
</template>
</el-input>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="onSearch">查询</el-button>
</el-form-item>
</el-form>
</template>
<!--列表-->
<el-table
v-loading="listLoading"
:data="tasks"
highlight-current-row
height="'100%'"
style="width: 100%;height:100%;"
>
<template #empty>
<el-empty :image-size="100" />
</template>
<el-table-column prop="id" label="任务编号" width="120" />
<el-table-column prop="topic" label="任务名称" min-width="120" />
<el-table-column prop="status" label="任务状态" width="80">
<template #default="{row}">
<el-tag v-if="row.status === 0 || row.status === 'Running'" disable-transitions>运行中</el-tag>
<el-tag v-if="row.status === 1 || row.status === 'Paused'" type="info" disable-transitions>暂停</el-tag>
<el-tag v-if="row.status === 2 || row.status === 'Completed'" type="success" disable-transitions>完成</el-tag>
</template>
</el-table-column>
<el-table-column prop="round" label="运行次数" width="80" />
<el-table-column prop="currentRound" label="当前次数" width="80" />
<el-table-column prop="body" label="任务数据" min-width="180" />
<el-table-column prop="interval" label="定时类型" width="100" :formatter="formatInterval" />
<el-table-column prop="intervalArgument" label="定时参数" min-width="180" />
<el-table-column prop="errorTimes" label="失败次数" width="80" />
<el-table-column prop="createTime" label="创建时间" :formatter="formatCreatedTime" width="100" />
<el-table-column prop="lastRunTime" label="最后运行时间" :formatter="formatCreatedTime" width="100" />
<el-table-column
fixed="right"
label="操作"
width="180"
>
<template #default="{ row }">
<el-button v-if="checkPermission(['api:admin:task-log:get-page'])" type="text" size="small" icon="el-icon-tickets" @click="onLog(row)">日志</el-button>
<my-confirm-button
v-if="checkPermission(['api:admin:task:resume']) && (row.status === 1 || row.status === 'Paused')"
后面还有 260 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
