Bug 12778 - Regression: Item lost status doesn't show in list of checkouts
When using the longoverdue script it's possible that items marked lost remain on the patron account. I think it's important for staff to see that some items are marked lost - currently the list of checkouts doesn't show any sign of the lost status. Test Plan: 1) Find a patron with a checked out lost item 2) Note the lost status is not displayed in the checkouts table 3) Apply this patch 4) Refresh the page, note the lost status now displays 5) Repeat this test plan for a damaged item Signed-off-by: Owen Leonard <oleonard@myacpl.org> Tested successfully with damaged and multiple lost values. Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Works as described, no problems found. Signed-off-by: Mason James <mtj@kohaaloha.com>
This commit is contained in:
parent
f8432bb26d
commit
9f0326bcb2
|
|
@ -151,19 +151,29 @@ $(document).ready(function() {
|
|||
} else {
|
||||
return "<strong>" + PREVIOUS_CHECKOUTS + "</strong>";
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"mDataProp": "date_due",
|
||||
"bVisible": false,
|
||||
},
|
||||
{
|
||||
"iDataSort": 1, // Sort on hidden unformatted date due column
|
||||
"mDataProp": function( oObj ) {
|
||||
if ( oObj.date_due_overdue ) {
|
||||
return "<span class='overdue'>" + oObj.date_due_formatted + "</span>";
|
||||
} else {
|
||||
return oObj.date_due_formatted;
|
||||
},
|
||||
{
|
||||
"mDataProp": "date_due",
|
||||
"bVisible": false,
|
||||
},
|
||||
{
|
||||
"iDataSort": 1, // Sort on hidden unformatted date due column
|
||||
"mDataProp": function( oObj ) {
|
||||
var due = oObj.date_due_formatted;
|
||||
|
||||
if ( oObj.date_due_overdue ) {
|
||||
due = "<span class='overdue'>" + due + "</span>";
|
||||
}
|
||||
|
||||
if ( oObj.lost ) {
|
||||
due += "<span class='lost'>" + oObj.lost + "</span>";
|
||||
}
|
||||
|
||||
if ( oObj.damaged ) {
|
||||
due += "<span class='dmg'>" + oObj.damaged + "</span>";
|
||||
}
|
||||
|
||||
return due;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
|
|
|||
|
|
@ -25,8 +25,8 @@ use JSON qw(to_json);
|
|||
|
||||
use C4::Auth qw(check_cookie_auth);
|
||||
use C4::Biblio qw(GetMarcBiblio GetFrameworkCode GetRecordValue );
|
||||
use C4::Circulation
|
||||
qw(GetIssuingCharges CanBookBeRenewed GetRenewCount GetSoonestRenewDate);
|
||||
use C4::Circulation qw(GetIssuingCharges CanBookBeRenewed GetRenewCount GetSoonestRenewDate);
|
||||
use C4::Koha qw(GetAuthorisedValueByCode);
|
||||
use C4::Context;
|
||||
|
||||
use Koha::DateUtils;
|
||||
|
|
@ -83,6 +83,9 @@ my $sql = '
|
|||
firstname,
|
||||
cardnumber,
|
||||
|
||||
itemlost,
|
||||
damaged,
|
||||
|
||||
DATEDIFF( issuedate, CURRENT_DATE() ) AS not_issued_today
|
||||
FROM issues
|
||||
LEFT JOIN items USING ( itemnumber )
|
||||
|
|
@ -170,6 +173,8 @@ while ( my $c = $sth->fetchrow_hashref() ) {
|
|||
GetMarcBiblio( $c->{biblionumber} ),
|
||||
GetFrameworkCode( $c->{biblionumber} )
|
||||
),
|
||||
lost => $c->{itemlost} ? GetAuthorisedValueByCode( 'LOST', $c->{itemlost} ) : undef,
|
||||
damaged => $c->{damaged} ? GetAuthorisedValueByCode( 'DAMAGED', $c->{damaged} ) : undef,
|
||||
borrower => {
|
||||
surname => $c->{surname},
|
||||
firstname => $c->{firstname},
|
||||
|
|
|
|||
Loading…
Reference in New Issue