LP1991103: Display a count of record notes in the staff catalog tab To test: 1. Apply this patch. 2. Open a record in the staff catalog. 3. Add some record notes. Note that the tab updates with the number of record notes on the record. 4. Delete some record notes. Note that the tab still updates accordingly. 5. Leave and come back to the record. Note that the number still persists in that tab. Release-Note: Show the total number of record notes in the Record Note tab in the staff catalog. Sponsored-by: PaILS Signed-off-by: Jane Sandberg <sandbergja@gmail.com> Signed-off-by: Elizabeth Davis <elizabeth.davis@sparkpa.org> Signed-off-by: Tiffany Little <tlittle@georgialibraries.org> Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
LP#2051708: Cache MR summary calculations As part of the angularization of the staff catalog, new logic was added to the bib summary API that gathers record attributes for the constituent records of a result's metarecord. For very large metarecords (~100+ constituents) this can be very slow, and when a search returns many bibs from the same metarecord, the underlying data is retrieved separately for each bib. This commit creates a temporary local cache to avoid repeating the caclulation of MR summary data on the same result set page. Release-note: Improve speed of searching for and displaying (in Staff View) titles that are members of large metarecord sets. Signed-off-by: Mike Rylander <mrylander@gmail.com> Signed-off-by: Galen Charlton <gmc@equinoxOLI.org> Signed-off-by: Jason Boyer <JBoyer@equinoxOLI.org>
LP#2039229: handle staff view for bibs without metarecord mappings Release-note: Fix crash when displaying Staff View for a deleted record that has no metarecord mappings. Signed-off-by: Jeff Davis <jdavis@sitka.bclibraries.ca> Signed-off-by: Mike Rylander <mrylander@gmail.com> Signed-off-by: Galen Charlton <gmc@equinoxOLI.org> Signed-off-by: Jason Boyer <JBoyer@equinoxOLI.org>
LP#2004055: Simpler Display Field highlighting This commit uses database functions to precompute the normalized and tokenized tsquery required for highlighting before it is returned to the user, and disallows highlight-time compilation of the highlight map. The primary purpose of this is to avoid the chance for user input to find its way directly into SQL statements, but an additional benefit is that it becomes much simpler for high level application code to make use of Display Field highlighting in non-search contexts. Signed-off-by: Mike Rylander <mrylander@gmail.com> Signed-off-by: Galen Charlton <gmc@equinoxOLI.org> Signed-off-by: Jason Boyer <JBoyer@equinoxOLI.org>
LP#1997485: Multi-term Did You Mean Expanding on the previous single-class, single-term search suggestion development, this feature provides suggestions for single-class searches with multiple terms. * The Library Settings that were previously used to control the global behavior of search suggestions have been moved to search class configuration fields. This was done because the data in each search class benefits from different setting values. * If a patron's search brings back a suggestion that matches an authority variant heading, the system will provide the main heading as a suggestion as well, along with spelling-corrected suggestions. * Quoated phrases in user input require strict term order and adjacency for the phrase portion of the suggestion generated for the phrase(s), whereas unquoted input (or the portion that is not quoted) does not. MARC Search/Facet Class (config.metabib_class) field additions: * variant_authority_suggestion Whether this class should attempt variant authority suggestions based on search-class/browse-axis mapping * symspell_transfer_case Whether suggestions should retain user-supplied letter case * symspell_skip_correct Only supply suggestions to misspelled words * symspell_suggestion_verbosity Setting that controls the amount of effort, and therefore time, spent on suggestion generation * max_phrase_edit_distance Maximum average per-word edit distance when evaluating suggestions * suggestion_word_option_count Maximum alternate suggestions per word * max_suggestions Maximum suggstions to present * low_result_threshold Maximum hit count beyond which suggestions are not provided * min_suggestion_use_threshold Minimum number of times a suggestion must exist in the corpus * pg_trgm_weight Weight of the trigram similarity metric; 0 avoids calculation costs * soundex_weight Weight of the soundex similarity metric; 0 avoids calculation costs * keyboard_distance_weight Weight of the keyboard distance similarity metric; 0 avoids calculation costs Signed-off-by: Mike Rylander <mrylander@gmail.com> Signed-off-by: Ruth Frasur <rfrasur@library.in.gov> Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
lp1959010 toward Staff View tab * make our Staff View tab with the new BibStaffView widget * seed our BibStaffView with BibSummary * first attempt at changing some identifiers with our seed code * experimenting with layout and stripping courses functionality * simplifying the layout for now and adding display fields * moar data * layout tweaks and propagate metabib attributes for Formats and Editions * don't cross the streams with metabib related * field names for the record and metabib variants of the catalog_summary call. This would otherwise break some links in search results involving bibs with metarecords. * hyperlinks for the formats and editions in the catalog staff view * fix catalog_summary vs catalog_summary.staff bug * searchOrg depth was being passed where a boolean was expected * This seems like a failure of TypeScript to detect.. type. What was going on here? * layout and css tweaking * fixing toc and relocating it and some other fields to column 1 * label fix Signed-off-by: Jason Etheridge <jason@EquinoxOLI.org> Signed-off-by: Mary Llewellyn <mllewell@biblio.org> Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
LP#1361782: Add DoS protection This commit adds two types of simple DoS protection: * Limit concurrent search requests per client IP address, regardless of the searches being performed. This helps address issues of accidental spamming from a malfunctioning OPAC workstation, or crawlers of various types. The limit is controlled by a global flag called "opac.max_concurrent_search.ip". * Limit the global concurrent search requests for the same query. This helps address both simple and distributed DoS that send the same search request over and over. The limit is controlled by a global flag called "opac.max_concurrent_search.query", and defaults to 20. When the limit is exceeded in either case the client receives an HTTP 429 "Too many requests" response from the web server, and the connection is ended. Signed-off-by: Mike Rylander <mrylander@gmail.com> Signed-off-by: Jason Stephenson <jason@sigio.com> Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
LP#1955079: Use Email::MIME for emailing records in the OPAC Email::Simple was mangling the headers. Let's use Email::MIME instead. Signed-off-by: Jane Sandberg <sandbergja@gmail.com> Signed-off-by: Garry Collum <gcollum@gmail.com> Signed-off-by: Michele Morgan <mmorgan@noblenet.org>
LP#1955079: Staff catalog can't email records The angular staff catalog uses the new print/email records functionality, but calls it without some expected parameters. This causes the backend method to fail as it assumes the params will exist. This commit removes that assumption by testing the length of the parameter list before attempted to read them. Signed-off-by: Mike Rylander <mrylander@gmail.com> Signed-off-by: Jane Sandberg <sandbergja@gmail.com> Signed-off-by: Michele Morgan <mmorgan@noblenet.org>
LP#1955931 Staff catalog show more details - add due date Adds a due date column to the show more details view in the Angular staff catalog. Signed-off-by: Dan Briem <dbriem@wlsmail.org> Signed-off-by: Garry Collum <gcollum@gmail.com> Signed-off-by: Michele Morgan <mmorgan@noblenet.org>
LP1933275 Staff catalog holdings view shows correct counts teaches the Holdings view to determine the number of copies and call numbers attached to each org unit based on the full data set (via new API) instead of copies in hand, since we may only have copies in hand for a subset of child org units. Signed-off-by: Bill Erickson <berickxx@gmail.com> Signed-off-by: Mary Llewellyn <mllewell@biblio.org> Signed-off-by: Jane Sandberg <sandbergja@gmail.com>
LP1928359 Add item circ info to Item Table Adds "Total Circ Count" and "Last Circ Date" to the staff catalog Item Table grid view. Signed-off-by: Bill Erickson <berickxx@gmail.com> Signed-off-by: Shula Link <slink@gchrl.org> Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
LP#1929587 Place hold button in staff client Disables and gray's out the place hold button on records in the Angular catalog that are deleted or have no holdable copies unless the user has the perm PLACE_UNFILLABLE_HOLD. To test: * Search for records with and without any copies * Search for records with and without holdable copies * Search as user with and without the permission PLACE_UNFILLABLE_HOLD Signed-off-by: Dan Briem <dbriem@wlsmail.org> Signed-off-by: Terran McCanna <tmccanna@georgialibraries.org> Signed-off-by: Bill Erickson <berickxx@gmail.com>
LP1923076: Add cast to int in more places Add cast to int of scalar used on arrays in more places where it seems necessary. Signed-off-by: Jason Stephenson <jason@sigio.com> Signed-off-by: Michele Morgan <mmorgan@noblenet.org> Signed-off-by: Mike Rylander <mrylander@gmail.com>
LP1913807 Staff catalog shows preferred lib holdings counts Always show holdings counts for the preferred library (when set) even when the library is not directly in the search scope. Signed-off-by: Bill Erickson <berickxx@gmail.com> Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
LP1910808 Staff catalog show call number In the search results page, show the first call number for each record (sorting by label sortkey) that is owned either by the user's preferred library or the search library. Signed-off-by: Bill Erickson <berickxx@gmail.com> Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
LP1908722 Staff catalog Show More Details Adds a "Show More Details" (and "Show Fewer Details") buttons to the Angualr staff catalog. Similar to the TPAC, activating the button means more holdings details are displayed in the search results page. Adds a new workstation setting type called 'eg.staff.catalog.results.show_more' Signed-off-by: Bill Erickson <berickxx@gmail.com> Signed-off-by: Galen Charlton <gmc@equinoxOLI.org> Signed-off-by: Michele Morgan <mmorgan@noblenet.org>
LP#1930088 Angular catalog: metarecord search returns no results This adds a missing param to a call to get_one_record_summary that's necessary after commit c07ce8. To test, perform a search using the Group Formats/Editions checkbox and you should see results. Signed-off-by: Dan Briem <dbriem@wlsmail.org> Signed-off-by: Michele Morgan <mmorgan@noblenet.org> Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
LP1881607 E-resource relationship labels Display the relationship designation for 856 URL's in the staff catalog. See Second Indicator: https://www.loc.gov/marc/bibliographic/bd856.html Signed-off-by: Bill Erickson <berickxx@gmail.com> Signed-off-by: Elaine Hardy <ehardy@georgialibraries.org> Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
LP1881607 Angular catalog located URIs Display in-range located URIs in the staff catalog record summary pane. Also applies a fix to the staff catalog to clear cached record detail summaries on new searches to ensure the correct org-scoped version of the record summary is retrieved on each new navigation to the detail page. Signed-off-by: Bill Erickson <berickxx@gmail.com> Signed-off-by: Elaine Hardy <ehardy@georgialibraries.org> Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>