From c60fecc92f003bac0b7d6f0a087ed9fc947173f3 Mon Sep 17 00:00:00 2001 From: Mason James Date: Fri, 23 Jan 2015 06:44:44 +1300 Subject: [PATCH] Reverting back to 'v3.16.06' tag, 1c30985 --- .../prog/en/css/staff-global.css | 6 -- .../intranet-tmpl/prog/en/js/checkouts.js | 71 +++++-------------- koha-tmpl/intranet-tmpl/prog/en/js/holds.js | 2 +- .../prog/en/modules/circ/circulation.tt | 1 - svc/checkouts | 31 +++----- 5 files changed, 28 insertions(+), 83 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css b/koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css index 5b091c742f..f7678f0804 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css +++ b/koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css @@ -283,12 +283,6 @@ tr.warn td { background-color: #FF9090; } -tr.ok td, -tr.ok:nth-child(odd) td, -tr.ok:nth-child(even) td { - background-color: #FFFFCC; -} - tr.onissue td { background-color: #FFFFCC; } diff --git a/koha-tmpl/intranet-tmpl/prog/en/js/checkouts.js b/koha-tmpl/intranet-tmpl/prog/en/js/checkouts.js index 9c5e4b699e..1755d6cdf4 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/js/checkouts.js +++ b/koha-tmpl/intranet-tmpl/prog/en/js/checkouts.js @@ -63,11 +63,8 @@ $(document).ready(function() { content = ""; if ( data.returned ) { content = CIRCULATION_RETURNED; - $(id).parent().parent().addClass('ok'); - $('#date_due_' + data.itemnumber).html(_("Returned")); } else { content = CIRCULATION_NOT_RETURNED; - $(id).parent().parent().addClass('warn'); } $(id).replaceWith( content ); @@ -95,7 +92,6 @@ $(document).ready(function() { var content = ""; if ( data.renew_okay ) { content = CIRCULATION_RENEWED_DUE + " " + data.date_due; - $('#date_due_' + data.itemnumber).replaceWith( data.date_due ); } else { content = CIRCULATION_RENEW_FAILED + " "; if ( data.error == "no_checkout" ) { @@ -115,11 +111,6 @@ $(document).ready(function() { }, "json") }); - // Refocus on barcode field if it exists - if ( $("#barcode").length ) { - $("#barcode").focus(); - } - // Prevent form submit return false; }); @@ -139,17 +130,17 @@ $(document).ready(function() { var drawn = 0; issuesTable = $("#issues-table").dataTable({ "oLanguage": { - "sProcessing": MSG_DT_LOADING_RECORDS, + "sEmptyTable" : MSG_DT_LOADING_RECORDS, }, "bAutoWidth": false, - "sDom": "rt", + "sDom": "<'row-fluid'<'span6'><'span6'>r>t<'row-fluid'>t", "aoColumns": [ { "mDataProp": function( oObj ) { if ( oObj.issued_today ) { - return "1" + oObj.timestamp; + return "0"; } else { - return "0" + oObj.date_due; + return "100"; } } }, @@ -169,23 +160,10 @@ $(document).ready(function() { { "iDataSort": 1, // Sort on hidden unformatted date due column "mDataProp": function( oObj ) { - var due = oObj.date_due_formatted; - - if ( oObj.date_due_overdue ) { - due = "" + due + ""; - } - - if ( oObj.lost ) { - due += "" + oObj.lost + ""; - } - - if ( oObj.damaged ) { - due += "" + oObj.damaged + ""; - } - - due = "" + due + ""; - - return due; + if ( oObj.date_due_overdue ) { + return "" + oObj.date_due_formatted + ""; + } else { + return oObj.date_due_formatted; } } }, @@ -228,7 +206,7 @@ $(document).ready(function() { return title; } }, - { "mDataProp": "itemtype_description" }, + { "mDataProp": "itemtype" }, { "mDataProp": "issuedate_formatted" }, { "mDataProp": "branchname" }, { "mDataProp": "itemcallnumber" }, @@ -257,7 +235,7 @@ $(document).ready(function() { if ( oObj.can_renew ) { // Do nothing } else if ( oObj.can_renew_error == "on_reserve" ) { - content += "" + content += "" + "" + ON_HOLD + "" + ""; @@ -290,28 +268,17 @@ $(document).ready(function() { + "" + ""; - var can_force_renew = ( oObj.onsite_checkout == 0 ) && ( oObj.can_renew_error != "on_reserve" ); - var can_renew = ( oObj.renewals_remaining > 0 && !oObj.can_renew_error ); - if ( oObj.onsite_checkout == 0 ) { - if ( can_renew || can_force_renew ) { - content += "" - + "" - + ""; + if ( oObj.renewals_remaining ) { + content += "(" + + RENEWALS_REMAINING.format( oObj.renewals_remaining, oObj.renewals_allowed ) + + ")"; + } - content += "(" - + RENEWALS_REMAINING.format( oObj.renewals_remaining, oObj.renewals_allowed ) - + ")"; - } - } + content += ""; - content += ""; - return content; - } + return content; + } }, { "bSortable": false, @@ -388,7 +355,7 @@ $(document).ready(function() { if ( ! relativesIssuesTable ) { relativesIssuesTable = $("#relatives-issues-table").dataTable({ "bAutoWidth": false, - "sDom": "rt", + "sDom": "<'row-fluid'<'span6'><'span6'>r>t<'row-fluid'>t", "aaSorting": [], "aoColumns": [ { diff --git a/koha-tmpl/intranet-tmpl/prog/en/js/holds.js b/koha-tmpl/intranet-tmpl/prog/en/js/holds.js index 253f3396f6..73807ea9d1 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/js/holds.js +++ b/koha-tmpl/intranet-tmpl/prog/en/js/holds.js @@ -5,7 +5,7 @@ $(document).ready(function() { if ( ! holdsTable ) { holdsTable = $("#holds-table").dataTable({ "bAutoWidth": false, - "sDom": "rt", + "sDom": "<'row-fluid'<'span6'><'span6'>r>t<'row-fluid'>t", "aoColumns": [ { "mDataProp": "reservedate_formatted" diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt index b2529850f4..c3b1875053 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt @@ -27,7 +27,6 @@