From 3328aec7bc4cc2c090f015cba905a82d6d52870c Mon Sep 17 00:00:00 2001
From: wlzboy <66905212@qq.com>
Date: 星期日, 19 十月 2025 10:34:29 +0800
Subject: [PATCH] fix:更新
---
ruoyi-ui/src/views/system/callbacklog/index.vue | 74 ++++++++++++++++++++++++++++---------
1 files changed, 56 insertions(+), 18 deletions(-)
diff --git a/ruoyi-ui/src/views/system/callbacklog/index.vue b/ruoyi-ui/src/views/system/callbacklog/index.vue
index 2e45a89..0735694 100644
--- a/ruoyi-ui/src/views/system/callbacklog/index.vue
+++ b/ruoyi-ui/src/views/system/callbacklog/index.vue
@@ -48,8 +48,8 @@
</el-form>
<el-row :gutter="10" class="mb8">
- <!-- <el-col :span="1.5">
- <el-button
+ <el-col :span="1.5">
+ <!-- <el-button
type="primary"
plain
icon="el-icon-plus"
@@ -78,8 +78,9 @@
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['system:callbacklog:remove']"
- >鍒犻櫎</el-button>
- </el-col> -->
+ >鍒犻櫎</el-button> -->
+
+ </el-col>
<el-col :span="1.5">
<el-button
type="warning"
@@ -89,6 +90,16 @@
@click="handleExport"
v-hasPermi="['system:callbacklog:export']"
>瀵煎嚭</el-button>
+ </el-col>
+ <el-col :span="1.5">
+ <el-button
+ type="primary"
+ plain
+ icon="el-icon-s-promotion"
+ size="mini"
+ :disabled="multiple"
+ @click="handleBatchRetry"
+ >鎵归噺閲嶈瘯</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
@@ -116,24 +127,17 @@
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
</template>
</el-table-column>
- <!-- <el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
+ <el-table-column label="鎿嶄綔" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
- icon="el-icon-edit"
- @click="handleUpdate(scope.row)"
- v-hasPermi="['system:callbacklog:edit']"
- >淇敼</el-button>
- <el-button
- size="mini"
- type="text"
- icon="el-icon-delete"
- @click="handleDelete(scope.row)"
- v-hasPermi="['system:callbacklog:remove']"
- >鍒犻櫎</el-button>
+ icon="el-icon-s-promotion"
+ @click="handleRetry(scope.row)"
+ v-hasPermi="['system:callbacklog:retry']"
+ >閲嶈瘯鍥炶皟</el-button>
</template>
- </el-table-column> -->
+ </el-table-column>
</el-table>
<pagination
@@ -181,7 +185,7 @@
</template>
<script>
-import { listCallbacklog, getCallbacklog, delCallbacklog, addCallbacklog, updateCallbacklog } from "@/api/system/callbacklog";
+import { listCallbacklog, getCallbacklog, delCallbacklog, addCallbacklog, updateCallbacklog, retryCallbacklog } from "@/api/system/callbacklog";
export default {
name: "Callbacklog",
@@ -328,6 +332,40 @@
this.download('system/callbacklog/export', {
...this.queryParams
}, `callbacklog_${new Date().getTime()}.xlsx`)
+ },
+ /** 瑙﹀彂鍗曚釜鍥炶皟閲嶈瘯 */
+ handleRetry(row) {
+ const id = row.id;
+ this.$modal.confirm('鏄惁纭閲嶈瘯璇ュ洖璋冭褰曪紵').then(function() {
+ // 鍒涘缓甯︽湁瓒呮椂璁剧疆鐨勮姹傞厤缃�
+ const config = {
+ timeout: 60000 // 璁剧疆60绉掕秴鏃�
+ };
+ return retryCallbacklog(id, config);
+ }).then(() => {
+ this.getList();
+ this.$modal.msgSuccess("瑙﹀彂閲嶈瘯鎴愬姛");
+ }).catch((error) => {
+ // 娣诲姞閿欒澶勭悊
+ if (error.message.includes('timeout')) {
+ this.$modal.msgError("璇锋眰瓒呮椂锛岃绋嶅悗閲嶈瘯");
+ } else {
+ this.$modal.msgError("閲嶈瘯澶辫触锛�" + error.message);
+ }
+ });
+ },
+ /** 鎵归噺瑙﹀彂鍥炶皟閲嶈瘯 */
+ handleBatchRetry() {
+ if (this.ids.length === 0) {
+ this.$modal.msgError("璇烽�夋嫨闇�瑕侀噸璇曠殑璁板綍");
+ return;
+ }
+ this.$modal.confirm('鏄惁纭閲嶈瘯閫変腑鐨�' + this.ids.length + '鏉″洖璋冭褰曪紵').then(() => {
+ return retryCallbacklog(this.ids.join(','));
+ }).then(() => {
+ this.getList();
+ this.$modal.msgSuccess("鎵归噺閲嶈瘯鎴愬姛");
+ }).catch(() => {});
}
}
};
--
Gitblit v1.9.1