mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-19 14:20:31 +00:00
chrone: sperate client and server to different repos.
This commit is contained in:
35
src/containers/Dialogs/UserFormDialog/index.js
Normal file
35
src/containers/Dialogs/UserFormDialog/index.js
Normal file
@@ -0,0 +1,35 @@
|
||||
import React, { lazy } from 'react';
|
||||
import { FormattedMessage as T } from 'components';
|
||||
import { Dialog, DialogSuspense } from 'components';
|
||||
import withDialogRedux from 'components/DialogReduxConnect';
|
||||
import { compose } from 'utils';
|
||||
|
||||
const UserFormDialogContent = lazy(() => import('./UserFormDialogContent'));
|
||||
|
||||
function UserFormDialog({
|
||||
dialogName,
|
||||
payload = { action: '', userId: null },
|
||||
isOpen,
|
||||
}) {
|
||||
|
||||
return (
|
||||
<Dialog
|
||||
name={dialogName}
|
||||
title={<T id={'edit_user'} />}
|
||||
className={'dialog--user-form'}
|
||||
autoFocus={true}
|
||||
canEscapeKeyClose={true}
|
||||
isOpen={isOpen}
|
||||
>
|
||||
<DialogSuspense>
|
||||
<UserFormDialogContent
|
||||
dialogName={dialogName}
|
||||
userId={payload.userId}
|
||||
action={payload.action}
|
||||
/>
|
||||
</DialogSuspense>
|
||||
</Dialog>
|
||||
);
|
||||
}
|
||||
|
||||
export default compose(withDialogRedux())(UserFormDialog);
|
||||
Reference in New Issue
Block a user