Uploaded image for project: 'mod-inventory-storage'
  1. mod-inventory-storage

Store Shelving Order in item (LC call numbers only)



    • Story
    • Status: Closed (View Workflow)
    • P3
    • Resolution: Done
    • None
    • 20.0.0
    • Prokopovych - Sprint 107, Prokopovych - Sprint 108
    • 8
    • Prokopovych



      Allow for items (that have LC call numbers) to be sorted by shelving order (based upon call number and related fields)


      Refer to UIIN-816 for how this field will be presented.


      1. Introduce a new property for the shelving order (the definition should be read only)
      2. Use the existing library to generate the shelving order (artefacts are in maven central)
      3. The input to this library should be a string concatenation of the following properties: call number, volume, enumeration, chronology, copy number, suffix
      4. For the call number and suffix properties, these should come from the effective call number components
      5. Store the output from the library in the new property

      This should be done, under the following circumstances:

      • When an item is created or updated (either individually or in a batch)
      • When a holdings record is updated (either individually or in a batch), all items associated with it should be updated (as this can change the derivation of the input properties)

      This should be done in a similar manner to other derived properties for items

      Out of Scope
      • Deriving the shelving order for existing item records (this is covered by MODINVSTOR-521)

      Generating the shelving order

      String input = call number + " " + volume + " " + enumeration + " " + chronology + " " + copy number + " " + suffix;
      LCCallNumber call = new LCCallNumber(input);
      String shelfKey = call.getShelfKey();

      Examples on sorted values:

      sort order prefix call number volume enumeration chronology copy suffix
      PN12 .A6   PN2 .A6          
      PN2 .A6 v.3 no.2 1999   PN2 .A6 v. 3 no. 2 1999    
      PN12 .A6 41999   PN2 .A6 1999          
      PN12 .A6 41999 CD   PN2 .A6 1999         CD
      PN12 .A6 41999 C.12   PN2 .A6 1999       2  
      PN12 .A69 41922   PN2 .A69     1922    
      PN12 .A69 41922 C.12   PN2 .A69     1922 2  
      PN12 .A69 NO.12   PN2 .A69   no. 2      
      PN12 .A69 NO.12 41922 C.11   PN2 .A69   no. 2 1922 1  
      PN12 .A69 NO.12 41922 C.12 Wordsworth PN2 .A69   no. 2 1922 2  
      PN12 .A69 V.11 NO.11   PN2 .A69 v.1 no. 1      
      PN12 .A69 V.11 NO.11 + Over PN2 .A69 v.1 no. 1     +
      PN12 .A69 V.11 NO.11 41921   PN2 .A69 v.1 no. 1 1921    
      PR 49199.3 41920 .L33 41475 .A6   PR9199.3 1920 .L33 1475 .A6          
      PQ 42678 .K26 P54   PQ2678.K26 P54          
      PQ 48550.21 .R57 V15 41992   PQ8550.21.R57 V5 1992          
      PQ 48550.21 .R57 V15 41992   PQ8550.21.R57 V5     1992    
      PR 3919 .L33 41990   PR919 .L33 1990          
      PR 49199 .A39   PR9199 .A39          
      PR 49199.48 .B3   PR9199.48 .B3          

      Complying with the library licence

      Include the following in the published jar:

      • a copy of the license
      • a note that MARC4J is covered by it, and
      • a link to the source repository on GitHub

      Add https://www.mojohaus.org/license-maven-plugin/add-third-party-mojo.html to the pom.xml to automatically create a THIRD-PARTY.txt file that contains a link to https://github.com/marc4j/marc4j where the marc4j source code can be downloaded. The plugin will add THIRD-PARTY.txt to the mod-inventory-storage jar.

      TestRail: Results


          Issue Links



                Andrii Shapovalov Andrii Shapovalov
                lauraw Laura Daniels
                Charlotte Whitt Charlotte Whitt
                0 Vote for this issue
                10 Start watching this issue



                  TestRail: Runs

                    TestRail: Cases