可用版本

This commit is contained in:
戚辰先生 2024-11-30 17:51:34 +08:00
parent 7efbb63d31
commit 7d27d8f576

View File

@ -4,11 +4,8 @@ import { PlusOutlined, EditOutlined, DeleteOutlined, KeyOutlined, TeamOutlined }
import type { UserResponse, Role } from './types'; import type { UserResponse, Role } from './types';
import type { DepartmentDTO } from '../Department/types'; import type { DepartmentDTO } from '../Department/types';
import { getUsers, createUser, updateUser, deleteUser, resetPassword } from './service'; import { getUsers, createUser, updateUser, deleteUser, resetPassword } from './service';
import { getDepartmentTree } from '../Department/service';
import { convertToPageParams, convertToPageInfo } from '@/utils/page';
import { useTableData } from '@/hooks/useTableData'; import { useTableData } from '@/hooks/useTableData';
import type { FixedType, AlignType } from 'rc-table/lib/interface'; import type { FixedType, AlignType } from 'rc-table/lib/interface';
// import RoleModal from './components/RoleModal';
const UserPage: React.FC = () => { const UserPage: React.FC = () => {
const { const {
@ -272,6 +269,20 @@ const UserPage: React.FC = () => {
> >
<Input placeholder="请输入用户名" disabled={!!editingUser} /> <Input placeholder="请输入用户名" disabled={!!editingUser} />
</Form.Item> </Form.Item>
{!editingUser && (
<Form.Item
name="password"
label="密码"
rules={[
{ required: true, message: '请输入密码' },
{ min: 6, message: '密码长度不能小于6位' }
]}
>
<Input.Password placeholder="请输入密码" />
</Form.Item>
)}
<Form.Item <Form.Item
name="nickname" name="nickname"
label="昵称" label="昵称"