From 2e0de6e0d07a814f69591d60f0036cf861f7fe31 Mon Sep 17 00:00:00 2001 From: wangxd-yu <657716219@qq.com> Date: Wed, 8 Dec 2021 23:27:47 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20confirm=E7=A1=AE=E8=AE=A4=E6=A1=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- yu-react/src/pages/log/EndpointLog/index.tsx | 18 ++++++------- yu-react/src/pages/system/Dept/index.tsx | 2 +- yu-react/src/pages/system/Dict/index.tsx | 28 ++++++++++++-------- yu-react/src/pages/system/Role/index.tsx | 15 ++++++----- 4 files changed, 36 insertions(+), 27 deletions(-) diff --git a/yu-react/src/pages/log/EndpointLog/index.tsx b/yu-react/src/pages/log/EndpointLog/index.tsx index 44b5fb5..5d5f7a8 100644 --- a/yu-react/src/pages/log/EndpointLog/index.tsx +++ b/yu-react/src/pages/log/EndpointLog/index.tsx @@ -100,16 +100,16 @@ const LogEndpointTable: React.FC = () => { closable={false} > - + {logEndpointCurrentRow?.url} - + {logEndpointCurrentRow?.httpStatus} - + {logEndpointCurrentRow?.createTime} - + {logEndpointCurrentRow?.time} @@ -118,19 +118,19 @@ const LogEndpointTable: React.FC = () => { {logEndpointCurrentRow?.ip} - + {logEndpointCurrentRow?.method} - + {logEndpointCurrentRow?.pattern} - + {logEndpointCurrentRow?.handler} - + {logEndpointCurrentRow?.request} - + {logEndpointCurrentRow?.response} diff --git a/yu-react/src/pages/system/Dept/index.tsx b/yu-react/src/pages/system/Dept/index.tsx index 34e2cea..1a9b43c 100644 --- a/yu-react/src/pages/system/Dept/index.tsx +++ b/yu-react/src/pages/system/Dept/index.tsx @@ -82,7 +82,7 @@ const DeptPage: React.FC = () => { > 添加下级 , - { await YuCrud.handleDelete(deleteDept, record.id); if (deptActionRef.current) { diff --git a/yu-react/src/pages/system/Dict/index.tsx b/yu-react/src/pages/system/Dict/index.tsx index 435eb2a..e741997 100644 --- a/yu-react/src/pages/system/Dict/index.tsx +++ b/yu-react/src/pages/system/Dict/index.tsx @@ -1,5 +1,5 @@ import { PlusOutlined } from '@ant-design/icons'; -import { Button, Drawer } from 'antd'; +import { Button, Drawer, Popconfirm } from 'antd'; import type { FormInstance } from 'antd'; import React, { useState, useRef } from 'react'; import { PageContainer } from '@ant-design/pro-layout'; @@ -79,15 +79,18 @@ const TableList: React.FC = () => { > 字典配置 , - { + { await YuCrud.handleDelete(deleteDict, record.id) if (actionRef.current) { actionRef.current.reload(); } - }}> - 删除 - , + }} + > + + 删除 + + ], }, ]; @@ -121,15 +124,18 @@ const TableList: React.FC = () => { > 编辑 , - { + { await YuCrud.handleDelete(deleteDictItem, record.id); if (itemActionRef.current) { itemActionRef.current.reload(); } - }}> - 删除 - , + }} + > + + 删除 + + ], }, ] diff --git a/yu-react/src/pages/system/Role/index.tsx b/yu-react/src/pages/system/Role/index.tsx index 3a21e60..42dae6d 100644 --- a/yu-react/src/pages/system/Role/index.tsx +++ b/yu-react/src/pages/system/Role/index.tsx @@ -1,5 +1,5 @@ import { FolderOutlined, PlusOutlined, ProfileOutlined, SecurityScanOutlined } from '@ant-design/icons'; -import { Button, Tree } from 'antd'; +import { Button, Popconfirm, Tree } from 'antd'; import type { FormInstance } from 'antd'; import React, { useState, useRef, useEffect } from 'react'; import { PageContainer } from '@ant-design/pro-layout'; @@ -116,15 +116,18 @@ const RoleTable: React.FC = () => { > 权限分配 , - { + { await YuCrud.handleDelete(deleteRole, record.id) if (actionRef.current) { actionRef.current.reload(); } - }}> - 删除 - , + }} + > + + 删除 + + ], }, ];