Bugzilla – Attachment 38373 Details for
Bug 13887
Add datatables to item specific holds table
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[PASSED QA] [PASSED QA] Bug 13887: Display the due date as a due date + sort on info
PASSED-QA-PASSED-QA-Bug-13887-Display-the-due-date.patch (text/plain), 4.14 KB, created by
Katrin Fischer
on 2015-04-22 20:32:50 UTC
(
hide
)
Description:
[PASSED QA] [PASSED QA] Bug 13887: Display the due date as a due date + sort on info
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2015-04-22 20:32:50 UTC
Size:
4.14 KB
patch
obsolete
>From ffdb773bddafbb69826d541bcb6810dfa3e445ed Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@biblibre.com> >Date: Wed, 22 Apr 2015 10:47:15 +0200 >Subject: [PATCH] [PASSED QA] [PASSED QA] Bug 13887: Display the due date as a > due date + sort on info > >The due dates should be displayed as due dates :) >i.e not displayed with 23:59 > >On the way, this patch fixes the sort on the info column. >The column is now sorted using the due dates > >Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> >Signed-off-by: Nick Clemens <nick@quecheelibrary.org> > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> >--- > C4/Circulation.pm | 2 ++ > .../prog/en/modules/reserve/request.tt | 21 +++++++++++++-------- > reserve/request.pl | 2 +- > 3 files changed, 16 insertions(+), 9 deletions(-) > >diff --git a/C4/Circulation.pm b/C4/Circulation.pm >index dd23734..d6153bf 100644 >--- a/C4/Circulation.pm >+++ b/C4/Circulation.pm >@@ -2402,6 +2402,8 @@ sub GetItemIssue { > $sth->execute($itemnumber); > my $data = $sth->fetchrow_hashref; > return unless $data; >+ $data->{issuedate_sql} = $data->{issuedate}; >+ $data->{date_due_sql} = $data->{date_due}; > $data->{issuedate} = dt_from_string($data->{issuedate}, 'sql'); > $data->{issuedate}->truncate(to => 'minute'); > $data->{date_due} = dt_from_string($data->{date_due}, 'sql'); >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt >index f072fb9..80be359 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt >@@ -45,6 +45,9 @@ $(document).ready(function() { > var my_table = $("#requestspecific").dataTable($.extend(true, {}, dataTablesDefaults, { > 'bPaginate': false, > "sDom": '<"top pager"ilf>t', >+ "aoColumnDefs": [ >+ { "sType": "title-string", "aTargets" : [ "title-string" ] } >+ ] > })); > > //Override fieldset styling for dataTables search box >@@ -456,7 +459,7 @@ function checkMultiHold() { > [% IF itemdata_enumchron %] > <th>Vol no.</th> > [% END %] >- <th>Information</th> >+ <th class="title-string">Information</th> > </tr> > </thead> > <tbody> >@@ -504,14 +507,16 @@ function checkMultiHold() { > </td> > [% END %] > <td> >- [% IF ( itemloo.onloan ) %] >- <span class="checkedout">Due [% itemloo.date_due %]</span> >+ [% IF ( itemloo.onloan ) %] >+ <span title="[% itemloo.date_due %]" class="checkedout">Due [% itemloo.date_due | $KohaDates as_due_date => 1 %]</span> > [% ELSE %] >- [% IF ( itemloo.transfertwhen ) %] >- In transit from [% itemloo.transfertfrom %], >- to [% itemloo.transfertto %], since [% itemloo.transfertwhen %] >- [% END %] >- [% END %] >+ <span title="0000-00-00"> >+ [% IF ( itemloo.transfertwhen ) %] >+ In transit from [% itemloo.transfertfrom %], >+ to [% itemloo.transfertto %], since [% itemloo.transfertwhen %] >+ [% END %] >+ </span> >+ [% END %] > > [% IF ( itemloo.message ) %] > Unavailable (lost or missing) >diff --git a/reserve/request.pl b/reserve/request.pl >index d849a48..c30fb21 100755 >--- a/reserve/request.pl >+++ b/reserve/request.pl >@@ -347,7 +347,7 @@ foreach my $biblionumber (@biblionumbers) { > # change the background color > my $issues= GetItemIssue($itemnumber); > if ( $issues->{'date_due'} ) { >- $item->{date_due} = format_sqldatetime($issues->{date_due}); >+ $item->{date_due} = $issues->{date_due_sql}; > $item->{backgroundcolor} = 'onloan'; > } > >-- >1.9.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 13887
:
37081
|
37345
|
37385
|
37388
|
37411
|
38294
|
38295
|
38309
|
38310
|
38311
|
38312
|
38313
|
38321
|
38322
|
38323
|
38369
|
38370
|
38371
|
38372
|
38373
|
38374