pulibrary / static-tables

Searchable index of Marquand Auction Catalogs
https://library.princeton.edu/marquand_catalogs/
MIT License
0 stars 0 forks source link

[Historical Photograph Collection] Search for keywords across multiple columns #173

Closed maxkadel closed 1 month ago

maxkadel commented 2 months ago

User story

As a user, I want to be able to find historical photographs of particular subjects, whether or not that term is included in the "subject" field.

From the stakeholder:

Could the “subject” search become a “keyword” search anywhere in the fields?

For example, if I search for “hospital” in the new db in the subject field, I receive one result

If I search for “hospital” in the old db I receive 17 results—I am wondering if the search in the new db is considering the note field as well, as there is only one result with the word hospital in the title, the others are all in the note field.

Also, I can’t currently search for an image no. in the available search boxes and receive a result.

(See google doc for screenshots)

Acceptance criteria

Concrete example

A search for "hospital" should include at least 17 results

Implementation notes, if any

Right now, this filter searches in a concatenated field on the spreadsheet. We could either add more fields to the concatenated field, or implement in a different way - make the text filter configurable so that it can search more fields.

https://github.com/pulibrary/static-tables/blob/d6288b2a19a8f8e5f5782c7249a1413c0af4ae69/app/configs/HistoricalPhotographCollection.js#L27-L35