From e0c9b337b4bb3739fee6486bbc9caf5f38b59255 Mon Sep 17 00:00:00 2001 From: tipaul Date: Fri, 9 Jun 2006 14:29:05 +0000 Subject: [PATCH] [IMPORTANT] 2 things in this commit - npl templates worked well for cloneSubfield, default one didn't. I couldn't understand why, so I ported npl template to default & just updated the stylesheet - npl templates were awfully indented, so I indented them a little bit - I thought for months that the idea of 10 tabs passed separately was crazy. So I fixed it : now there is just 1 (ONE) tab described in templates, that is looped by BIG_LOOP. The BIG_LOOP is filled by the build_tabs. Works the same way as previously, except there is just 1 tab described in templates !!! Things still to do : - making cloneTag work correctly - handle authorities popup, that is broken - handle authorities reporting, that is broken too. --- acqui.simple/addbiblio.pl | 15 +- .../default/en/acqui.simple/addbiblio.tmpl | 818 +++--------------- .../npl/en/acqui.simple/addbiblio.tmpl | 381 ++------ 3 files changed, 239 insertions(+), 975 deletions(-) diff --git a/acqui.simple/addbiblio.pl b/acqui.simple/addbiblio.pl index d01583e8b8..7a32a216ff 100755 --- a/acqui.simple/addbiblio.pl +++ b/acqui.simple/addbiblio.pl @@ -264,6 +264,10 @@ sub build_tabs ($$$$) { from authorised_values where category=? order by lib"); + # in this array, we will push all the 10 tabs + # to avoid having 10 tabs in the template : they will all be in the same BIG_LOOP + my @BIG_LOOP; + # loop through each tab 0 through 9 for (my $tabloop = 0; $tabloop <= 9; $tabloop++) { my @loop_data = (); @@ -368,8 +372,15 @@ sub build_tabs ($$$$) { } } } - $template->param($tabloop."XX" =>\@loop_data); + if ($#loop_data >=0) { + my %big_loop_line; + $big_loop_line{number}=$tabloop; + $big_loop_line{innerloop}=\@loop_data; + push @BIG_LOOP,\%big_loop_line; + } +# $template->param($tabloop."XX" =>\@loop_data); } + $template->param(BIG_LOOP => \@BIG_LOOP); } @@ -482,6 +493,8 @@ if ($op eq "addbiblio") { my @tags = $input->param('tag'); my @subfields = $input->param('subfield'); my @values = $input->param('field_value'); + use Data::Dumper; + warn "DUMP : ".Dumper(@values); # build indicator hash. my @ind_tag = $input->param('ind_tag'); my @indicator = $input->param('indicator'); diff --git a/koha-tmpl/intranet-tmpl/default/en/acqui.simple/addbiblio.tmpl b/koha-tmpl/intranet-tmpl/default/en/acqui.simple/addbiblio.tmpl index 3a16dc85d9..80728d82eb 100644 --- a/koha-tmpl/intranet-tmpl/default/en/acqui.simple/addbiblio.tmpl +++ b/koha-tmpl/intranet-tmpl/default/en/acqui.simple/addbiblio.tmpl @@ -1,651 +1,103 @@ +
+

Edit MARC Record Number Add MARC Record With Framework :

+
- -

Biblionumber : With Framework :

-

- - - "> - "> + + + " /> + " /> - + - - - z3950 search -

-
- -
- - 0 - - - 1 - - - 2 - - - 3 - - - 4 - - - 5 - - - 6 - - - 7 - - - 8 - - - 9 - -
- -
- -
-

Duplicate suspected with

-

You must either :

- -
- - -
"> - -

- "> - - "> - "> - - - "> - - - ')">+ -

- - - - " onclick="unHideSubfield('subfield','label')"> - - - -

- - - - - - ')">+ - - "/> - " size="2" maxlength="1"/> - "/> - "/> - "/> -

-
- -
- -
- -
- -
"> - -

- "> - - "> - "> - - - "> - - - ')">+ -

- - - - " onclick="unHideSubfield('subfield','label')"> - - - -

- - - - - - ')">+ - - "/> - " size="2" maxlength="1"/> - "/> - "/> - "/> -

-
- -
- -
- -
- -
"> - -

- "> - - "> - "> - - - "> - - - ')">+ -

- - - - " onclick="unHideSubfield('subfield','label')"> - - - -

- - - - - - ')">+ - - "/> - " size="2" maxlength="1"/> - "/> - "/> - "/> -

-
- -
- -
- -
- -
"> - -

- "> - - "> - "> - - - "> - - - ')">+ -

- - - - " onclick="unHideSubfield('subfield','label')"> - - - -

- - - - - - ')">+ - - "/> - " size="2" maxlength="1"/> - "/> - "/> - "/> -

-
- -
- - -
- -
- -
"> - -

- "> - - "> - "> - - - "> - - - ')">+ -

- - - - " onclick="unHideSubfield('subfield','label')"> - - - -

- - - - - - ')">+ - - "/> - " size="2" maxlength="1"/> - "/> - "/> - "/> -

-
- -
- - -
- -
- -
"> - -

- "> - - "> - "> - - - "> - - - ')">+ -

- - - - " onclick="unHideSubfield('subfield','label')"> - - - -

- - - - - - ')">+ - - "/> - " size="2" maxlength="1"/> - "/> - "/> - "/> -

-
- -
- - -
- -
- -
"> - -

- "> - - "> - "> - - - "> - - - ')">+ -

- - - - " onclick="unHideSubfield('subfield','label')"> - - - -

- - - - - - ')">+ - - "/> - " size="2" maxlength="1"/> - "/> - "/> - "/> -

-
- -
- - -
- -
- -
"> - -

- "> - - "> - "> - - - "> - - - ')">+ -

+ - - - " onclick="unHideSubfield('subfield','label')"> - - - -

- - - - - - ')">+ - - "/> - " size="2" maxlength="1"/> - "/> - "/> - "/> -

-
- -
- +
- - -
- -
"> - -

- "> - - "> - "> - - - "> - - - ')">+ -

- - - - " onclick="unHideSubfield('subfield','label')"> - - - -

- - - - - - ')">+ - - "/> - " size="2" maxlength="1"/> - "/> - "/> - "/> -

-
- -
- + - -
- -
"> - -

- "> - - "> - "> - - - "> - - - ')">+ -

- - - - " onclick="unHideSubfield('subfield','label')"> - - - -

- - - - - - ')">+ - - "/> - " size="2" maxlength="1"/> - "/> - "/> - "/> -

-
- -
- -
- + + + + +
XX" id="XX" class="tab" style="visibility:hidden"> + +
XX" id="XX" class="tab" style="visibility:visible"> + + + + +
+

Is this a duplicate of " onclick="openWindow('../MARCdetail.pl?bib=&popup=1', 'Duplicate biblio'; return false;)">?

+

You must either :

+ +
+ + + + +

+ "> + + "> + style="display:none;" name="indicator" size="2" maxlength="2" value="" class="flat"> - + + style="display:none;" name="indicator" value=""> + + + + + ')">+ +

+ +
+ + + " onclick="unHideSubfield('subfield','label')"> + + + +
+

+ + + + + + ')">+ + + "/> + " size="2" maxlength="1"/> + "/> + "/> + "/> +

+
+ +
+ +
+
"> @@ -670,32 +122,40 @@