invenio-app-rdm icon indicating copy to clipboard operation
invenio-app-rdm copied to clipboard

Allow setting the order of files for records

Open max-moser opened this issue 4 months ago • 2 comments

Overview

It's been recently requested to change the order of files for a record because the default order is somewhat arbitrary (definitely not lexicographic). InvenioRDM seems to have some basic support for this (record.files.order), but setting this field results in internal server errors during the lifecycle of the record/draft.

Problem

For example, I've set the order of files for a draft through invenio shell, and after draft.commit() and during rdm_rec_svc.indexer.reindex(draft), I get the following exception: RequestError: RequestError(400, 'strict_dynamic_mapping_exception', 'mapping set to strict, dynamic introduction of [order] within [files] is not allowed')

Optimal solution

It would be nice to have the order of appearance for files be changeable by the user, maybe through drag & drop on the deposit page.

Alternatives

Basically it would already suffice to support setting the file order through the backend.

max-moser avatar Feb 09 '24 10:02 max-moser