Bug 25968 - Make logs sort by date descending as a default and add column configuration options
Summary: Make logs sort by date descending as a default and add column configuration o...
Status: Pushed to stable
Alias: None
Product: Koha
Classification: Unclassified
Component: Templates (show other bugs)
Version: master
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Owen Leonard
QA Contact: Testopia
URL:
Keywords:
: 24251 (view as bug list)
Depends on:
Blocks:
 
Reported: 2020-07-09 17:14 UTC by Barbara Johnson
Modified: 2020-08-07 14:38 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Who signed the patch off:
Text to go in the release notes:
Version(s) released in:
20.11.00, 20.05.03


Attachments
Bug 25968: Make logs sort by date descending as a default (4.83 KB, patch)
2020-07-10 13:33 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 25968: Make logs sort by date descending as a default (4.88 KB, patch)
2020-07-16 19:27 UTC, ByWater Sandboxes
Details | Diff | Splinter Review
Bug 25968: Make logs sort by date descending as a default (4.94 KB, patch)
2020-07-29 22:35 UTC, Katrin Fischer
Details | Diff | Splinter Review
Bug 25968: Make logs sort by date descending as a default (4.91 KB, patch)
2020-07-30 14:17 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Barbara Johnson 2020-07-09 17:14:26 UTC
It would be helpful to have the logs sort by date descending so that you can view the newest items at the top of the page rather than having to scroll to the bottom.
Comment 1 Owen Leonard 2020-07-10 13:33:35 UTC Comment hidden (obsolete)
Comment 2 ByWater Sandboxes 2020-07-16 19:27:42 UTC
Created attachment 106967 [details] [review]
Bug 25968: Make logs sort by date descending as a default

This patch adds DataTables with columns configuration to the log viewer.
The table of log entries is now sorted by default by date descending.

To test, apply the patch and go to Administration -> Table settings.

 - Expand the "Tools" section and confirm that there is a section for
   "logviewer."
 - Go to Tools -> Log viewer.
 - Perform a search which will return multiple results.
 - Confirm that the results are sorted by date descending.
 - Test that the table controls work correctly: Paging, columns, export.
 - Return to the Table settings administration page and test that
   changes to those settings are correctly reflected in the log viewer
   table.

Signed-off-by: barbara <barbara.johnson@bedfordtx.gov>
Comment 3 Owen Leonard 2020-07-28 19:28:49 UTC
*** Bug 24251 has been marked as a duplicate of this bug. ***
Comment 4 Katrin Fischer 2020-07-29 22:35:35 UTC
Created attachment 107552 [details] [review]
Bug 25968: Make logs sort by date descending as a default

This patch adds DataTables with columns configuration to the log viewer.
The table of log entries is now sorted by default by date descending.

To test, apply the patch and go to Administration -> Table settings.

 - Expand the "Tools" section and confirm that there is a section for
   "logviewer."
 - Go to Tools -> Log viewer.
 - Perform a search which will return multiple results.
 - Confirm that the results are sorted by date descending.
 - Test that the table controls work correctly: Paging, columns, export.
 - Return to the Table settings administration page and test that
   changes to those settings are correctly reflected in the log viewer
   table.

Signed-off-by: barbara <barbara.johnson@bedfordtx.gov>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 5 Katrin Fischer 2020-07-29 22:35:56 UTC
Extended the bug description a bit and it looks like this also fixed the date sorting for different formats?
Comment 6 Jonathan Druart 2020-07-30 14:17:48 UTC
Created attachment 107593 [details] [review]
Bug 25968: Make logs sort by date descending as a default

This patch adds DataTables with columns configuration to the log viewer.
The table of log entries is now sorted by default by date descending.

To test, apply the patch and go to Administration -> Table settings.

 - Expand the "Tools" section and confirm that there is a section for
   "logviewer."
 - Go to Tools -> Log viewer.
 - Perform a search which will return multiple results.
 - Confirm that the results are sorted by date descending.
 - Test that the table controls work correctly: Paging, columns, export.
 - Return to the Table settings administration page and test that
   changes to those settings are correctly reflected in the log viewer
   table.

Signed-off-by: barbara <barbara.johnson@bedfordtx.gov>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

JD amended patch: Fix indentation in .yml to match other entries
Comment 7 Jonathan Druart 2020-07-30 15:47:21 UTC
Pushed to master for 20.11, thanks to everybody involved!
Comment 8 Lucas Gass 2020-08-06 20:22:15 UTC
Handy and small enhancement, choosing to backport to 20.05.x for 20.05.03
Comment 9 Aleisha Amohia 2020-08-07 02:11:57 UTC
enhancement, not backported to 19.11.x (even though I agree, it is a handy one)
Comment 10 Jonathan Druart 2020-08-07 14:38:21 UTC
(In reply to Lucas Gass from comment #8)
> Handy and small enhancement, choosing to backport to 20.05.x for 20.05.03

Lucas, there is a failure coming from this backport:

23:25:27 koha_1       | #   Failed test '/kohadevbox/koha/koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt'
23:25:27 koha_1       | #   at xt/author/valid-templates.t line 141.
23:25:27 koha_1       | # plugin error - TablesSettings: plugin not found

ColumnsSettings has been replaced by TablesSettings.