|
@@ -1,5 +1,5 @@
|
|
import React, { useEffect, useState } from 'react';
|
|
import React, { useEffect, useState } from 'react';
|
|
-import { Col, Form, Input, InputNumber, message, Modal, Row, Table } from 'antd';
|
|
|
|
|
|
+import { Col, Form, Input, message, Modal, Row, Table } from 'antd';
|
|
import type { ColumnsType } from 'antd/es/table';
|
|
import type { ColumnsType } from 'antd/es/table';
|
|
import { createRole, editRole } from '@/services/role';
|
|
import { createRole, editRole } from '@/services/role';
|
|
import { queryMenu } from '@/services/menu';
|
|
import { queryMenu } from '@/services/menu';
|
|
@@ -111,14 +111,6 @@ const Edit: React.FC<editPros> = (props) => {
|
|
setSelectedRowKeys(keys);
|
|
setSelectedRowKeys(keys);
|
|
};
|
|
};
|
|
|
|
|
|
- const formItemLayout = {
|
|
|
|
- labelCol: {
|
|
|
|
- span: 6,
|
|
|
|
- },
|
|
|
|
- wrapperCol: {
|
|
|
|
- span: 18,
|
|
|
|
- },
|
|
|
|
- };
|
|
|
|
const formItemLayout24 = {
|
|
const formItemLayout24 = {
|
|
labelCol: { span: 3 },
|
|
labelCol: { span: 3 },
|
|
wrapperCol: { span: 21 },
|
|
wrapperCol: { span: 21 },
|
|
@@ -151,9 +143,9 @@ const Edit: React.FC<editPros> = (props) => {
|
|
>
|
|
>
|
|
<Form form={form}>
|
|
<Form form={form}>
|
|
<Row>
|
|
<Row>
|
|
- <Col span={12}>
|
|
|
|
|
|
+ <Col span={24}>
|
|
<Form.Item
|
|
<Form.Item
|
|
- {...formItemLayout}
|
|
|
|
|
|
+ {...formItemLayout24}
|
|
name="name"
|
|
name="name"
|
|
label="角色名称"
|
|
label="角色名称"
|
|
rules={[{ required: true, message: '请输入角色名称' }]}
|
|
rules={[{ required: true, message: '请输入角色名称' }]}
|
|
@@ -162,17 +154,6 @@ const Edit: React.FC<editPros> = (props) => {
|
|
<Input placeholder="请输入角色名称" />
|
|
<Input placeholder="请输入角色名称" />
|
|
</Form.Item>
|
|
</Form.Item>
|
|
</Col>
|
|
</Col>
|
|
- <Col span={12}>
|
|
|
|
- <Form.Item
|
|
|
|
- {...formItemLayout}
|
|
|
|
- name="sequence"
|
|
|
|
- label="排序值"
|
|
|
|
- rules={[{ required: true, message: '请输入排序值' }]}
|
|
|
|
- initialValue={params?.sequence}
|
|
|
|
- >
|
|
|
|
- <InputNumber placeholder="请输入排序值" style={{ width: '100%' }} />
|
|
|
|
- </Form.Item>
|
|
|
|
- </Col>
|
|
|
|
<Col span={24}>
|
|
<Col span={24}>
|
|
<Form.Item
|
|
<Form.Item
|
|
{...formItemLayout24}
|
|
{...formItemLayout24}
|