[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Koha-cvs] koha C4/Members.pm members/memberentry.pl
From: |
Chris Cormack |
Subject: |
[Koha-cvs] koha C4/Members.pm members/memberentry.pl |
Date: |
Thu, 01 Jun 2006 23:18:57 +0000 |
CVSROOT: /sources/koha
Module name: koha
Branch:
Changes by: Chris Cormack <address@hidden> 06/06/01 23:18:57
Modified files:
C4 : Members.pm
members : memberentry.pl
Log message:
Modifying members is now working, well mostly anyway.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/koha/koha/C4/Members.pm.diff?tr1=1.18&tr2=1.19&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/koha/koha/members/memberentry.pl.diff?tr1=1.23&tr2=1.24&r1=text&r2=text
Patches:
Index: koha/C4/Members.pm
diff -u koha/C4/Members.pm:1.18 koha/C4/Members.pm:1.19
--- koha/C4/Members.pm:1.18 Thu Jun 1 22:49:08 2006
+++ koha/C4/Members.pm Thu Jun 1 23:18:57 2006
@@ -19,7 +19,7 @@
# Koha; if not, write to the Free Software Foundation, Inc., 59 Temple Place,
# Suite 330, Boston, MA 02111-1307 USA
-# $Id: Members.pm,v 1.18 2006/06/01 22:49:08 rangi Exp $
+# $Id: Members.pm,v 1.19 2006/06/01 23:18:57 rangi Exp $
use strict;
require Exporter;
@@ -30,7 +30,7 @@
use vars qw($VERSION @ISA @EXPORT @EXPORT_OK);
-$VERSION = do { my @v = '$Revision: 1.18 $' =~ /\d+/g; shift(@v) . "." . join(
"_", map { sprintf "%03d", $_ } @v ); };
+$VERSION = do { my @v = '$Revision: 1.19 $' =~ /\d+/g; shift(@v) . "." . join(
"_", map { sprintf "%03d", $_ } @v ); };
=head1 NAME
@@ -304,11 +304,11 @@
my $query = "UPDATE borrowers SET
title=?,dateexpiry=?,cardnumber=?,sex=?,ethnotes=?,address=?,fax=?,
- firstname=?,contactnote=?,dateofbirth=?,contactname=?,emailaddress=?,
- streetcity=?,altrelationship=?,othernames=?,phoneday=?,categorycode=?,
- city=?,area=?,phone=?,borrowernotes=?,altphone=?,surname=?,initials=?,
- physstreet=?,ethnicity=?,gonenoaddress=?,lost=?,debarred=?,textmessaging=?,
- branchcode=?,zipcode=?,homezipcode=?,sort1=?,sort2=?
+ firstname=?,contactnote=?,dateofbirth=?,contactname=?,email=?,
+ address2=?,relationship=?,othernames=?,phonepro=?,categorycode=?,
+ city=?,phone=?,borrowernotes=?,B_phone=?,surname=?,initials=?,
+ B_address=?,ethnicity=?,gonenoaddress=?,lost=?,debarred=?,opacnote=?,
+ branchcode=?,zipcode=?,B_zipcode=?,sort1=?,sort2=?
WHERE borrowernumber=?";
my $sth = $dbh->prepare($query);
@@ -318,22 +318,21 @@
$data{'ehtnotes'}, $data{'address'},
$data{'fax'}, $data{'firstname'},
$data{'contactnote'}, $data{'dateofbirth'},
- $data{'contactname'}, $data{'emailaddress'},
- $data{'streetcity'}, $data{'altrelationship'},
- $data{'othernames'}, $data{'phoneday'},
+ $data{'contactname'}, $data{'email'},
+ $data{'address2'}, $data{'relationship'},
+ $data{'othernames'}, $data{'phonepro'},
$data{'categorycode'}, $data{'city'},
- $data{'area'}, $data{'phone'},
- $data{'borrowernotes'}, $data{'altphone'},
+ $data{'phone'},
+ $data{'borrowernotes'}, $data{'b_phone'},
$data{'surname'}, $data{'initials'},
- $data{'physstreet'}, $data{'ethnicity'},
+ $data{'b_address'}, $data{'ethnicity'},
$data{'gna'}, $data{'lost'},
- $data{'debarred'}, $data{'textmessaging'},
+ $data{'debarred'}, $data{'opacnotes'},
$data{'branchcode'}, $data{'zipcode'},
- $data{'homezipcode'}, $data{'sort1'},
- $data{'sort2'}, $data{'borrowernumber'}
+ $data{'b_zipcode'}, $data{'sort1'},
+ $data{'sort2'}, $data{'borrowerid'}
);
$sth->finish;
-
# ok if its an adult (type) it may have borrowers that depend on it as a
guarantor
# so when we update information for an adult we should check for guarantees
and update the relevant part
# of their records, ie addresses and phone numbers
Index: koha/members/memberentry.pl
diff -u koha/members/memberentry.pl:1.23 koha/members/memberentry.pl:1.24
--- koha/members/memberentry.pl:1.23 Thu Jun 1 21:49:25 2006
+++ koha/members/memberentry.pl Thu Jun 1 23:18:57 2006
@@ -1,5 +1,5 @@
#!/usr/bin/perl
-# $Id: memberentry.pl,v 1.23 2006/06/01 21:49:25 rangi Exp $
+# $Id: memberentry.pl,v 1.24 2006/06/01 23:18:57 rangi Exp $
# Copyright 2006 SAN OUEST PROVENCE et Paul POULAIN
#
@@ -89,8 +89,18 @@
$template->param( "checked" => 1) if ($nodouble eq 1);
-
+my $borrower_data=borrdata('',$borrowernumber);
# if a add or modify is requested => check validity of data.
+if ($step eq 0){
+ foreach my $column (keys %$borrower_data){
+ $data{$column}=$borrower_data->{$column};
+ }
+ $data{'borrowerid'}=$borrowernumber;
+ if (!$borrowerid){
+ $borrowerid=$borrowernumber;
+ }
+}
+
if ($op eq 'add' or $op eq 'modify') {
my @names=$input->param;
foreach my $key (@names){
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Koha-cvs] koha C4/Members.pm members/memberentry.pl,
Chris Cormack <=