Bugzilla – Attachment 173474 Details for
Bug 33484
Ability to remember user's selected table configuration and search filters for tables
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 33484: Allow several tables using the same table settings - columns_settings
Bug-33484-Allow-several-tables-using-the-same-tabl.patch (text/plain), 2.69 KB, created by
Jonathan Druart
on 2024-10-28 09:46:12 UTC
(
hide
)
Description:
Bug 33484: Allow several tables using the same table settings - columns_settings
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2024-10-28 09:46:12 UTC
Size:
2.69 KB
patch
obsolete
>From 02a21fc1fd4adca99ea4a15aff0f5a9128e1200c Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Thu, 17 Oct 2024 12:32:34 +0200 >Subject: [PATCH] Bug 33484: Allow several tables using the same table settings > - columns_settings > >In some cases (at least on the suggestions page) we display several >pages using the same settings. >In that case the key "DataTables_acqui_suggestions_suggestions" is not >specific enough, we need to add the id of the table as well. > >This patch does not modify koha-tmpl/intranet-tmpl/prog/js/datatables.js >/ REST API wrapper as I don't think we have occurrences that need this. > >Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com> >Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > .../prog/en/includes/columns_settings.inc | 12 ++++++++---- > 1 file changed, 8 insertions(+), 4 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/columns_settings.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/columns_settings.inc >index fdc33745691..30146653da2 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/columns_settings.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/columns_settings.inc >@@ -14,10 +14,12 @@ function KohaTable(id_selector, dt_parameters, table_settings, add_filters) { > > let columns_settings = table_settings["columns"]; > >- let table_key = 'DataTables_%s_%s_%s'.format( >+ let table_key = 'DataTables_%s_%s_%s_%s'.format( > table_settings.module, > table_settings.page, >- table_settings.table); >+ table_settings.table, >+ id_selector, >+ ); > > let default_save_state = table_settings.default_save_state; > let default_save_state_search = table_settings.default_save_state_search; >@@ -221,10 +223,12 @@ function KohaTable(id_selector, dt_parameters, table_settings, add_filters) { > titleAttr: __("Copy shareable link"), > text: '<i class="fa fa-lg fa-copy"></i> <span class="dt-button-text">' + __("Copy shareable link") + '</span>', > action: function (e, dt, node, config) { >- let table_key = 'DataTables_%s_%s_%s'.format( >+ let table_key = 'DataTables_%s_%s_%s_%s'.format( > table_settings.module, > table_settings.page, >- table_settings.table); >+ table_settings.table, >+ dt.settings()[0].nTable.id, >+ ); > > let state = JSON.stringify(dt.state()); > delete state.time; >-- >2.34.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 33484
:
149444
|
149445
|
149447
|
149448
|
149449
|
149925
|
149926
|
149927
|
149928
|
149929
|
149930
|
149974
|
149975
|
149976
|
149977
|
149978
|
149979
|
173443
|
173444
|
173445
|
173446
|
173447
|
173448
|
173449
|
173450
|
173451
|
173452
|
173453
|
173454
|
173455
|
173456
|
173457
|
173458
|
173459
|
173460
|
173461
|
173462
|
173463
|
173464
|
173465
|
173466
|
173467
|
173468
|
173469
|
173470
|
173471
|
173472
|
173473
| 173474 |
173475
|
173476
|
173477
|
173478
|
173479
|
173480
|
173481
|
173482
|
173483
|
173484
|
173485
|
173486
|
173546
|
173606
|
173607
|
173985
|
174219