From 383ecea0b2b3095b8a758a7a424aed7309dca273 Mon Sep 17 00:00:00 2001 From: Alex Buckley Date: Wed, 8 Aug 2018 15:31:08 +1200 Subject: [PATCH] Bug 21173 - Fixed 2 template and SQL typos --- C4/Items.pm | 6 +++--- .../prog/en/modules/tools/automatic_item_modification_by_age.tt | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/C4/Items.pm b/C4/Items.pm index 64a6b86..b867e5e 100644 --- a/C4/Items.pm +++ b/C4/Items.pm @@ -2839,15 +2839,15 @@ sub ToggleNewStatus { if ( defined $age ) { # Calculate item age based on hours since item last altered if ( defined $rule && defined $age_starting_point && $unit eq "hours" && $age_starting_point eq "itemaltered" ) { - $query .= q| AND HOUR(TIMEDIFF(NOW(), timestamp)) >= ? |; + $query .= q| AND HOUR(TIMEDIFF(NOW(), items.timestamp)) >= ? |; push @params, $age; } elsif ( defined $rule && defined $age_starting_point && $unit eq "days" && $age_starting_point eq "itemaltered" ) { # Calculate item age based on days since item last altered - $query .= q| AND TO_DAYS(NOW()) - TO_DAYS(timestamp) >= ? |; + $query .= q| AND TO_DAYS(NOW()) - TO_DAYS(items.timestamp) >= ? |; push @params, $age; } else { # Calculate item age based on days since item was created - $query .= q| AND TO_DAYS(NOW()) - TO_DAYS(dateaccessioned) >= ? |; + $query .= q| AND TO_DAYS(NOW()) - TO_DAYS(items.dateaccessioned) >= ? |; push @params, $age; } } diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/automatic_item_modification_by_age.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/automatic_item_modification_by_age.tt index 44cf3b1..cb4a5f7 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/automatic_item_modification_by_age.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/automatic_item_modification_by_age.tt @@ -163,7 +163,7 @@
Unit
-

Note: If the unit of 'Hours' is set then you cannot choose an age starting point, the item age starting point wil default to the last item alteration event. The Age starting point selection will be hidden if you have set the unit to 'Hours'.

+

Note: If the unit of 'Hours' is set then you cannot choose an age starting point, the item age starting point will default to the last item alteration event. The Age starting point selection will be hidden if you have set the unit to 'Hours'.