Bugzilla – Attachment 117389 Details for
Bug 27680
API DataTables Wrapper fails for ordering on multi-data-field columns
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 27680: Take first order column for ordering
Bug-27680-Take-first-order-column-for-ordering.patch (text/plain), 1.28 KB, created by
Tomás Cohen Arazi (tcohen)
on 2021-02-26 18:09:25 UTC
(
hide
)
Description:
Bug 27680: Take first order column for ordering
Filename:
MIME Type:
Creator:
Tomás Cohen Arazi (tcohen)
Created:
2021-02-26 18:09:25 UTC
Size:
1.28 KB
patch
obsolete
>From 517cae6e795d84b8194ee48ecfe5c68490f3ff27 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Fri, 12 Feb 2021 10:53:27 +0100 >Subject: [PATCH] Bug 27680: Take first order column for ordering > >Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> >--- > koha-tmpl/intranet-tmpl/prog/js/datatables.js | 1 + > 1 file changed, 1 insertion(+) > >diff --git a/koha-tmpl/intranet-tmpl/prog/js/datatables.js b/koha-tmpl/intranet-tmpl/prog/js/datatables.js >index da01ac8ba03..7d64b907d5c 100644 >--- a/koha-tmpl/intranet-tmpl/prog/js/datatables.js >+++ b/koha-tmpl/intranet-tmpl/prog/js/datatables.js >@@ -637,6 +637,7 @@ jQuery.fn.dataTable.ext.errMode = function(settings, note, message) { > order.forEach(function (e,i) { > var order_col = e.column; > var order_by = options.columns[order_col].data; >+ order_by = order_by.split(':')[0]; > var order_dir = e.dir == 'asc' ? '+' : '-'; > dataSet._order_by = order_dir + (!order_by.includes('.')?'me.'+order_by:order_by); > }); >-- >2.30.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 27680
:
116794
|
116795
|
116796
|
116829
|
116831
|
116832
|
116833
|
116834
|
116843
|
116844
|
116845
|
116846
|
117335
|
117336
|
117337
|
117338
|
117339
|
117340
|
117341
|
117375
|
117388
|
117389
|
117390
|
117391
|
117392
|
117393
|
117394
|
117438
|
117439
|
117440
|
117441
|
117442
|
117476