omeka / omeka/plugin-ExhibitBuilder
Sorting by date added field
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 25
- Forks
- 37
- PR merge metrics
- No merged PRs in 30d
Description
The sorting by Date Added appears to be sorting on the id field, not the actual date added field.
I'm sure for 99% of users, this is totally fine. In my case, I want to sort my exhibits by a specified date (each exhibit represents a different event and I want to list them chronologically). I'm doing a hacky thing and manually setting Date Added in the database to the event date. My events are listed in the proper descending order if I sort by Recent, but if I sort by Date Added it is sorting on id.
I've hacked in a fix (In ExhibitController, changed _getBrowseDefaultSort function so that the default case matches the recent case and except using 'a' instead of 'd'), so I'm good.
I don't think that this is ever an issue unless people are monkeying with Date Added in the database. Ideally it would be great to have more sorting options for exhibits, but if not, hopefully by at least posting this someone else will be saved from a lot of confusion.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in ExhibitController at _getBrowseDefaultSort, comparing the Date Added default case with the Recent case described in the issue. Confirm that sorting by Date Added uses the actual date-added field rather than the exhibit id, and verify that exhibits with manually set dates appear in chronological order.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 48/100