Summary: | Table sorting using title-string option is obsolete | ||
---|---|---|---|
Product: | Koha | Reporter: | Martin Renvoize (ashimema) <martin.renvoize> |
Component: | Staff interface | Assignee: | Bugs List <koha-bugs> |
Status: | NEW --- | QA Contact: | Testopia <testopia> |
Severity: | enhancement | ||
Priority: | P5 - low | CC: | fridolin.somers, gmcharlt, jonathan.druart, oleonard, sally.healey, tomascohen |
Version: | Main | Keywords: | Academy |
Hardware: | All | ||
OS: | All | ||
See Also: | https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27926 | ||
Change sponsored?: | --- | Patch complexity: | --- |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: | ||
Circulation function: | |||
Bug Depends on: | 27974, 27975, 27980, 27982, 27983, 27990, 27994, 27998, 28007, 28016, 28018 | ||
Bug Blocks: | |||
Attachments: |
Bug 27934: Update waiting_holds.inc to use data-order
Bug 27934: Update waiting_holds.inc to use data-order |
Description
Martin Renvoize (ashimema)
2021-03-11 15:39:59 UTC
It must be data-order https://datatables.net/manual/data/orthogonal-data#HTML-5 We use it already in a few places. That's a really useful page of documentation Jonathan, thanks for linking it :) Created attachment 118182 [details] [review] Bug 27934: Update waiting_holds.inc to use data-order This patch updates the waiting_holds table to use data-order attributes on the "Waiting since" and "Date hold placed" fields. Test plan 1/ Prior to applying the patch navigate to a page that displays waiting holds 2/ Hover over the the "Waiting since" and "Date hold placed" data fields and note that you are faced with a tooltip with the iso formatted date. 3/ Apply the patch 4/ Check that sorting still works as expected for the two columns 5/ You should no longer be able to trigger the tooltip Example patch.. there's allot of these to fix... Find more cases with a simple grep for 'title-string' in the templates directories Created attachment 118206 [details] [review] Bug 27934: Update waiting_holds.inc to use data-order This patch updates the waiting_holds table to use data-order attributes on the "Waiting since" and "Date hold placed" fields. Test plan 1/ Prior to applying the patch navigate to a page that displays waiting holds 2/ Hover over the the "Waiting since" and "Date hold placed" data fields and note that you are faced with a tooltip with the iso formatted date. 3/ Apply the patch 4/ Check that sorting still works as expected for the two columns 5/ You should no longer be able to trigger the tooltip Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> Sorry, I keep jumping too soon - who knew that signing off bugs was so exciting? ;) Happy to sign off again once it's ready for testing. I agree that we should update the templates to use the newer sorting option. I've updated the bug title to make it clear that it's about an obsolete option. Still a couple of occurrences in waiting_holds.inc then we are good to remove the functions in datatables.js Added a QA check https://gitlab.com/koha-community/qa-test-tools/-/issues/48 Issue #48 - Forbid title-string class for sorting Recent push : Bug 27926: Add 'title-string' for dates on circ-patron-results Does it need to be patched ? (In reply to Fridolin Somers from comment #11) > Recent push : > Bug 27926: Add 'title-string' for dates on circ-patron-results > > Does it need to be patched ? That already had a follow-up to fix it :) It looks like we sill got some remaining title-string attributes: koha-tmpl/intranet-tmpl/prog/en/includes/columns_settings.inc: { "targets": [ "title-string" ], "type": "title-string" }, koha-tmpl/intranet-tmpl/prog/en/modules/recalls/recalls_to_pull.tt: <th class="recall-date title-string">Earliest recall date</th> koha-tmpl/intranet-tmpl/prog/en/modules/recalls/recalls_to_pull.tt: { "sType": "title-string", "aTargets" : [ "title-string" ] }, koha-tmpl/intranet-tmpl/prog/en/modules/recalls/recalls_waiting.tt: <th class="recall-waitingdate title-string">Available since</th> koha-tmpl/intranet-tmpl/prog/en/modules/recalls/recalls_waiting.tt: <th class="recall-waitingdate title-string">Available since</th> columns_settings.inc is obviously correct The recall ones need to be adjusted. |