X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/e0effe9fd43b8d7c0d7fcb9aade9b718cf5dddda..96a705a50db3d742fd897c12a236b8a44bbcaffb:/src/views-components/dialog-create/dialog-user-create.tsx?ds=sidebyside

diff --git a/src/views-components/dialog-create/dialog-user-create.tsx b/src/views-components/dialog-create/dialog-user-create.tsx
index 80904397ec..6be7b28f0e 100644
--- a/src/views-components/dialog-create/dialog-user-create.tsx
+++ b/src/views-components/dialog-create/dialog-user-create.tsx
@@ -2,13 +2,21 @@
 //
 // SPDX-License-Identifier: AGPL-3.0
 
-import * as React from 'react';
+import React from 'react';
 import { InjectedFormProps } from 'redux-form';
-import { WithDialogProps } from '~/store/dialog/with-dialog';
-import { FormDialog } from '~/components/form-dialog/form-dialog';
-import { UserFirstNameField, UserLastNameField, UserEmailField, UserIdentityUrlField, UserVirtualMachineField, UserGroupsVirtualMachineField } from '~/views-components/form-fields/user-form-fields';
+import { WithDialogProps } from 'store/dialog/with-dialog';
+import { FormDialog } from 'components/form-dialog/form-dialog';
+import { UserEmailField, UserVirtualMachineField, UserGroupsVirtualMachineField } from 'views-components/form-fields/user-form-fields';
+import { UserCreateFormDialogData } from 'store/users/users-actions';
+import { UserResource } from 'models/user';
+import { VirtualMachinesResource } from 'models/virtual-machines';
 
-export type DialogUserProps = WithDialogProps<{}> & InjectedFormProps<any>;
+export type DialogUserProps = WithDialogProps<{}> & InjectedFormProps<UserCreateFormDialogData>;
+
+interface DataProps {
+    user: UserResource;
+    items: VirtualMachinesResource[];
+}
 
 export const UserRepositoryCreate = (props: DialogUserProps) =>
     <FormDialog
@@ -19,10 +27,7 @@ export const UserRepositoryCreate = (props: DialogUserProps) =>
     />;
 
 const UserAddFields = (props: DialogUserProps) => <span>
-    <UserFirstNameField />
-    <UserLastNameField />
     <UserEmailField />
-    <UserIdentityUrlField />
-    <UserVirtualMachineField data={props.data}/>
+    <UserVirtualMachineField data={props.data as DataProps}/>
     <UserGroupsVirtualMachineField />
 </span>;
