[Koha-patches] [PATCH] Fix for Bug 5436 - Extended patron attributes display improvements

Owen Leonard oleonard at myacpl.org
Fri Aug 5 20:56:31 CEST 2011


From: Henri-Damien LAURENT <henridamien.laurent at biblibre.com>

Show patron attributes in the sidebar on circ and patron pages

[Edit from Owen Leonard: This patch takes changes originally in
Bug 5436 and isolates just the parts relating to display of
patron attributes. Because function for pulling patron attributes
was merged with the function for displaying address information
in SetMemberInfosInTemplate() (also found in Bug 5749), I moved
the call to GetBorrowerAttributes into the individual scripts.
That keeps the functionality relating specifically to patron
attributes separate from the proposed changes to displaying
addresses.

Because I think it's important to keep the display consistent,
I added display of patron attributes to all pages which include
the patron information sidebar.]
---
 C4/Members/AttributeTypes.pm                       |   31 +++++++++++++++++--
 C4/Members/Attributes.pm                           |    3 +-
 admin/patron-attr-types.pl                         |    9 +++++-
 circ/circulation.pl                                |    3 ++
 .../0009-patron-attr-display-checkout.pl           |    7 ++++
 installer/data/mysql/kohastructure.sql             |    1 +
 .../intranet-tmpl/prog/en/includes/circ-menu.inc   |    7 ++++
 .../prog/en/modules/admin/patron-attr-types.tt     |    7 ++++-
 members/boraccount.pl                              |    6 +++-
 members/mancredit.pl                               |    3 ++
 members/maninvoice.pl                              |    3 ++
 members/member-flags.pl                            |    5 ++-
 members/member-password.pl                         |    7 +++-
 members/messaging.pl                               |    3 ++
 members/moremember.pl                              |    3 ++
 members/notices.pl                                 |    5 ++-
 members/pay.pl                                     |    5 ++-
 members/readingrec.pl                              |    6 +++-
 18 files changed, 100 insertions(+), 14 deletions(-)
 create mode 100644 installer/data/mysql/atomicupdate/0009-patron-attr-display-checkout.pl

