rdmo icon indicating copy to clipboard operation
rdmo copied to clipboard

Add parent to element when copying in management

Open jochenklar opened this issue 7 months ago • 0 comments

Description / Beschreibung

Right now copying from the nested view does add the new element to the old parent, e.g. a copied section does not end up in the same catalog.

Expected behaviour / Erwartetes Verhalten

Copying elements should add them to the same parent.

Ideas

The parent needs to be a prop to the element component (e.g. here https://github.com/rdmorganiser/rdmo/blob/main/rdmo/management/assets/js/components/nested/NestedCatalog.js#L94) and then needs to be provoded to fetchCopy (https://github.com/rdmorganiser/rdmo/blob/main/rdmo/management/assets/js/components/element/Section.js#L29). Prferebly in the same format as for the createSection action ({ catalog }) so that the same syntax as in the factories can be used.

jochenklar avatar Jul 18 '24 16:07 jochenklar