|
|
@ -1,4 +1,3 @@ |
|
|
|
import { usePageStoreOptions } from '@/store' |
|
|
|
import { PageContainer, ProCard } from '@ant-design/pro-components' |
|
|
|
import { Flexbox } from 'react-layout-kit' |
|
|
|
import { DraggablePanel } from '@/components/draggable-panel' |
|
|
@ -11,6 +10,7 @@ import { defaultDepart, selectedDepartAtom, departTreeAtom, saveOrUpdateDepartAt |
|
|
|
import { useAtom, useAtomValue, } from 'jotai' |
|
|
|
import Glass from '@/components/glass' |
|
|
|
import { useEffect, useRef } from 'react' |
|
|
|
import UserPicker from '@/components/user-picker/UserPicker.tsx' |
|
|
|
|
|
|
|
const Departments = () => { |
|
|
|
|
|
|
@ -18,9 +18,9 @@ const Departments = () => { |
|
|
|
const { styles, cx } = useStyle() |
|
|
|
const [ form ] = Form.useForm() |
|
|
|
const inputRef = useRef<InputRef>() |
|
|
|
const { data } = useAtomValue(departTreeAtom, usePageStoreOptions()) |
|
|
|
const { mutate, isPending, isError, error } = useAtomValue(saveOrUpdateDepartAtom, usePageStoreOptions()) |
|
|
|
const [ current, setCurrent ] = useAtom(selectedDepartAtom, usePageStoreOptions()) |
|
|
|
const { data } = useAtomValue(departTreeAtom) |
|
|
|
const { mutate, isPending, isError, error } = useAtomValue(saveOrUpdateDepartAtom) |
|
|
|
const [ current, setCurrent ] = useAtom(selectedDepartAtom) |
|
|
|
|
|
|
|
useEffect(() => { |
|
|
|
|
|
|
@ -40,6 +40,7 @@ const Departments = () => { |
|
|
|
|
|
|
|
return ( |
|
|
|
<PageContainer breadcrumbRender={false} title={false} className={styles.container}> |
|
|
|
|
|
|
|
<Flexbox horizontal> |
|
|
|
<DraggablePanel expandable={false} |
|
|
|
placement="left" |
|
|
@ -119,8 +120,8 @@ const Departments = () => { |
|
|
|
<InputNumber/> |
|
|
|
</Form.Item> |
|
|
|
<Form.Item label={t('system.departments.form.manager_user_id', '负责人')} |
|
|
|
name={'path'}> |
|
|
|
<Input/> |
|
|
|
name={'manager_user_id'}> |
|
|
|
<UserPicker/> |
|
|
|
</Form.Item> |
|
|
|
|
|
|
|
<Form.Item label={t('system.departments.form.phone', '联系电话')} |
|
|
|