1 // Copyright (C) The Arvados Authors. All rights reserved.
3 // SPDX-License-Identifier: AGPL-3.0
5 import { compose, Dispatch } from "redux";
6 import { reduxForm } from 'redux-form';
7 import { withDialog } from "store/dialog/with-dialog";
8 import { DialogCollectionUpdate } from 'views-components/dialog-update/dialog-collection-update';
10 COLLECTION_UPDATE_FORM_NAME,
11 CollectionUpdateFormDialogData,
13 } from 'store/collections/collection-update-actions';
15 export const UpdateCollectionDialog = compose(
16 withDialog(COLLECTION_UPDATE_FORM_NAME),
17 reduxForm<CollectionUpdateFormDialogData>({
19 form: COLLECTION_UPDATE_FORM_NAME,
20 onSubmit: (data: CollectionUpdateFormDialogData, dispatch: Dispatch) => {
21 dispatch<any>(updateCollection(data));
24 )(DialogCollectionUpdate);