Commit 8418baa3 authored by 皮倩雯's avatar 皮倩雯

数据字典界面修改

parent a5cad1b7
Pipeline #36757 skipped with stages
......@@ -2,7 +2,7 @@
* @Description:
* @Author: leizhe
* @Date: 2021-05-27 16:31:05
* @LastEditTime: 2021-10-28 13:57:57
* @LastEditTime: 2021-10-28 14:35:23
* @LastEditors: leizhe
*/
import React, { useState, useEffect } from 'react';
......@@ -45,6 +45,7 @@ const dictionary = () => {
const [select, setSelect] = useState({}); // 当前选中条目,可以是一级/二级,修改/删除时设置
const history = useHistory();
const [editForm] = Form.useForm();
const [title, setTitle] = useState('')
const { Search } = Input;
const columns2 = [
......@@ -93,7 +94,7 @@ const dictionary = () => {
<div onClick={e => e.stopPropagation()}>
<Tooltip title="删除">
<Popconfirm
title="是否确认删除该数据?"
title={title}
okText="确认"
cancelText="取消"
onConfirm={submitDelete}
......@@ -102,6 +103,11 @@ const dictionary = () => {
<DeleteOutlined
onClick={() => {
setSelect(record);
if (record.parentID === '-1' || record.parentID === null) {
setTitle('确认删除一级目录数据,删除一级目录数据会将其二级目录子数据一起删除');
} else {
setTitle('确认删除二级条目数据');
}
}
}
style={{
......
......@@ -652,8 +652,9 @@ const WebDic = () => {
key=''
columns={columns}
dataSource={data}
scroll={{ x: 'max-content', y: 'calc(100vh - 370px)' }}
scroll={{y: 'calc(100vh - 370px)' }}
bordered
className={styles.pab}
title={() => {
return <div >
<span>一级条目</span>
......@@ -663,7 +664,7 @@ const WebDic = () => {
style={{
color: '#1890FF',
fontSize: '25px',
verticalAlign: 'middle',
marginTop:'3px',
float: 'right',
}}
/>
......@@ -710,7 +711,7 @@ const WebDic = () => {
style={{
color: '#1890FF',
fontSize: '25px',
verticalAlign: 'middle',
marginTop:'3px',
float: 'right',
}}
/>
......
......@@ -30,6 +30,7 @@
max-height: calc(100vh - 345px) !important;
min-height:calc(100vh - 345px);
margin-right: -6px;
width:100%;
}
.ant-table-pagination.ant-pagination {
margin: 10px 0 !important;
......@@ -43,6 +44,9 @@
margin-right: -7px;
}
}
// .pad{
// overflow-x: hidden;
// }
.ant-table-wrapper {
max-width: 98%;
margin-left: 2%;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment