Commit b27be4ff authored by 张烨's avatar 张烨
parents 2d0dbd41 8996ec65
import React, { useState, useEffect } from 'react'; import React, { useState, useEffect } from 'react';
import { import {
Table, Table,
Tooltip,
Spin, Spin,
Modal, Modal,
Form, Form,
...@@ -11,7 +12,8 @@ import { ...@@ -11,7 +12,8 @@ import {
notification, notification,
message, message,
} from 'antd'; } from 'antd';
import { get } from '@/services/index'; import { get } from '@/services';
import { EditTwoTone, DeleteOutlined } from '@ant-design/icons';
import styles from './AppDic.less'; import styles from './AppDic.less';
const AppDic = () => { const AppDic = () => {
...@@ -53,40 +55,40 @@ const AppDic = () => { ...@@ -53,40 +55,40 @@ const AppDic = () => {
{ {
title: '操作', title: '操作',
key: 'action', key: 'action',
width: 200, width: 100,
render: record => ( render: record => (
<Space> <Space>
<Button <Tooltip title="编辑">
type="primary" <EditTwoTone
size="small" onClick={() => {
onClick={() => { setSelect(record);
setSelect(record); setEditVisible(true);
setEditVisible(true); editForm.setFieldsValue({
editForm.setFieldsValue({ label: record.Label,
label: record.Label, key: record.Key,
key: record.Key, value: record.Value,
value: record.Value, description: record.Description,
description: record.Description, });
}); }}
}} style={{ fontSize: '16px' }}
> />
修改 </Tooltip>
</Button>
<Popconfirm <Popconfirm
title="是否删除该数据?" title="是否删除该数据?"
okText="确认" okText="确认"
cancelText="取消" cancelText="取消"
onConfirm={submitDelete} onConfirm={submitDelete}
> >
<Button <DeleteOutlined
size="small"
danger
onClick={() => { onClick={() => {
setSelect(record); setSelect(record);
}} }}
> style={{
删除 fontSize: '16px',
</Button> margin: '0px 10px',
color: '#e86060',
}}
/>
</Popconfirm> </Popconfirm>
</Space> </Space>
), ),
......
...@@ -15,7 +15,7 @@ import { ...@@ -15,7 +15,7 @@ import {
Col, Col,
} from 'antd'; } from 'antd';
import { EditTwoTone, DeleteOutlined } from '@ant-design/icons'; import { EditTwoTone, DeleteOutlined } from '@ant-design/icons';
import { get } from '@/services/index'; import { get } from '@/services';
import styles from './WebDic.less'; import styles from './WebDic.less';
const WebDic = () => { const WebDic = () => {
......
...@@ -257,7 +257,7 @@ const UserManage = () => { ...@@ -257,7 +257,7 @@ const UserManage = () => {
<Tooltip title="冻结用户"> <Tooltip title="冻结用户">
<StopOutlined <StopOutlined
onClick={() => freezeUser(record)} onClick={() => freezeUser(record)}
style={{ fontSize: '16px', color: '#1890FF' }} style={{ fontSize: '16px', color: '#e86060' }}
/> />
</Tooltip> </Tooltip>
</> </>
...@@ -267,15 +267,15 @@ const UserManage = () => { ...@@ -267,15 +267,15 @@ const UserManage = () => {
<Tooltip title="解冻用户"> <Tooltip title="解冻用户">
<StopOutlined <StopOutlined
onClick={() => freezeUser(record)} onClick={() => freezeUser(record)}
style={{ fontSize: '16px' }} style={{ fontSize: '16px', color: '#1890FF' }}
/> />
</Tooltip> </Tooltip>
</> </>
)} )}
<Tooltip title="删除用户"> <Tooltip title="删除用户">
<DeleteTwoTone <DeleteOutlined
onClick={() => deleteUser(record)} onClick={() => deleteUser(record)}
style={{ fontSize: '16px' }} style={{ fontSize: '16px', color: '#e86060' }}
/> />
</Tooltip> </Tooltip>
</Space> </Space>
...@@ -285,8 +285,6 @@ const UserManage = () => { ...@@ -285,8 +285,6 @@ const UserManage = () => {
const [selectionType] = useState('checkbox'); const [selectionType] = useState('checkbox');
const rowSelection = { const rowSelection = {
onChange: (selectedRowKeys, selectedRows) => { onChange: (selectedRowKeys, selectedRows) => {
console.log(selectedRowKeys.toString());
console.log(selectedRows.map(item => item.OUID).toString());
setUserIDs(selectedRowKeys.toString()); // 数组转字符串,逗号连接 setUserIDs(selectedRowKeys.toString()); // 数组转字符串,逗号连接
setOrgIDs(selectedRows.map(item => item.OUID).toString()); setOrgIDs(selectedRows.map(item => item.OUID).toString());
// 选中行数大于0时设置批量操作可行 // 选中行数大于0时设置批量操作可行
...@@ -1414,14 +1412,22 @@ const UserManage = () => { ...@@ -1414,14 +1412,22 @@ const UserManage = () => {
label="新密码" label="新密码"
rules={[{ required: true, message: '不能为空' }]} rules={[{ required: true, message: '不能为空' }]}
> >
<Input placeholder="请输入新密码" /> <Input
placeholder="请输入新密码"
type="password"
autoComplete="off"
/>
</Form.Item> </Form.Item>
<Form.Item <Form.Item
name="passwordConfirm" name="passwordConfirm"
label="确认密码" label="确认密码"
rules={[{ required: true, message: '不能为空' }]} rules={[{ required: true, message: '不能为空' }]}
> >
<Input placeholder="再次确认新密码" /> <Input
placeholder="再次确认新密码"
type="password"
autoComplete="off"
/>
</Form.Item> </Form.Item>
</Form> </Form>
</Modal> </Modal>
......
...@@ -7,6 +7,7 @@ import { ...@@ -7,6 +7,7 @@ import {
SolutionOutlined, SolutionOutlined,
// AndroidOutlined, // AndroidOutlined,
// CommentOutlined, // CommentOutlined,
TableOutlined,
CopyOutlined, CopyOutlined,
} from '@ant-design/icons'; } from '@ant-design/icons';
import UserLayout from '../layouts/UserLayout'; import UserLayout from '../layouts/UserLayout';
...@@ -21,7 +22,7 @@ import CurrentSolution from '@/pages/database/CurrentSolution'; ...@@ -21,7 +22,7 @@ import CurrentSolution from '@/pages/database/CurrentSolution';
import UserManage from '../pages/userCenter/UserManage'; import UserManage from '../pages/userCenter/UserManage';
import RoleManage from '@/pages/userCenter/roleManage/RoleManage'; import RoleManage from '@/pages/userCenter/roleManage/RoleManage';
import SiteManage from '../pages/userCenter/siteManage/SiteManage'; import SiteManage from '../pages/userCenter/siteManage/SiteManage';
import Dictionary from '../pages/platformCenter/dictionary'; import Dictionary from '../pages/dataCenter/dictionary';
import ServiceLog from '../pages/log/serviceLog'; import ServiceLog from '../pages/log/serviceLog';
import LoginLog from '../pages/log/loginLog'; import LoginLog from '../pages/log/loginLog';
import OmsLog from '../pages/log/omsLog'; import OmsLog from '../pages/log/omsLog';
...@@ -207,13 +208,14 @@ export default { ...@@ -207,13 +208,14 @@ export default {
'/web4/?widget=product/oms/MqttConfig/MqttConfig.js|hideMap=true', '/web4/?widget=product/oms/MqttConfig/MqttConfig.js|hideMap=true',
component: BaseFrameContainer, component: BaseFrameContainer,
}, },
{
path: '/platformCenter/dictionary',
name: '数据中心',
component: Dictionary,
},
], ],
}, },
{
path: '/dataCenter/dictionary',
name: '数据中心',
icon: <TableOutlined style={iconStyle} />,
component: Dictionary,
},
{ {
path: '/productCenter', path: '/productCenter',
component: BlankLayout, component: BlankLayout,
......
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