From cbebed60f289e4015d8ad731a8169e8bc6f726cf Mon Sep 17 00:00:00 2001
From: luxiaotao1123 <t1341870251@163.com>
Date: 星期一, 26 二月 2024 15:42:44 +0800
Subject: [PATCH] #
---
zy-asrs-framework/src/main/resources/templates/react/Index.txt | 2 +-
zy-asrs-flow/src/pages/system/operationRecord/index.jsx | 39 +++++++++++++++++++++++----------------
2 files changed, 24 insertions(+), 17 deletions(-)
diff --git a/zy-asrs-flow/src/pages/system/operationRecord/index.jsx b/zy-asrs-flow/src/pages/system/operationRecord/index.jsx
index 94de2f8..caa1ae7 100644
--- a/zy-asrs-flow/src/pages/system/operationRecord/index.jsx
+++ b/zy-asrs-flow/src/pages/system/operationRecord/index.jsx
@@ -1,6 +1,6 @@
import React, { useState, useRef, useEffect } from 'react';
-import { Button, message, Modal, Tooltip } from 'antd';
+import { Button, message, Modal, Tag } from 'antd';
import {
FooterToolbar,
PageContainer,
@@ -14,6 +14,17 @@
import { repairBug } from '@/utils/common-util';
const TABLE_KEY = "pro-table-operationRecord";
+
+const resultMap = {
+ 0: {
+ color: '#cd201f',
+ text: '澶辫触',
+ },
+ 1: {
+ color: '#3b5999',
+ text: '鎴愬姛',
+ },
+};
const handleSave = async (val) => {
const hide = message.loading('姝e湪娣诲姞');
@@ -110,11 +121,10 @@
width: 48,
},
{
- title: '鍚嶇О绌洪棿',
+ title: '鎺ュ彛鍚�',
dataIndex: 'namespace',
valueType: 'text',
hidden: false,
- width: 140,
copyable: true,
filterDropdown: (props) => <TextFilter
name='namespace'
@@ -128,7 +138,7 @@
dataIndex: 'url',
valueType: 'text',
hidden: false,
- width: 140,
+ width: 180,
filterDropdown: (props) => <TextFilter
name='url'
{...props}
@@ -141,7 +151,6 @@
dataIndex: 'appkey',
valueType: 'text',
hidden: false,
- width: 140,
filterDropdown: (props) => <TextFilter
name='appkey'
{...props}
@@ -154,7 +163,6 @@
dataIndex: 'timestamp',
valueType: 'text',
hidden: false,
- width: 140,
filterDropdown: (props) => <TextFilter
name='timestamp'
{...props}
@@ -167,7 +175,6 @@
dataIndex: 'clientIp',
valueType: 'text',
hidden: false,
- width: 140,
filterDropdown: (props) => <TextFilter
name='clientIp'
{...props}
@@ -180,7 +187,6 @@
dataIndex: 'request',
valueType: 'text',
hidden: false,
- width: 140,
ellipsis: true,
copyable: true,
filterDropdown: (props) => <TextFilter
@@ -195,7 +201,6 @@
dataIndex: 'response',
valueType: 'text',
hidden: false,
- width: 140,
ellipsis: true,
copyable: true,
filterDropdown: (props) => <TextFilter
@@ -210,7 +215,6 @@
dataIndex: 'spendTime',
valueType: 'text',
hidden: false,
- width: 140,
filterDropdown: (props) => <TextFilter
name='spendTime'
{...props}
@@ -226,7 +230,6 @@
dataIndex: 'err',
valueType: 'text',
hidden: false,
- width: 140,
filterDropdown: (props) => <TextFilter
name='err'
{...props}
@@ -239,7 +242,7 @@
dataIndex: 'result$',
valueType: 'text',
hidden: false,
- width: 140,
+ width: 100,
filterDropdown: (props) => <SelectFilter
name='result'
{...props}
@@ -250,13 +253,16 @@
{ label: '澶辫触', value: 0 },
]}
/>,
+ render: (_, record) => {
+ const result = resultMap[record.result]
+ return <Tag color={result.color}>{result.text}</Tag>
+ },
},
{
title: '鐢ㄦ埛',
dataIndex: 'userId$',
valueType: 'text',
hidden: false,
- width: 140,
filterDropdown: (props) => <LinkFilter
name='userId'
major='user'
@@ -270,7 +276,6 @@
dataIndex: 'createTime$',
valueType: 'text',
hidden: false,
- width: 140,
filterDropdown: (props) => <DatetimeRangeFilter
name='createTime'
{...props}
@@ -283,7 +288,6 @@
dataIndex: 'memo',
valueType: 'text',
hidden: false,
- width: 140,
filterDropdown: (props) => <TextFilter
name='memo'
{...props}
@@ -295,7 +299,6 @@
{
title: '鎿嶄綔',
dataIndex: 'option',
- width: 140,
valueType: 'option',
render: (_, record) => [
<Button
@@ -411,6 +414,10 @@
persistenceKey: TABLE_KEY,
persistenceType: 'localStorage',
defaultValue: {
+ appkey: { show: repairBug(TABLE_KEY, 'appkey', false) },
+ err: { show: repairBug(TABLE_KEY, 'err', false) },
+ timestamp: { show: repairBug(TABLE_KEY, 'timestamp', false) },
+ memo: { show: repairBug(TABLE_KEY, 'memo', false) },
option: { fixed: 'right', disable: true },
},
onChange(value) {
diff --git a/zy-asrs-framework/src/main/resources/templates/react/Index.txt b/zy-asrs-framework/src/main/resources/templates/react/Index.txt
index e796b79..4046980 100644
--- a/zy-asrs-framework/src/main/resources/templates/react/Index.txt
+++ b/zy-asrs-framework/src/main/resources/templates/react/Index.txt
@@ -227,7 +227,7 @@
persistenceKey: TABLE_KEY,
persistenceType: 'localStorage',
defaultValue: {
- memo: { show: repairBug(TABLE_KEY, 'memo', false) },
+ // memo: { show: repairBug(TABLE_KEY, 'memo', false) },
option: { fixed: 'right', disable: true },
},
onChange(value) {
--
Gitblit v1.9.1