diff --git a/admin/columns_settings.yml b/admin/columns_settings.yml index 8c5edc210c..a06bbfbd9c 100644 --- a/admin/columns_settings.yml +++ b/admin/columns_settings.yml @@ -2649,6 +2649,8 @@ modules: columnname: batch_patron_edit_surname - columnname: batch_patron_edit_firstname + - + columnname: batch_patron_edit_sex - columnname: batch_patron_edit_branchcode - diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt index 07999fc2b5..8a7c87fdc0 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt @@ -221,6 +221,7 @@ Card number Surname First name + Gender Library Patron category Street number @@ -257,6 +258,15 @@ [% borrower.cardnumber | html %] [% borrower.surname | html %] [% borrower.firstname | html %] + + [% IF borrower.sex == 'F' %] + Female + [% ELSIF borrower.sex == 'M' %] + Male + [% ELSIF borrower.sex == 'O' %] + Other + [% END %] + [% Branches.GetName( borrower.branchcode ) | html %] [% Categories.GetName(borrower.categorycode) | html %] [% borrower.streetnumber | html %] @@ -345,6 +355,8 @@ Surname: [% CASE 'firstname' %] First name: + [% CASE 'sex' %] + Gender: [% CASE 'branchcode' %] Library: [% CASE 'categorycode' %] diff --git a/tools/modborrowers.pl b/tools/modborrowers.pl index b09a41d343..04323caa30 100755 --- a/tools/modborrowers.pl +++ b/tools/modborrowers.pl @@ -222,6 +222,17 @@ if ( $op eq 'cud-show' || $op eq 'show' ) { type => "text", mandatory => ( grep /firstname/, @mandatoryFields ) ? 1 : 0, }, + { + name => "sex", + type => "select", + option => [ + { value => "", lib => "" }, + { value => "F", lib => "Female" }, + { value => "M", lib => "Male" }, + { value => "O", lib => "Other" }, + ], + mandatory => ( grep /sex/, @mandatoryFields ) ? 1 : 0, + }, { name => "branchcode", type => "select", @@ -356,7 +367,7 @@ if ( $op eq 'cud-do' ) { my @disabled = $input->multi_param('disable_input'); my $infos; for my $field ( - qw/surname firstname branchcode categorycode streetnumber address address2 city state zipcode country email phone mobile fax sort1 sort2 dateenrolled dateexpiry password_expiration_date borrowernotes opacnote debarred debarredcomment protected/ + qw/surname firstname sex branchcode categorycode streetnumber address address2 city state zipcode country email phone mobile fax sort1 sort2 dateenrolled dateexpiry password_expiration_date borrowernotes opacnote debarred debarredcomment protected/ ) { my $value = $input->param($field);