#
luxiaotao1123
2024-02-28 8f7dd147703c853f0168b1bcfcc153a3b0a6b7e7
zy-asrs-flow/src/pages/system/user/components/edit.jsx
@@ -8,18 +8,21 @@
    ProFormTextArea,
    ProFormRadio
} from '@ant-design/pro-components';
import { FormattedMessage, useIntl } from '@umijs/max';
import { Form, Modal } from 'antd';
import moment from 'moment';
import Http from '@/utils/http';
const Edit = (props) => {
    const intl = useIntl();
    const [form] = Form.useForm();
    const { } = props;
    useEffect(() => {
        form.resetFields();
        form.setFieldsValue({
            ...props.values
            ...props.values,
            roleIds: props.values.userRoleIds
        })
    }, [form, props])
@@ -151,16 +154,6 @@
                        />
                    </ProForm.Group>
                    <ProForm.Group>
                        {/* <ProFormSelect
                            name="status"
                            label="状态"
                            colProps={{ md: 12, xl: 12 }}
                            placeholder="请选择"
                            options={[
                                { label: '正常', value: 1 },
                                { label: '禁用', value: 0 },
                            ]}
                        /> */}
                        <ProFormRadio.Group
                            name="status"
                            label="状态"
@@ -177,7 +170,11 @@
                            label="角色"
                            colProps={{ md: 12, xl: 12 }}
                            placeholder="请选择"
                            rules={[{ required: true, message: '角色不能为空!' }]}
                            rules={[{ required: true, type: 'array', message: '角色不能为空!' }]}
                            request={async ({ keyWords }) => {
                                const resp = await Http.doPostForm('api/role/query', { condition: keyWords });
                                return resp.data;
                            }}
                        />
                    </ProForm.Group>
                    <ProFormTextArea