To update the image for [% patron.title | html %] [% patron.surname | html %], select a new image file and click 'Upload.'
Click the 'Delete' button to remove the current image.
[% ELSE %]
@@ -207,7 +207,7 @@
- [% IF ( picture ) %]
Delete[% END %]
+ [% IF ( patron.image ) %]
Delete[% END %]
@@ -297,7 +297,7 @@
Borrowernumber: [% patron.borrowernumber %]
Category: [% patron.category.description %] ([% patron.categorycode %])
Registration date: [% patron.dateenrolled | $KohaDates %]
-
+
Expiration date:
[% IF ( was_renewed ) %]
[% patron.dateexpiry | $KohaDates %]
@@ -390,10 +390,10 @@
First name: [% patron.altcontactfirstname | html %]
Address: [% patron.altcontactaddress1 | html %]
Address 2: [% patron.altcontactaddress2 | html %]
-
City: [% patron.altcontactaddress3 | html %]
+
City: [% patron.altcontactaddress3 | html %]
[% IF ( patron.altcontactstate ) %]
State: [% patron.altcontactstate | html %][% END %]
ZIP/Postal code: [% patron.altcontactzipcode | html %]
- [% IF ( patron.altcontactcountry ) %]
Country: [% patron.altcontactcountry | html %][% END %]
+ [% IF ( patron.altcontactcountry ) %]
Country: [% patron.altcontactcountry | html %][% END %]
[% IF ( patron.altcontactphone ) %]
Phone: [% patron.altcontactphone | html %][% END %]
@@ -606,7 +606,7 @@
],
"bPaginate": false
}));
- [% IF ( picture ) %]
+ [% IF ( patron.image ) %]
$('#delpicture').click(function(){
return confirm(_("Are you sure you want to delete this patron image? This cannot be undone."));
});
--- a/members/boraccount.pl
+++ a/members/boraccount.pl
@@ -98,8 +98,6 @@ foreach my $accountline ( @{$accts}) {
$template->param( adultborrower => 1 ) if ( $patron->category->category_type =~ /^(A|I)$/ );
-$template->param( picture => 1 ) if $patron->image;
-
if (C4::Context->preference('ExtendedPatronAttributes')) {
my $attributes = GetBorrowerAttributes($borrowernumber);
$template->param(
--- a/members/deletemem.pl
+++ a/members/deletemem.pl
@@ -108,7 +108,6 @@ my $op = $input->param('op') || 'delete_confirm';
my $dbh = C4::Context->dbh;
my $is_guarantor = $dbh->selectrow_array("SELECT COUNT(*) FROM borrowers WHERE guarantorid=?", undef, $member);
if ( $op eq 'delete_confirm' or $countissues > 0 or $flags->{'CHARGES'} or $is_guarantor or $deletelocal == 0) {
- $template->param( picture => 1 ) if $patron->image;
$template->param( adultborrower => 1 ) if $patron->category->category_type =~ /^(A|I)$/;
--- a/members/discharge.pl
+++ a/members/discharge.pl
@@ -103,8 +103,6 @@ my @validated_discharges = Koha::Patron::Discharge::get_validated({
borrowernumber => $borrowernumber,
});
-$template->param( picture => 1 ) if $patron->image;
-
$template->param(
patron => $patron,
can_be_discharged => $can_be_discharged,
--- a/members/files.pl
+++ a/members/files.pl
@@ -114,7 +114,6 @@ else {
);
}
- $template->param( picture => 1 ) if $patron->image;
$template->param( adultborrower => 1 )
if ( $patron_category->category_type eq 'A' || $patron_category->category_type eq 'I' );
--- a/members/housebound.pl
+++ a/members/housebound.pl
@@ -62,9 +62,8 @@ my $patron = Koha::Patrons->find($borrowernumber);
output_and_exit_if_error( $input, $cookie, $template, { module => 'members', logged_in_user => $logged_in_user, current_patron => $patron } );
# Get supporting cast
-my ( $branch, $category, $houseboundprofile, $visit, $patron_image );
+my ( $branch, $category, $houseboundprofile, $visit );
if ( $patron ) { # FIXME This test is not needed - output_and_exit_if_error handles it
- $patron_image = $patron->image;
$category = Koha::Patron::Categories->new->find($patron->categorycode);
$houseboundprofile = $patron->housebound_profile;
}
@@ -170,7 +169,6 @@ if ( C4::Context->preference('ExtendedPatronAttributes') and $patron ) {
$template->param( adultborrower => 1 ) if ( $category->category_type eq 'A' || $category->category_type eq 'I' );
$template->param(
- picture => $patron_image,
housebound_profile => $houseboundprofile,
visit => $houseboundvisit,
messages => \@messages,
--- a/members/mancredit.pl
+++ a/members/mancredit.pl
@@ -86,7 +86,6 @@ if ($add){
}
$template->param( adultborrower => 1 ) if ( $patron->category->category_type =~ /^(A|I)$/ );
- $template->param( picture => 1 ) if $patron->image;
if (C4::Context->preference('ExtendedPatronAttributes')) {
my $attributes = GetBorrowerAttributes($borrowernumber);
--- a/members/maninvoice.pl
+++ a/members/maninvoice.pl
@@ -114,7 +114,6 @@ if ($add){
}
$template->param( adultborrower => 1 ) if ( $patron->category->category_type =~ /^(A|I)$/ );
- $template->param( picture => 1 ) if $patron->image;
if (C4::Context->preference('ExtendedPatronAttributes')) {
my $attributes = GetBorrowerAttributes($borrowernumber);
--- a/members/member-flags.pl
+++ a/members/member-flags.pl
@@ -18,7 +18,6 @@ use Koha::Patron::Categories;
use Koha::Patrons;
use C4::Output;
-use Koha::Patron::Images;
use Koha::Token;
my $input = new CGI;
@@ -189,7 +188,6 @@ if ($input->param('newflags')) {
}
$template->param( adultborrower => 1 ) if ( $category_type =~ /^(A|I)$/ );
- $template->param( picture => 1 ) if $patron->image;
if (C4::Context->preference('ExtendedPatronAttributes')) {
my $attributes = GetBorrowerAttributes($bor->{'borrowernumber'});
--- a/members/member-password.pl
+++ a/members/member-password.pl
@@ -103,8 +103,6 @@ if ( $category_type eq 'C') {
$template->param( adultborrower => 1 ) if ( $category_type =~ /^(A|I)$/ );
-$template->param( picture => 1 ) if $patron->image;
-
if ( C4::Context->preference('ExtendedPatronAttributes') ) {
my $attributes = GetBorrowerAttributes( $bor->{'borrowernumber'} );
$template->param(
--- a/members/moremember.pl
+++ a/members/moremember.pl
@@ -53,7 +53,6 @@ use C4::Members::Attributes qw(GetBorrowerAttributes);
use Koha::AuthorisedValues;
use Koha::CsvProfiles;
use Koha::Patron::Debarments qw(GetDebarments);
-use Koha::Patron::Images;
use Koha::Patron::Messages;
use Module::Load;
if ( C4::Context->preference('NorwegianPatronDBEnable') && C4::Context->preference('NorwegianPatronDBEnable') == 1 ) {
@@ -275,10 +274,6 @@ if ( C4::Context->preference('NorwegianPatronDBEnable') && C4::Context->preferen
}
}
-# check to see if patron's image exists in the database
-# basically this gives us a template var to condition the display of
-# patronimage related interface on
-$template->param( picture => 1 ) if $patron->image;
# Generate CSRF token for upload and delete image buttons
$template->param(
csrf_token => Koha::Token->new->generate_csrf({ session_id => $input->cookie('CGISESSID'),}),
--- a/members/notices.pl
+++ a/members/notices.pl
@@ -51,8 +51,6 @@ my ($template, $loggedinuser, $cookie)
my $logged_in_user = Koha::Patrons->find( $loggedinuser ) or die "Not logged in";
output_and_exit_if_error( $input, $cookie, $template, { module => 'members', logged_in_user => $logged_in_user, current_patron => $patron } );
-$template->param( picture => 1 ) if $patron->image;
-
# Allow resending of messages in Notices tab
my $op = $input->param('op') || q{};
if ( $op eq 'resend_notice' ) {
--- a/members/pay.pl
+++ a/members/pay.pl
@@ -40,7 +40,6 @@ use C4::Koha;
use C4::Overdues;
use C4::Members::Attributes qw(GetBorrowerAttributes);
use Koha::Patrons;
-use Koha::Patron::Images;
use Koha::Patron::Categories;
use URI::Escape;
@@ -140,8 +139,6 @@ sub add_accounts_to_template {
}
borrower_add_additional_fields($patron->unblessed);
- my $patron_image = Koha::Patron::Images->find($borrower->{borrowernumber});
- $template->param( picture => 1 ) if $patron_image;
$template->param(
patron => $patron,
accounts => \@accounts,
--- a/members/paycollect.pl
+++ a/members/paycollect.pl
@@ -27,7 +27,6 @@ use C4::Members;
use C4::Members::Attributes qw(GetBorrowerAttributes);
use C4::Accounts;
use C4::Koha;
-use Koha::Patron::Images;
use Koha::Patrons;
use Koha::Account;
use Koha::Token;
@@ -200,9 +199,6 @@ sub borrower_add_additional_fields {
$b_ref->{adultborrower} = 1;
}
- my $patron_image = Koha::Patron::Images->find($b_ref->{borrowernumber});
- $template->param( picture => 1 ) if $patron_image;
-
if (C4::Context->preference('ExtendedPatronAttributes')) {
$b_ref->{extendedattributes} = GetBorrowerAttributes($b_ref->{borrowernumber});
}
--- a/members/printfeercpt.pl
+++ a/members/printfeercpt.pl
@@ -116,8 +116,6 @@ for (my $i=0;$i<$numaccts;$i++){
$template->param( adultborrower => 1 ) if ( $category->category_type eq 'A' || $category->category_type eq 'I' );
-$template->param( picture => 1 ) if $patron->image;
-
$template->param(
patron => $patron,
finesview => 1,
--- a/members/printinvoice.pl
+++ a/members/printinvoice.pl
@@ -116,8 +116,6 @@ for ( my $i = 0 ; $i < $numaccts ; $i++ ) {
$template->param( adultborrower => 1 ) if ( $category->category_type eq 'A' || $category->category_type eq 'I' );
-$template->param( picture => 1 ) if $patron->image;
-
$template->param(
patron => $patron,
finesview => 1,
--- a/members/purchase-suggestions.pl
+++ a/members/purchase-suggestions.pl
@@ -60,8 +60,6 @@ if (C4::Context->preference('ExtendedPatronAttributes')) {
);
}
-$template->param( picture => 1 ) if $patron->image;
-
my $suggestions = SearchSuggestion( { suggestedby => $borrowernumber } );
$template->param( suggestions => $suggestions );
--- a/members/readingrec.pl
+++ a/members/readingrec.pl
@@ -104,8 +104,6 @@ if (! $limit){
$limit = 'full';
}
-$template->param( picture => 1 ) if $patron->image;
-
if (C4::Context->preference('ExtendedPatronAttributes')) {
my $attributes = GetBorrowerAttributes($patron->borrowernumber);
$template->param(
--- a/members/routing-lists.pl
+++ a/members/routing-lists.pl
@@ -88,6 +88,4 @@ if (C4::Context->preference('ExtendedPatronAttributes')) {
);
}
-$template->param( picture => 1 ) if $patron and $patron->image;
-
output_html_with_http_headers $query, $cookie, $template->output;
--- a/members/statistics.pl
+++ a/members/statistics.pl
@@ -84,8 +84,6 @@ if (C4::Context->preference('ExtendedPatronAttributes')) {
);
}
-$template->param( picture => 1 ) if $patron->image;
-
$template->param( adultborrower => 1 ) if ( $category->category_type eq 'A' || $category->category_type eq 'I' );
$template->param(
--