1 package # hide from PAUSE
2 DBICTest::Schema::Encoded;
4 use base qw/DBICTest::BaseResult/;
9 __PACKAGE__->table('encoded');
10 __PACKAGE__->add_columns(
12 data_type => 'integer',
13 is_auto_increment => 1
16 data_type => 'varchar',
22 __PACKAGE__->set_primary_key('id');
24 __PACKAGE__->has_many (keyholders => 'DBICTest::Schema::Employee', 'encoded');
27 my ($self, $col, $value) = @_;
28 if( $col eq 'encoded' ){
29 $value = reverse split '', $value;
31 $self->next::method($col, $value);
35 my($self, $attr, @rest) = @_;
36 $attr->{encoded} = reverse split '', $attr->{encoded}
37 if defined $attr->{encoded};
38 return $self->next::method($attr, @rest);