fix: 2.5.0

1. 修复看板重试场景列表统计错误
2. 修复通知和场景列表页查询问题
3. 删除retry_summary的多余索引问题
This commit is contained in:
byteblogs168 2023-12-05 18:32:38 +08:00
parent fe176790d7
commit 66d1ba1831
6 changed files with 12 additions and 24 deletions

View File

@ -435,8 +435,7 @@ CREATE TABLE `retry_summary`
`create_dt` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
`update_dt` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '修改时间',
PRIMARY KEY (`id`),
KEY `idx_namespace_id_group_name_scene_name` (`namespace_id`, `group_name`, scene_name),
UNIQUE KEY `uk_scene_name_trigger_at` (`namespace_id`, `group_name`, `scene_name`, `trigger_at`) USING BTREE
) ENGINE = InnoDB
AUTO_INCREMENT = 1
DEFAULT CHARSET = utf8mb4 COMMENT ='DashBoard_Retry';
DEFAULT CHARSET = utf8mb4 COMMENT ='DashBoard_Retry';

View File

@ -157,9 +157,9 @@
<select id="retryTaskList"
resultType="com.aizuda.easy.retry.template.datasource.persistence.dataobject.DashboardRetryLineResponseDO$Task">
SELECT group_name AS groupName,
sum(CASE WHEN (group_status = 1) THEN 1 ELSE 0 END) AS run,
sum(CASE WHEN (scene_status = 1) THEN 1 ELSE 0 END) AS run,
count(*) AS total
FROM group_config
FROM scene_config
WHERE namespace_id = #{namespaceId}
GROUP BY namespace_id, group_name
</select>

View File

@ -177,22 +177,21 @@ public class RetryTaskServiceImpl implements RetryTaskService {
}
if (RetryStatusEnum.FINISH.getStatus().equals(retryStatusEnum.getStatus())) {
RetryTaskLogMessage retryTaskLogMessage = new RetryTaskLogMessage();
retryTaskLogMessage.setUniqueId(retryTask.getUniqueId());
retryTaskLogMessage.setGroupName(retryTask.getGroupName());
retryTaskLogMessage.setMessage("手动操作完成");
retryTaskLogMessage.setCreateDt(LocalDateTime.now());
retryTaskLogMessageMapper.insert(retryTaskLogMessage);
RetryTaskLog retryTaskLog = new RetryTaskLog();
retryTaskLog.setRetryStatus(RetryStatusEnum.FINISH.getStatus());
retryTaskLogMapper.update(retryTaskLog, new LambdaUpdateWrapper<RetryTaskLog>()
.eq(RetryTaskLog::getNamespaceId, namespaceId)
.eq(RetryTaskLog::getUniqueId, retryTask.getUniqueId())
.eq(RetryTaskLog::getGroupName, retryTask.getGroupName()));
}
RetryTaskLog retryTaskLog = new RetryTaskLog();
retryTaskLog.setRetryStatus(requestVO.getRetryStatus());
retryTaskLogMapper.update(retryTaskLog, new LambdaUpdateWrapper<RetryTaskLog>()
.eq(RetryTaskLog::getNamespaceId, namespaceId)
.eq(RetryTaskLog::getUniqueId, retryTask.getUniqueId())
.eq(RetryTaskLog::getGroupName, retryTask.getGroupName()));
retryTask.setUpdateDt(LocalDateTime.now());
return retryTaskAccess.updateById(requestVO.getGroupName(), namespaceId, retryTask);
}

View File

@ -10,7 +10,7 @@
</a-row>
<a-row :gutter="24" type="flex" :style="{ marginTop: '24px' }">
<a-col :xl="12" :lg="24" :md="24" :sm="24" :xs="24">
<a-card :loading="loading" :bordered="false" :title="$t('dashboard.analysis.online-top-search')" :style="{ height: '100%' }">
<a-card :loading="loading" :bordered="false" title="场景列表" :style="{ height: '100%' }">
<s-table
ref="table"
size="default"
@ -28,7 +28,7 @@
<div>
<div>
<v-chart :force-fit="true" :height="405" :data="pieData" :scale="pieScale" >
<v-tooltip :showTitle="true" dataKey="value*percent" />
<v-tooltip :showTitle="false" dataKey="name*percent" />
<v-axis />
<v-legend dataKey="value" />
<v-pie position="percent" color="value" :vStyle="pieStyle" />

View File

@ -189,11 +189,6 @@ export default {
created () {
getAllGroupNameList().then((res) => {
this.groupNameList = res.data
if (this.groupNameList !== null && this.groupNameList.length > 0) {
this.queryParam['groupName'] = this.groupNameList[0]
this.$refs.table.refresh(true)
this.handleChange(this.groupNameList[0])
}
})
const groupName = this.$route.query.groupName

View File

@ -216,11 +216,6 @@ export default {
created () {
getAllGroupNameList().then((res) => {
this.groupNameList = res.data
if (this.groupNameList !== null && this.groupNameList.length > 0) {
this.queryParam['groupName'] = this.groupNameList[0]
this.$refs.table.refresh(true)
this.handleChange(this.groupNameList[0])
}
})
},
methods: {