|
Lines 1-6
Link Here
|
| 1 |
#!/usr/bin/perl |
1 |
#!/usr/bin/perl |
| 2 |
|
2 |
|
| 3 |
# Copyright 2000-2002 Katipo Communications |
3 |
# Copyright 2000-2002 Katipo Communications |
|
|
4 |
# Parts copyright 2011 BibLibre |
| 4 |
# |
5 |
# |
| 5 |
# This file is part of Koha. |
6 |
# This file is part of Koha. |
| 6 |
# |
7 |
# |
|
Lines 40-61
$flagsrequired->{borrowers} = 1;
Link Here
|
| 40 |
my ( $loggedinuser, $cookie, $sessionID ) = |
41 |
my ( $loggedinuser, $cookie, $sessionID ) = |
| 41 |
checkauth( $input, 0, $flagsrequired ); |
42 |
checkauth( $input, 0, $flagsrequired ); |
| 42 |
|
43 |
|
| 43 |
my $destination = $input->param("destination") || ''; |
|
|
| 44 |
my $cardnumber = $input->param("cardnumber"); |
| 45 |
my $borrowernumber = $input->param('borrowernumber'); |
44 |
my $borrowernumber = $input->param('borrowernumber'); |
| 46 |
my $status = $input->param('status'); |
|
|
| 47 |
|
45 |
|
| 48 |
my $dbh = C4::Context->dbh; |
46 |
my $dbh = C4::Context->dbh; |
| 49 |
my $sth = |
47 |
my $sth = |
| 50 |
$dbh->prepare("Update borrowers set debarred = ? where borrowernumber = ?"); |
48 |
$dbh->prepare("Update borrowers set debarred = NULL where borrowernumber = ?"); |
| 51 |
$sth->execute( $status, $borrowernumber ); |
49 |
$sth->execute( $borrowernumber ); |
| 52 |
$sth->finish; |
50 |
$sth->finish; |
| 53 |
|
51 |
|
| 54 |
if ( $destination eq "circ" ) { |
52 |
print $input->redirect( |
| 55 |
print $input->redirect( |
53 |
"/cgi-bin/koha/members/moremember.pl?borrowernumber=$borrowernumber"); |
| 56 |
"/cgi-bin/koha/circ/circulation.pl?findborrower=".$cardnumber); |
|
|
| 57 |
} |
| 58 |
else { |
| 59 |
print $input->redirect( |
| 60 |
"/cgi-bin/koha/members/moremember.pl?borrowernumber=$borrowernumber"); |
| 61 |
} |