Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revise formating of Extent field values #459

Open
ggeisler opened this issue Jan 11, 2023 · 1 comment
Open

Revise formating of Extent field values #459

ggeisler opened this issue Jan 11, 2023 · 1 comment

Comments

@ggeisler
Copy link
Contributor

Currently we display the Extent field as part of item metadata, which is helpful. However, the value reads especially awkwardly for component items (as opposed to parent container items). If this can be easily updated, it would improve the metadata display.

Parent container items

The current display is:

Extent: 135 item(s)

Generally this is fine. However, I do wonder why we can't use the Rails pluralize helper so we end up with this formatting as: Extent: 135 items or Extent: 1 item? If there's a good reason for this, that's fine, I just want to make sure this isn't an easy improvement that was just overlooked when initially implemented.

Component items

For the lowest-level component items that include a full list of metadata on their item detail page, we use this format:

Text and image items: Extent: 1 item(s) and 120 pages
Audio and moving image items: Extent: 1 item(s) and 0:15:25

If we can apply different formatting for component items (which I think we already are in that we add "and [page or duration value]" to the parent container version), I'd prefer to replace the "and" with a hyphen, so the end result is:

Text and image items: Extent: 1 item(s) - 120 pages
Audio and moving image items: Extent: 1 item(s) - 0:15:25


Even better would be to add additional formatting (in duration after the time value) for the audio and moving image cases:

Audio and moving image items: Extent: 1 item(s) - 0:15:25 in duration


And finally, the best option would be to use the pluralize helper and combine the two formatting suggestions above to get:

Parent items: Extent: 135 items
Text and image items: Extent: 1 item - 120 pages
Audio and moving image items: Extent: 1 item - 0:15:25 in duration

@marlo-longley
Copy link
Collaborator

marlo-longley commented Jan 11, 2023

Thanks for this Gary.

I believe we are hardcoding this into our data for upload to ASpace, as it is a required field for the upload, we made the choice to use "item(s)" from the available options in the controlled vocubulary. See

"extent_type": "item(s)",
This label is indexed into the "extent" Solr field along with the number -- "1 item(s)" is then displayed.

If we continue with this pattern the solution would be to make the python script smarter and reflect Gary's improvements there. Assuming ASpace will accept the data in an upload (need to check against controlled vocab), then we would need to re-upload, and reindex the entire collection.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants