/[Frey]/trunk/lib/App/RoomReservation/Reservation.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /trunk/lib/App/RoomReservation/Reservation.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1118 by dpavlin, Tue Jun 30 09:42:37 2009 UTC revision 1121 by dpavlin, Tue Jun 30 13:24:03 2009 UTC
# Line 81  has _confirmed => ( Line 81  has _confirmed => (
81          default => sub { 0 },          default => sub { 0 },
82  );  );
83    
84    has _seat_number => (
85            is => 'rw',
86            isa => 'Int',
87    );
88    
89  sub BUILD {  sub BUILD {
90          my $self = shift;          my $self = shift;
91          die "e-mail not verified\n" unless $self->email eq $self->email_verify;          die "e-mail not verified\n" unless $self->email eq $self->email_verify;
92            my $sth = $self->dbh->prepare(qq{
93                    select count(*) from reservation where email = ?
94            });
95            $sth->execute( $self->email );
96            my ($registred) = $sth->fetchrow_array;
97            die "e-mail address ", $self->email, " allready registred\n" if $registred;
98  }  }
99    
100  my @cols = Frey::PPI->new( class => __PACKAGE__ )->attribute_order;  my @cols = Frey::PPI->new( class => __PACKAGE__ )->attribute_order;

Legend:
Removed from v.1118  
changed lines
  Added in v.1121

  ViewVC Help
Powered by ViewVC 1.1.26