From 5e1f8caf609aa58eabf6f353d12ec25e0e8e23a0 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Tue, 25 Jun 2013 12:46:04 -0400 Subject: [PATCH] Bug 10475 - Item form in acquisition not hiding subfields properly Subfields hidden in your ACQ framework leave a gap where they used to be in the item entry form when adding an item to an order. This patch makes the same change made by 7116 to services/itemrecorddisplay.tt to correct the problem. To test: - Edit your ACQ framework and set some item subfields to hidden in the editor. - Set your AcqCreateItem system preference to "when placing an order." - Add a title to an existing basket from an existing record. The item entry form should display correctly with your hidden subfields hidden. No whitespace should be left behind where the subfields were hidden. Also changed: Invalid "size" attributes on hidden form fields in neworderempty.tt, stray . Signed-off-by: Chris Cormack Signed-off-by: Katrin Fischer Works nicely, passes all tests and QA script. Thx Owen! Signed-off-by: Galen Charlton --- .../prog/en/modules/acqui/neworderempty.tt | 31 +++++++++---------- .../en/modules/services/itemrecorddisplay.tt | 8 +++-- 2 files changed, 21 insertions(+), 18 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt index 47ee2624a7..bbcd4e809d 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt @@ -241,7 +241,7 @@ $(document).ready(function()
  1. [% IF ( biblionumber ) %] Title - [% title |html %] + [% title |html %] [% ELSE %] @@ -250,7 +250,7 @@ $(document).ready(function()
  2. [% IF ( biblionumber ) %] Author: - [% author %] + [% author %] [% ELSE %] @@ -259,7 +259,7 @@ $(document).ready(function()
  3. [% IF ( biblionumber ) %] Publisher: - [% publishercode %] + [% publishercode %] [% ELSE %] @@ -268,7 +268,7 @@ $(document).ready(function()
  4. [% IF ( biblionumber ) %] Edition: - [% editionstatement %] + [% editionstatement %] [% ELSE %] @@ -278,7 +278,7 @@ $(document).ready(function()
  5. [% IF ( biblionumber ) %] Publication year: - [% publicationyear %] + [% publicationyear %] [% ELSE %] @@ -287,7 +287,7 @@ $(document).ready(function()
  6. [% IF ( biblionumber ) %] ISBN: - [% isbn %] + [% isbn %] [% ELSE %] @@ -297,7 +297,7 @@ $(document).ready(function()
  7. [% IF ( biblionumber ) %] EAN: - [% ean %] + [% ean %] [% ELSE %] @@ -307,12 +307,11 @@ $(document).ready(function()
  8. [% IF ( biblionumber ) %] Series: - [% seriestitle %] + [% seriestitle %] [% ELSE %] [% END %] -
  9. [% UNLESS ( biblionumber ) %] [% IF ( itemtypeloop ) %] @@ -394,7 +393,7 @@ $(document).ready(function()
  10. [% IF ( close ) %] Quantity: - [% quantity %] + [% quantity %] [% ELSE %] [% IF (AcqCreateItemOrdering) %] @@ -417,7 +416,7 @@ $(document).ready(function()
  11. [% IF ( close ) %] Fund: - [% Budget_name %] + [% Budget_name %] [% ELSE %] [% currency %] + [% currency %] [% ELSE %] [% listprice %] + [% listprice %] [% ELSE %] @@ -471,9 +470,9 @@ $(document).ready(function()
  12. [% IF ( close ) %] Tax rate: - [% gstrate %]% + [% gstrate %]% [% ELSE %] - + [% rrp %] + [% rrp %] [% ELSE %] (adjusted for [% cur_active %]) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/services/itemrecorddisplay.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/services/itemrecorddisplay.tt index 005a0a87cb..56372769b5 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/services/itemrecorddisplay.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/services/itemrecorddisplay.tt @@ -1,7 +1,11 @@
      [% FOREACH iteminfo IN iteminformation %] -
    1. -
      + [% IF ( iteminfo.hidden ) %] +
    2. + [% ELSE %] +
    3. + [% END %] +
      [% IF (iteminfo.mandatory) %] [% ELSE %] -- 2.20.1