diff --git a/C4/Members/AttributeTypes.pm b/C4/Members/AttributeTypes.pm
index 3a05268..e36557b 100644
--- a/C4/Members/AttributeTypes.pm
+++ b/C4/Members/AttributeTypes.pm
@@ -118,6 +118,7 @@ sub new {
     $self->{'opac_display'} = 0;
     $self->{'password_allowed'} = 0;
     $self->{'staff_searchable'} = 0;
+    $self->{'display_checkout'} = 0;
     $self->{'authorised_value_category'} = '';
 
     bless $self, $class;
@@ -152,6 +153,7 @@ sub fetch {
     $self->{'opac_display'}              = $row->{'opac_display'};
     $self->{'password_allowed'}          = $row->{'password_allowed'};
     $self->{'staff_searchable'}          = $row->{'staff_searchable'};
+    $self->{'display_checkout'}          = $row->{'display_checkout'};
     $self->{'authorised_value_category'} = $row->{'authorised_value_category'};
 
     bless $self, $class;
@@ -182,14 +184,15 @@ sub store {
                                          opac_display = ?,
                                          password_allowed = ?,
                                          staff_searchable = ?,
-                                         authorised_value_category = ?
+                                         authorised_value_category = ?,
+                                         display_checkout = ?
                                      WHERE code = ?");
     } else {
         $sth = $dbh->prepare_cached("INSERT INTO borrower_attribute_types 
                                         (description, repeatable, unique_id, opac_display, password_allowed,
-                                         staff_searchable, authorised_value_category, code)
+                                         staff_searchable, authorised_value_category, display_checkout, code)
                                         VALUES (?, ?, ?, ?, ?,
-                                                ?, ?, ?)");
+                                                ?, ?, ?, ?)");
     }
     $sth->bind_param(1, $self->{'description'});
     $sth->bind_param(2, $self->{'repeatable'});
@@ -198,7 +201,8 @@ sub store {
     $sth->bind_param(5, $self->{'password_allowed'});
     $sth->bind_param(6, $self->{'staff_searchable'});
     $sth->bind_param(7, $self->{'authorised_value_category'});
-    $sth->bind_param(8, $self->{'code'});
+    $sth->bind_param(8, $self->{'display_checkout'});
+    $sth->bind_param(9, $self->{'code'});
     $sth->execute;
 
 }
@@ -304,6 +308,25 @@ sub staff_searchable {
     @_ ? $self->{'staff_searchable'} = ((shift) ? 1 : 0) : $self->{'staff_searchable'};
 }
 
+=head2 display_checkout
+
+=over 4
+
+my $display_checkout = $attr_type->display_checkout();
+$attr_type->display_checkout($display_checkout);
+
+=back
+
+Accessor.  The C<$display_checkout> argument
+is interpreted as a Perl boolean.
+
+=cut
+
+sub display_checkout {
+    my $self = shift;
+    @_ ? $self->{'display_checkout'} = ((shift) ? 1 : 0) : $self->{'display_checkout'};
+}
+
 =head2 authorised_value_category
 
   my $authorised_value_category = $attr_type->authorised_value_category();
diff --git a/C4/Members/Attributes.pm b/C4/Members/Attributes.pm
index 35d6702..29a31e6 100644
--- a/C4/Members/Attributes.pm
+++ b/C4/Members/Attributes.pm
@@ -72,7 +72,7 @@ sub GetBorrowerAttributes {
     my $opac_only = @_ ? shift : 0;
 
     my $dbh = C4::Context->dbh();
-    my $query = "SELECT code, description, attribute, lib, password
+    my $query = "SELECT code, description, attribute, lib, password, display_checkout
                  FROM borrower_attributes
                  JOIN borrower_attribute_types USING (code)
                  LEFT JOIN authorised_values ON (category = authorised_value_category AND attribute = authorised_value)
@@ -89,6 +89,7 @@ sub GetBorrowerAttributes {
             value             => $row->{'attribute'},  
             value_description => $row->{'lib'},  
             password          => $row->{'password'},
+            display_checkout  => $row->{'display_checkout'},
         }
     }
     return \@results;
diff --git a/admin/patron-attr-types.pl b/admin/patron-attr-types.pl
index 1dfe442..c32b6c2 100755
--- a/admin/patron-attr-types.pl
+++ b/admin/patron-attr-types.pl
@@ -106,6 +106,9 @@ sub error_add_attribute_type_form {
     if ($input->param('staff_searchable')) {
         $template->param(staff_searchable_checked => 'checked="checked"');
     }
+    if ($input->param('display_checkout')) {
+        $template->param(display_checkout_checked => 'checked="checked"');
+    }
 
     $template->param(
         attribute_type_form => 1,
@@ -147,6 +150,8 @@ sub add_update_attribute_type {
     $attr_type->authorised_value_category($authorised_value_category);
     my $password_allowed = $input->param('password_allowed');
     $attr_type->password_allowed($password_allowed);
+    my $display_checkout = $input->param('display_checkout');
+    $attr_type->display_checkout($display_checkout);
 
     if ($op eq 'edit') {
         $template->param(edited_attribute_type => $attr_type->code());
@@ -222,7 +227,9 @@ sub edit_attribute_type_form {
     if ($attr_type->staff_searchable()) {
         $template->param(staff_searchable_checked => 'checked="checked"');
     }
-
+    if ($attr_type->display_checkout()) {
+        $template->param(display_checkout_checked => 'checked="checked"');
+    }
     authorised_value_category_list($template, $attr_type->authorised_value_category());
 
     $template->param(
diff --git a/circ/circulation.pl b/circ/circulation.pl
index c34db54..7f70502 100755
--- a/circ/circulation.pl
+++ b/circ/circulation.pl
@@ -35,6 +35,7 @@ use C4::Biblio;
 use C4::Reserves;
 use C4::Context;
 use CGI::Session;
+use C4::Members::Attributes qw(GetBorrowerAttributes);
 
 use Date::Calc qw(
   Today
@@ -630,6 +631,7 @@ my $fast_cataloging = 0;
     if (defined getframeworkinfo('FA')) {
     $fast_cataloging = 1 
     }
+my $attributes = GetBorrowerAttributes($borrowernumber);
 
 $template->param(
     lib_messages_loop => $lib_messages_loop,
@@ -679,6 +681,7 @@ $template->param(
     circview => 1,
     soundon           => C4::Context->preference("SoundOn"),
     fast_cataloging   => $fast_cataloging,
+    extendedattributes => $attributes,
 );
 
 # save stickyduedate to session
diff --git a/installer/data/mysql/atomicupdate/0009-patron-attr-display-checkout.pl b/installer/data/mysql/atomicupdate/0009-patron-attr-display-checkout.pl
new file mode 100644
index 0000000..44cfcfa
--- /dev/null
+++ b/installer/data/mysql/atomicupdate/0009-patron-attr-display-checkout.pl
@@ -0,0 +1,7 @@
+#! /usr/bin/perl
+use strict;
+use warnings;
+use C4::Context;
+my $dbh=C4::Context->dbh;
+$dbh->do("ALTER TABLE borrower_attribute_types ADD COLUMN `display_checkout` TINYINT(1) NOT NULL DEFAULT '0';");
+print "Upgrade done (Added a display_checkout field in borrower_attribute_types table)\n";
diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql
index e9edf25..c23b1f6 100644
--- a/installer/data/mysql/kohastructure.sql
+++ b/installer/data/mysql/kohastructure.sql
@@ -284,6 +284,7 @@ CREATE TABLE `borrower_attribute_types` (
   `password_allowed` tinyint(1) NOT NULL default 0,
   `staff_searchable` tinyint(1) NOT NULL default 0,
   `authorised_value_category` varchar(10) default NULL,
+  `display_checkout` tinyint(1) NOT NULL default 0,
   PRIMARY KEY  (`code`),
   KEY `auth_val_cat_idx` (`authorised_value_category`)
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/circ-menu.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/circ-menu.inc
index 129bd66..65cfebf 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/includes/circ-menu.inc
+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/circ-menu.inc
@@ -48,6 +48,13 @@
             <li> <span class="empty">No email stored.</span>    </li>
         [% END %]
     [% END %]
+    [% FOREACH extendedattribute IN extendedattributes %]
+        [% IF ( extendedattribute.display_checkout ) %]
+            [% IF ( extendedattribute.value ) %]
+                <li>[% extendedattribute.description %] : [% IF ( extendedattribute.value_description ) %][% extendedattribute.value_description %][% ELSE %][% extendedattribute.value %][% END %]</li>
+            [% END %]
+        [% END %]
+    [% END %]
     <li>Category: [% categoryname %] ([% categorycode %])</li>
     <li>Home Library: [% IF ( branchname ) %][% branchname %][% ELSE %][% branch %][% END %]</li>
 </ul></div>
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/patron-attr-types.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/patron-attr-types.tt
index 105d268..7718ef2 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/patron-attr-types.tt
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/patron-attr-types.tt
@@ -68,7 +68,7 @@ function CheckAttributeTypeForm(f) {
     <div class="yui-b">
 
 [% IF ( WARNING_extended_attributes_off ) %]
-<div class="dialog message">Because the 'ExtendedPatronAttributes` system preference is currently not enabled, extended patron attributes cannot be given to patron records.  Go <a href="/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=ExtendedPatronAttributes">here</a> if you wish to enable this feature.</div>
+<div class="dialog message">Because the 'ExtendedPatronAttributes` system preference is currently not enabled, extended patron attributes cannot be given to patron records.  Go <a href="/cgi-bin/koha/admin/preferences.pl?op=search&amp;searchfield=ExtendedPatronAttributes">here</a> if you wish to enable this feature.</div>
 [% END %]
 
 [% IF ( attribute_type_form ) %]
@@ -122,6 +122,11 @@ function CheckAttributeTypeForm(f) {
             <input type="checkbox" id="staff_searchable" name="staff_searchable" [% staff_searchable_checked %] />
             <span>Check to make this attribute staff_searchable in the staff patron search.</span>
        </li>
+       <li><label for="display_checkout">Display in check-out: </label>
+            <input type="checkbox" id="display_checkout" name="display_checkout" [% display_checkout_checked %] />
+            <span>Check to show this attribute in patron check-out.</span>
+       </li>
+
         <li><label for="authorised_value_category">Authorized value category: </label>
             <select name="authorised_value_category" id="authorised_value_category">
                 <option value=""></option>
diff --git a/members/boraccount.pl b/members/boraccount.pl
index b91684a..d812259 100755
--- a/members/boraccount.pl
+++ b/members/boraccount.pl
@@ -32,6 +32,7 @@ use CGI;
 use C4::Members;
 use C4::Branch;
 use C4::Accounts;
+use C4::Members::Attributes qw(GetBorrowerAttributes);
 
 my $input=new CGI;
 
@@ -96,6 +97,7 @@ $template->param( adultborrower => 1 ) if ( $data->{'category_type'} eq 'A' );
 
 my ($picture, $dberror) = GetPatronImage($data->{'cardnumber'});
 $template->param( picture => 1 ) if $picture;
+my $attributes = GetBorrowerAttributes($borrowernumber);
 
 $template->param(
     finesview           => 1,
@@ -120,6 +122,8 @@ $template->param(
     totalcredit         => $totalcredit,
     is_child            => ($data->{'category_type'} eq 'C'),
     reverse_col         => $reverse_col,
-    accounts            => $accts );
+    accounts            => $accts,
+    extendedattributes => $attributes,
+);
 
 output_html_with_http_headers $input, $cookie, $template->output;
diff --git a/members/mancredit.pl b/members/mancredit.pl
index ae41b57..801fcc2 100755
--- a/members/mancredit.pl
+++ b/members/mancredit.pl
@@ -33,6 +33,7 @@ use C4::Members;
 use C4::Branch;
 use C4::Accounts;
 use C4::Items;
+use C4::Members::Attributes qw(GetBorrowerAttributes);
 
 my $input=new CGI;
 
@@ -77,6 +78,7 @@ if ($add){
     $template->param( adultborrower => 1 ) if ( $data->{category_type} eq 'A' );
     my ($picture, $dberror) = GetPatronImage($data->{'cardnumber'});
     $template->param( picture => 1 ) if $picture;
+    my $attributes = GetBorrowerAttributes($borrowernumber);
     
     $template->param(
         borrowernumber => $borrowernumber,
@@ -97,6 +99,7 @@ if ($add){
 		    branchcode => $data->{'branchcode'},
 		    branchname => GetBranchName($data->{'branchcode'}),
 		    is_child        => ($data->{'category_type'} eq 'C'),
+            extendedattributes => $attributes,
         );
     output_html_with_http_headers $input, $cookie, $template->output;
 }
diff --git a/members/maninvoice.pl b/members/maninvoice.pl
index 9e8d429..9a040b6 100755
--- a/members/maninvoice.pl
+++ b/members/maninvoice.pl
@@ -32,6 +32,7 @@ use C4::Members;
 use C4::Accounts;
 use C4::Items;
 use C4::Branch;
+use C4::Members::Attributes qw(GetBorrowerAttributes);
 
 my $input=new CGI;
 
@@ -105,6 +106,7 @@ if ($add){
     $template->param( adultborrower => 1 ) if ( $data->{'category_type'} eq 'A' );
     my ($picture, $dberror) = GetPatronImage($data->{'cardnumber'});
     $template->param( picture => 1 ) if $picture;
+    my $attributes = GetBorrowerAttributes($borrowernumber);
 
 	$template->param(
                 borrowernumber => $borrowernumber,
@@ -125,6 +127,7 @@ if ($add){
 		branchcode => $data->{'branchcode'},
 		branchname => GetBranchName($data->{'branchcode'}),
 		is_child        => ($data->{'category_type'} eq 'C'),
+        extendedattributes => $attributes,
     );
     output_html_with_http_headers $input, $cookie, $template->output;
 }
diff --git a/members/member-flags.pl b/members/member-flags.pl
index 007b56c..00a3268 100755
--- a/members/member-flags.pl
+++ b/members/member-flags.pl
@@ -13,6 +13,7 @@ use C4::Auth qw(:DEFAULT :EditPermissions);
 use C4::Context;
 use C4::Members;
 use C4::Branch;
+use C4::Members::Attributes qw(GetBorrowerAttributes);
 #use C4::Acquisitions;
 
 use C4::Output;
@@ -161,7 +162,8 @@ if ($input->param('newflags')) {
 $template->param( adultborrower => 1 ) if ( $bor->{'category_type'} eq 'A' );
     my ($picture, $dberror) = GetPatronImage($bor->{'cardnumber'});
     $template->param( picture => 1 ) if $picture;
-		
+my $attributes = GetBorrowerAttributes($bor->{'borrowernumber'});
+
 $template->param(
 		borrowernumber => $bor->{'borrowernumber'},
     cardnumber => $bor->{'cardnumber'},
@@ -182,6 +184,7 @@ $template->param(
 		branchname => GetBranchName($bor->{'branchcode'}),
 		loop => \@loop,
 		is_child        => ($bor->{'category_type'} eq 'C'),
+        extendedattributes => $attributes,
 		);
 
     output_html_with_http_headers $input, $cookie, $template->output;
diff --git a/members/member-password.pl b/members/member-password.pl
index 0fefe4f..03f5243 100755
--- a/members/member-password.pl
+++ b/members/member-password.pl
@@ -14,6 +14,7 @@ use C4::Members;
 use C4::Branch;
 use C4::Circulation;
 use CGI;
+use C4::Members::Attributes qw(GetBorrowerAttributes);
 
 use Digest::MD5 qw(md5_base64);
 
@@ -89,7 +90,8 @@ if ( $newpassword  && ! $errormsg ) {
 $template->param( adultborrower => 1 ) if ( $bor->{'category_type'} eq 'A' );
 my ($picture, $dberror) = GetPatronImage($bor->{'cardnumber'});
 $template->param( picture => 1 ) if $picture;
-	
+my $attributes = GetBorrowerAttributes($bor->{'borrowernumber'});
+
     $template->param( othernames => $bor->{'othernames'},
 	    surname     => $bor->{'surname'},
 	    firstname   => $bor->{'firstname'},
@@ -111,7 +113,8 @@ $template->param( picture => 1 ) if $picture;
 	    userid      => $bor->{'userid'},
 	    destination => $destination,
 		is_child        => ($bor->{'category_type'} eq 'C'),
-	    defaultnewpassword => $defaultnewpassword 
+	    defaultnewpassword => $defaultnewpassword,
+    	extendedattributes => $attributes,
 	);
 
 
diff --git a/members/messaging.pl b/members/messaging.pl
index 8791dcf..21435de 100755
--- a/members/messaging.pl
+++ b/members/messaging.pl
@@ -35,6 +35,7 @@ use C4::Letters;
 use C4::Biblio;
 use C4::Reserves;
 use C4::Branch; # GetBranchName
+use C4::Members::Attributes qw(GetBorrowerAttributes);
 
 use Data::Dumper;
 
@@ -79,6 +80,7 @@ $template->param( picture => 1 ) if $picture;
 
 # get some recent messages sent to this borrower for display:
 my $message_queue = C4::Letters::GetQueuedMessages( { borrowernumber => $query->param('borrowernumber') } );
+my $attributes = GetBorrowerAttributes($borrowernumber);
 
 $template->param( messagingview               => 1,
                   message_queue               => $message_queue,
@@ -88,6 +90,7 @@ $template->param( messagingview               => 1,
                   dateformat                  => C4::Context->preference("dateformat"),
                   categoryname                => $borrower->{'description'},
                   $borrower->{'categorycode'} => 1,
+                  extendedattributes => $attributes,
 );
 
 #$messaging_preferences->{'SMSnumber'}{'value'} = defined $borrower->{'smsalertnumber'}
diff --git a/members/moremember.pl b/members/moremember.pl
index 9292fd0..2f40242 100755
--- a/members/moremember.pl
+++ b/members/moremember.pl
@@ -52,6 +52,7 @@ use C4::Branch; # GetBranchName
 use C4::Form::MessagingPreferences;
 use C4::NewsChannels; #get slip news
 use List::MoreUtils qw/uniq/;
+use C4::Members::Attributes qw(GetBorrowerAttributes);
 
 #use Smart::Comments;
 #use Data::Dumper;
@@ -438,6 +439,7 @@ if (C4::Context->preference('EnhancedMessagingPreferences')) {
     $template->param(SMSSendDriver => C4::Context->preference("SMSSendDriver"));
     $template->param(SMSnumber     => defined $data->{'smsalertnumber'} ? $data->{'smsalertnumber'} : $data->{'mobile'});
 }
+my $attributes = GetBorrowerAttributes($borrowernumber);
 
 $template->param(
     detailview => 1,
@@ -467,6 +469,7 @@ $template->param(
     "dateformat_" . (C4::Context->preference("dateformat") || '') => 1,
     samebranch     => $samebranch,
     quickslip		  => $quickslip,
+    extendedattributes => $attributes,
 );
 
 #Get the slip news items
diff --git a/members/notices.pl b/members/notices.pl
index 088d5a8..e0db209 100755
--- a/members/notices.pl
+++ b/members/notices.pl
@@ -27,6 +27,7 @@ use CGI;
 use C4::Members;
 use C4::Branch;
 use C4::Letters;
+use C4::Members::Attributes qw(GetBorrowerAttributes);
 
 use C4::Dates qw/format_date/;
 my $input=new CGI;
@@ -52,11 +53,13 @@ $template->param( picture => 1 ) if $picture;
 # Getting the messages
 my $queued_messages = C4::Letters::GetQueuedMessages({borrowernumber => $borrowernumber});
 $template->param( %{$borrower} );
+my $attributes = GetBorrowerAttributes($borrowernumber);
 
 $template->param(
 			QUEUED_MESSAGES 	=> $queued_messages,
 			borrowernumber 		=> $borrowernumber,
-			sentnotices 		=> 1
+			sentnotices 		=> 1,
+		    extendedattributes => $attributes,
 		);
 output_html_with_http_headers $input, $cookie, $template->output;
 
diff --git a/members/pay.pl b/members/pay.pl
index 4ecdcc9..6d88cf4 100755
--- a/members/pay.pl
+++ b/members/pay.pl
@@ -39,6 +39,7 @@ use C4::Stats;
 use C4::Koha;
 use C4::Overdues;
 use C4::Branch; # GetBranches
+use C4::Members::Attributes qw(GetBorrowerAttributes);
 
 my $input = new CGI;
 
@@ -152,6 +153,7 @@ if ( $data->{'category_type'} eq 'C') {
 $template->param( adultborrower => 1 ) if ( $data->{'category_type'} eq 'A' );
 my ($picture, $dberror) = GetPatronImage($data->{'cardnumber'});
 $template->param( picture => 1 ) if $picture;
+my $attributes = GetBorrowerAttributes($borrowernumber);
 	
     $template->param(
         allfile        => \@allfile,
@@ -173,7 +175,8 @@ $template->param( picture => 1 ) if $picture;
 	branchcode => $data->{'branchcode'},
 	branchname => GetBranchName($data->{'branchcode'}),
 	is_child        => ($data->{'category_type'} eq 'C'),
-        total          => sprintf( "%.2f", $total )
+        total          => sprintf( "%.2f", $total ),
+    extendedattributes => $attributes,
     );
     output_html_with_http_headers $input, $cookie, $template->output;
 
diff --git a/members/readingrec.pl b/members/readingrec.pl
index e7586a0..04414e3 100755
--- a/members/readingrec.pl
+++ b/members/readingrec.pl
@@ -32,6 +32,7 @@ use C4::Branch;
 use List::MoreUtils qw/any/;
 
 use C4::Dates qw/format_date/;
+use C4::Members::Attributes qw(GetBorrowerAttributes);
 
 my $input = CGI->new;
 
@@ -95,6 +96,7 @@ if (! $limit){
 
 my ($picture, $dberror) = GetPatronImage($data->{'cardnumber'});
 $template->param( picture => 1 ) if $picture;
+my $attributes = GetBorrowerAttributes($borrowernumber);
 
 $template->param(
 						readingrecordview => 1,
@@ -122,7 +124,9 @@ $template->param(
 			   			is_child        => ($data->{'category_type'} eq 'C'),
 			   			branchname => GetBranchName($data->{'branchcode'}),
 						showfulllink => (scalar @loop_reading > 50),					
-						loop_reading => \@loop_reading);
+						loop_reading => \@loop_reading,
+					    extendedattributes => $attributes,
+);
 output_html_with_http_headers $input, $cookie, $template->output;
 
 
-- 
1.7.3



More information about the Koha-patches mailing list