Initial auth example, something is a bit wonky with the session?
[catagits/Web-Simple.git] / examples / auth / lib / AuthApp / Schema / Result / User.pm
CommitLineData
f8cbb1c8 1package AuthApp::Schema::Result::User;
2
3use base 'DBIx::Class::Core';
4
5__PACKAGE__->load_components(qw(InflateColumn::Authen::Passphrase));
6__PACKAGE__->table('users');
7__PACKAGE__->add_columns(
8 id => {
9 data_type => 'integer',
10 is_auto_increment => 1,
11 },
12 username => {
13 data_type => 'TINYTEXT',
14 },
15 password => {
16 data_type => 'varchar',
17 size => 255,
18 inflate_passphrase => 'rfc2307',
19 },
20 );
21
22__PACKAGE__->set_primary_key('id');
23__PACKAGE__->add_unique_constraint('username' => ['username']);
24
251;
26
27