gwu-libraries / launchpad

A django based system that provides a stable URL for every item in the library's catalog. Various discovery services will link to these URLs. The page for each item will in turn link out to various other resources that provide methods for accessing the content of the items.
MIT License
15 stars 9 forks source link

sort periodical holdings in descending order by call number and item enum #1152

Open cummingsm opened 8 years ago

cummingsm commented 8 years ago

The continuing resources group recommends listing the most recent periodical issue first, generally speaking the volumes should be sorted from high to low.

Use case item 2274417 has three volumes: 1, 3, and 8. The revised sort order from top down will be volumes 8, 3, and 1. Sorting needs to ignore case, as some volumes are indicated by lower case 'v' and some are uppercase 'V'. This bib record has two holdings. As of 7/7/16 three are attached to holding 2626864 (gwg w) which has a call number RC 467.P7. The three items all have temporary location "wrlc stor" and all the item statuses are 'Charged'. All three have item type Regular loan.

The other seven volumes are items currently attached to a suppress holding 2626865 which has no call number. These items are all in item status 'Charged' and all are item type 'Periodical.' If we unsuppress the WRLC holding the volumes would display as well. That is the intention. There may be a problem however, with listing all the volumes in sequential order from 9 to 1 because of the fact that there are two different holdings and different item temporary locations. It is likely that the page will show volumes 8,3,1 and then volumes 9,7,6,5,4,2,and 1. (Notice volume 1 is listed on both holdings)

image

cummingsm commented 8 years ago

Use case no.2 bib 2272252. This record has two unsuppressed print holdings with many items. Neither holding has a call number. The holding with location 'gwg p' has two groups of items. One group is items with perm location 'gwg p'. These items do not have a temp location.The items are not charged, and are item type Regular loan, except one item is item type non-circulating, with item enumeration 'Current Periodicals'. The item enumeration for these volumes range from vol 76 to vol 78. A second grouping on this holding is a set of items with temp location WRLC Shared periodical, where all the items are Charged, again volumes range from vol 76 to vol 78. The display we want is in reverse volume order from v.78:no.22(2012)-v.78:no.24(2012) to v.76.no.1(2010)-v76:no.4(2010)

The other holding, 2623887 is holding location 'wrlc stnc', and there are two groups of items. One set of items has temporary location WRLC Shared Per. Discard, item type 1day loan, item status Not Charged; another set has temp location WRLC Shared periodical, 1day loan, item status Charged. The display we want is in reverse volume order. These would be interfiled with the other holding.

cummingsm commented 8 years ago

Use case no.3, bib 2357106. This record has a lot of volumes that would be a good test of sorting by item enumeration. We might use a function to take a set of item enumeration values and normalize them for sorting purposes. I have prototyped a step-by-step way to normalize the values, which is shown in the attached spreadsheet with examples. normalize-enumeration.xlsx