X-Git-Url: https://git.arvados.org/arvados-workbench2.git/blobdiff_plain/1bda4645781ebb80f6d0db901f857abff088d749..5c6e7a1fcb3e951c09e4a794f92a80a35f4db2ee:/src/views-components/dialog-create/dialog-collection-create.tsx

diff --git a/src/views-components/dialog-create/dialog-collection-create.tsx b/src/views-components/dialog-create/dialog-collection-create.tsx
index 2fb007b8..38a8114d 100644
--- a/src/views-components/dialog-create/dialog-collection-create.tsx
+++ b/src/views-components/dialog-create/dialog-collection-create.tsx
@@ -3,22 +3,14 @@
 // SPDX-License-Identifier: AGPL-3.0
 
 import * as React from 'react';
-import { InjectedFormProps } from 'redux-form';
+import { InjectedFormProps, Field } from 'redux-form';
 import { WithDialogProps } from '~/store/dialog/with-dialog';
 import { CollectionCreateFormDialogData } from '~/store/collections/collection-create-actions';
-import { collectionUploaderActions, UploadFile } from "~/store/collections/uploader/collection-uploader-actions";
 import { FormDialog } from '~/components/form-dialog/form-dialog';
 import { CollectionNameField, CollectionDescriptionField } from '~/views-components/form-fields/collection-form-fields';
-import { FileUpload } from '~/components/file-upload/file-upload';
+import { require } from '~/validators/require';
+import { FileUploaderField } from '../file-uploader/file-uploader';
 
-// interface DialogCollectionDataProps {
-//     open: boolean;
-//     handleSubmit: any;
-//     submitting: boolean;
-//     invalid: boolean;
-//     pristine: boolean;
-//     files: UploadFile[];
-// }
 
 type DialogCollectionProps = WithDialogProps<{}> & InjectedFormProps<CollectionCreateFormDialogData>;
 
@@ -33,8 +25,10 @@ export const DialogCollectionCreate = (props: DialogCollectionProps) =>
 const CollectionAddFields = () => <span>
     <CollectionNameField />
     <CollectionDescriptionField />
-    {/* <FileUpload
-        files={this.props.files}
-        disabled={busy}
-        onDrop={files => this.props.dispatch(collectionUploaderActions.SET_UPLOAD_FILES(files))} /> */}
-</span>;
\ No newline at end of file
+    <Field
+        name='files'
+        validate={[require]}
+        label='Files'
+        component={FileUploaderField} />
+</span>;
+
