Bug #12707
Finding aids will display custom LODs as "otherlevel" instead of using the otherlevel value
Status: | Verified | Start date: | 01/14/2019 | |
---|---|---|---|---|
Priority: | Medium | Due date: | ||
Assignee: | - | % Done: | 0% | |
Category: | Finding aids | |||
Target version: | Release 2.6.0 | |||
Google Code Legacy ID: | Tested version: | 2.4, 2.5, 2.6 | ||
Sponsored: | No | Requires documentation: |
Description
When a custom level of description is created in AtoM, the resulting EAD looks like the following example (where a level has been created for "Box"):
<c otherlevel="box" level="otherlevel">
When a finding aid is generated, AtoM will use the @level value, resulting in the finding aid listing "otherlevel" as the level of description, as in the attached image:
Instead, we should add a custom rule that says, when the value of @level is "otherlevel", use the @otherlevel value instead.
To reproduce
- Navigate to Manage > Taxonomies > Levels of description and add a new custom level, e.g. "Box"
- Save and navigate to an existing archival unit
- Add a new lower-level of description, using the custom "Box" LOD, and save
- Generate a finding aid
Resulting error
- Box levels are listed as "otherlevel" in the finding aid generated.
- The value of the @otherlevel attribute is ignored
An example from an AtoM site currently being used in production can be seen here:
Expected result
- The finding aid output should say "box"
- When the value of @level is "otherlevel", use the @otherlevel value instead
History
#1 Updated by Mike Cantelon almost 3 years ago
- Assignee set to Mike Cantelon
#2 Updated by Mike Cantelon almost 3 years ago
- Status changed from New to In progress
#3 Updated by Mike Cantelon almost 3 years ago
- Status changed from In progress to Code Review
- Assignee deleted (
Mike Cantelon)
PR for CR: https://github.com/artefactual/atom/pull/938
#4 Updated by David Juhasz almost 3 years ago
- File walden-garden-club-2.pdf added
- Status changed from Code Review to Feedback
- Assignee set to Mike Cantelon
Dan and Mike,
I tried testing this fix by adding two child descriptions to the "Walden Garden Club" Fonds from our sample data, e.g. https://demo.accesstomemory.org/membership-and-executive-board-lists- A "Text box" description with LOD: Box
- A "Test item" description with LOD: Item
The resulting Finding aid is attached (walden-garden-club-2.pfd).
Note:
- The "Text box" description with LOD: Box shows up with the same formatting as the "Series" level descriptions, and no level of description is listed
- A blank "File/item" table is displayed in the "Series 009-1: Membership and Executive Board Lists"
- The "Test item" description shows up in a separate "file/item" list but it's level of description is missing
Mike, my understanding is that both @otherlevel and @level attrbiutes must be supported for this feature to work properly. @level is used for standard levels of description (e.g. Fonds, Series, Item) and @otherlevel is used for custom LODs (e.g. Box).
#5 Updated by David Juhasz almost 3 years ago
@Dan Gillean I don't know how the Finding aid template is going to correctly format custom LODs (e.g. box), as it looks like the formatting is hardcoded by LOD. :(
#6 Updated by Dan Gillean almost 3 years ago
David you are correct that both @level and @otherlevel need to be used. I'll copy the definition of both attributes below for reference.
I don't know what our XSLT looks like currently or if this is possible, but could we perhaps use an <xsl:if> or <xsl:choose> statement, to say:
IF the @level value IS otherlevel
THEN use the otherlevel value as the level
See:
- https://www.w3schools.com/xml/xsl_if.asp
- https://www.w3schools.com/xml/xsl_choose.asp
- https://stackoverflow.com/questions/13622338/how-to-implement-if-else-statement-in-xslt
If that's not possible (or beyond the scope of what we can do now), then I guess we'll just leave this ticket as-is for now. It's not a super high priority, just a nice to have I was hoping would be easy to knock off.
@LEVEL in EAD 2002:
LEVEL -- The hierarchical level of the materials being described by the element. This attribute is available in <archdesc>, where the highest level of material represented in the finding aid must be declared (e.g., collection, fonds, record group), and in <c> and <c01-12> (e.g., subgroup, series, file). If none of the values in the semi-closed list are appropriate, the value "otherlevel" may be chosen and the term specified in the OTHERLEVEL attribute. Values are:
- collection
- fonds
- class
- recordgrp
- series
- subfonds
- subgrp
- subseries
- file
- item
- otherlevel
@OTHERLEVEL in EAD 2002:
OTHERLEVEL -- The hierarchical level of the materials described in <archdesc>, <c>, <c01-12>, and <archdescgrp> can be specified when the semi-closed list in the LEVEL attribute (e.g., collection, fonds, series, etc.) does not contain an appropriate term. Set LEVEL to "otherlevel" and then supply the preferred term in the OTHERLEVEL attribute.
#7 Updated by Mike Cantelon almost 3 years ago
- Assignee changed from Mike Cantelon to David Juhasz
Did the change I made cause the other issues to happen or are the other issues additional things that need fixing?
#8 Updated by David Juhasz almost 3 years ago
Mike, I think the change you made caused the "item" description level of description to disappear - as the item LOD value will be represented by the "@level" attribute (and no @otherlevel attribute is set).
The fact that the "Box test" description shows up with formatting like the series level descriptions I assume is due to the finding aid formatting being hard-coded to certain levels of description, i.e. because the "Box test" is not an file or item level description it does not show up in the file/box list table.
I'm not sure why the blank file/item table row is being displayed - maybe that is keyed on position of the description in the hierarchy instead of LOD?
#9 Updated by David Juhasz almost 3 years ago
- Assignee changed from David Juhasz to Mike Cantelon
#10 Updated by David Juhasz almost 3 years ago
- File walden-garden-club-2.xml
added
I've attached the corresponding EAD for my test data (walden-garden-club-2.xml)
Note the <c> element for the "Text box" description:<c otherlevel="box" level="otherlevel">
vs. the "Test item" description:<c level="item">
#11 Updated by Mike Cantelon almost 3 years ago
I've updated this PR with, hopefully, a fix.
#12 Updated by Mike Cantelon almost 3 years ago
- Assignee changed from Mike Cantelon to David Juhasz
#13 Updated by Mike Cantelon almost 3 years ago
- Status changed from Feedback to Code Review
#14 Updated by Mike Cantelon over 2 years ago
I've updated the PR... let me know what you think!
#15 Updated by Mike Cantelon over 2 years ago
- Status changed from Code Review to QA/Review
- Assignee deleted (
David Juhasz)
Merged into qa/2.6.x
#16 Updated by Dan Gillean over 2 years ago
- Status changed from QA/Review to Feedback
- Assignee set to Mike Cantelon
- Tested version 2.5, 2.6 added
I'm still seeing "otherlevel" show up as the LOD in the file/item table summary. Attaching the sample record (with added levels Sub-sub-subseries, Part, Box, and Sub-part) all used in records nested below series 01) used during testing.
#17 Updated by Dan Gillean over 2 years ago
- File flora-roy-with-extra-levels.csv
added
#18 Updated by Mike Cantelon over 2 years ago
- Status changed from Feedback to Code Review
- Assignee deleted (
Mike Cantelon)
PR for CR: https://github.com/artefactual/atom/pull/991
#19 Updated by Mike Cantelon over 2 years ago
- Status changed from Code Review to QA/Review
Merged into qa/2.6.x for QA.
#20 Updated by Dan Gillean over 2 years ago
- Status changed from QA/Review to Verified
- Target version set to Release 2.6.0