Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add filters to the catalogue grid #22

Open
geealbers opened this issue Jan 31, 2019 · 1 comment
Open

Add filters to the catalogue grid #22

geealbers opened this issue Jan 31, 2019 · 1 comment
Labels
enhancement New feature or request

Comments

@geealbers
Copy link
Member

Though there are only 24 objects in this volume, as we have in past catalogues like Ancient Terracottas and Ancient Lamps, we could add some filters to the CVA catalogue grid so that users could get a visual representation of different groupings. I think the obvious categories would be to filter by

  • Attribution
  • Subject
  • Date

The first two would offer a nice visualization of the attribution and subject indexes (though the subject drop down would be quite long so maybe not practical). The third is sort of standard, though would require some adjustment to the data in objects.yml. Instead of:

date: -490 to -480

We would need something like:

start_date: -490
end_date: -480

Or maybe just:

dates: 
  - -490
  - -480
@geealbers geealbers added the enhancement New feature or request label Jan 31, 2019
@geealbers
Copy link
Member Author

This filter feature will be used here in CVA and included in the core Quire Starter Theme.

screen shot 2019-02-26 at 9 54 52 pm

The filters will be variable from project to project, so users will need a direct way to choose what keys in the object data to filter on. I would suggest we follow the pattern established with object_display_order (used to populate the entry page tombstones), and establish a new object_filter array.

object_display_order:
  - plates
  - accession_number
object_filter:
  - attribution
  - subject
  - date
object_list:
  - id: 1
    plates: "518–20"
    plate_list: 518, 519, 520
    accession_number: 86.AE.205
    link: http://www.getty.edu/art/collection/objects/11968/
    bareiss_number: 342
    fabric: Athenian
    technique: Red-figure
    shape_name: Krater, Column-
    attribution: Myson
    date: -490 to -480
    subject: akontist, athlete, bridle, deer, dog, goat, *haltēres*, himation, horse, javelin, jumper, *kentron*, *paedotribēs*, palmette (*anthemion*), panther, pick, sponge, staff, stick, strigil, trainer

Ask with this, we'd also want to establish a new param for config.yml to turn the feature on or off. Perhaps gridObjectFilters: true.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant