|
|
@@ -113,6 +113,35 @@
|
|
|
align="center"
|
|
|
:formatter="(row) => timeFormatter(row, 'startTime')"
|
|
|
></ElTableColumn>
|
|
|
+ <ElTableColumn
|
|
|
+ prop="result"
|
|
|
+ label="执行状态"
|
|
|
+ align="center"
|
|
|
+ width="100"
|
|
|
+ :filters="[{ text: '成功', value: '成功' }, { text: '失败', value: '失败' }]"
|
|
|
+ :filter-method="(value, row) => {
|
|
|
+ return row.result === value;
|
|
|
+ }"
|
|
|
+ filter-placement="bottom-end"
|
|
|
+ >
|
|
|
+ <template #default="scope">
|
|
|
+ <template v-if="scope.row.result === '部署成功'">
|
|
|
+ <ElTag type="success">{{scope.row.result}}</ElTag>
|
|
|
+ </template>
|
|
|
+ <template v-else-if="scope.row.result === '部署失败'">
|
|
|
+ <ElTag type="danger">{{scope.row.result}}</ElTag>
|
|
|
+ </template>
|
|
|
+ <template v-else-if="scope.row.result === '部署中'">
|
|
|
+ <ElTag>{{scope.row.result}}<i class="el-icon-loading"></i></ElTag>
|
|
|
+ </template>
|
|
|
+ <template v-else-if="scope.row.result === '无执行记录'">
|
|
|
+ <ElTag>{{scope.row.result}}</ElTag>
|
|
|
+ </template>
|
|
|
+ <template v-else>
|
|
|
+ <ElTag type="warning">未知状态</ElTag>
|
|
|
+ </template>
|
|
|
+ </template>
|
|
|
+ </ElTableColumn>
|
|
|
<ElTableColumn>
|
|
|
<template #default="scope">
|
|
|
<ElButton @click="handleClick('detail', scope.row.id)" type="text" size="small">查看详情</ElButton>
|