gtsoft-snail-job-server/frontend/src/views/task/RetryLogInfo.vue

100 lines
2.8 KiB
Vue
Raw Normal View History

2023-01-14 21:02:18 +08:00
<template>
<div>
<page-header-wrapper @back="() => $router.go(-1)" style='margin: -24px -1px 0'>
<div></div>
2023-01-14 21:02:18 +08:00
</page-header-wrapper>
<a-card :bordered="false">
<a-descriptions title="" bordered>
<a-descriptions-item label="组名称">
{{ retryInfo.groupName }}
</a-descriptions-item>
<a-descriptions-item label="场景名称">
{{ retryInfo.sceneName }}
</a-descriptions-item>
<a-descriptions-item label="唯一id">
{{ retryInfo.uniqueId }}
</a-descriptions-item>
<a-descriptions-item label="幂等id" :span="2">
{{ retryInfo.idempotentId }}
</a-descriptions-item>
<a-descriptions-item label="业务编号">
{{ retryInfo.bizNo }}
</a-descriptions-item>
<a-descriptions-item label="下次触发时间">
{{ parseDate(retryInfo.nextTriggerAt) }}
</a-descriptions-item>
<a-descriptions-item label="执行时间">
{{ parseDate( retryInfo.createDt) }}
</a-descriptions-item>
2023-06-06 23:23:59 +08:00
<a-descriptions-item label="当前重试状态 | 数据类型">
<a-tag color="red">
{{ retryStatus[retryInfo.retryStatus] }}
</a-tag>
2023-06-06 23:23:59 +08:00
<a-divider type="vertical" />
<a-tag :color="taskType[retryInfo.taskType].color">
{{ taskType[retryInfo.taskType].name }}
</a-tag>
</a-descriptions-item>
<a-descriptions-item label="执行器名称" :span="3">
{{ retryInfo.executorName }}
</a-descriptions-item>
<a-descriptions-item label="参数" :span="3">
{{ retryInfo.argsStr }}
</a-descriptions-item>
<a-descriptions-item label="失败原因" :span="3">
{{ retryInfo.errorMessage }}
</a-descriptions-item>
<a-descriptions-item label="扩展参数" :span="3">
{{ retryInfo.extAttrs }}
</a-descriptions-item>
</a-descriptions>
</a-card>
2023-01-14 21:02:18 +08:00
</div>
</template>
<script>
import { getRetryTaskLogById } from '@/api/manage'
import moment from 'moment'
export default {
name: 'RetryLogInfo',
data () {
return {
retryInfo: {},
retryStatus: {
'0': '处理中',
'1': '处理成功',
2023-01-14 21:02:18 +08:00
'2': '最大次数'
2023-06-06 23:23:59 +08:00
},
taskType: {
'1': {
'name': '重试数据',
'color': '#d06892'
},
'2': {
'name': '回调数据',
'color': '#f5a22d'
}
2023-01-14 21:02:18 +08:00
}
}
},
created () {
const id = this.$route.query.id
if (id) {
getRetryTaskLogById(id).then(res => {
this.retryInfo = res.data
})
}
},
methods: {
parseDate (date) {
return moment(date).format('YYYY-MM-DD HH:mm:ss')
}
}
}
</script>
<style scoped>
</style>