package myHive::Model::DB::Areas;
use Moose;
use namespace::autoclean;
use Data::Dumper;

extends 'myHive::Model::DB';

=head1 NAME

myHive::Model::DB::Areas - Catalyst Model

=head1 DESCRIPTION

Catalyst Model.

=head1 AUTHOR

root

=head1 LICENSE

This library is free software. You can redistribute it and/or modify
it under the same terms as Perl itself.

=cut

sub add {
        my ( $self, %params ) = @_;
        print STDERR Dumper(\%params);
        my $procedure           = 'addAreas';
        my $account             = $params{account};
        my $id              	= $params{id} || 0;
        my $name                = $params{name};
        my $stmt      = qq/select $procedure($account, $id,'$name')/;
        my ($sth,@bind)       = $self->{dbh}->prepare($stmt);
        #check to see if we should log
        if ( exists $params{log} && $params{log} == 1 ) {
                print STDERR Dumper($stmt);
                print STDERR Dumper(\@bind);
        }

        $sth->execute;
        return $sth;




}


__PACKAGE__->meta->make_immutable;

1;
