File: FourKeys_to_TwoKeys.pm

package info (click to toggle)
libdbix-class-perl 0.082844-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 5,320 kB
  • sloc: perl: 27,215; sql: 322; sh: 29; makefile: 16
file content (36 lines) | stat: -rw-r--r-- 1,019 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
package # hide from PAUSE
    DBICTest::Schema::FourKeys_to_TwoKeys;

use warnings;
use strict;

use base qw/DBICTest::BaseResult/;

__PACKAGE__->table('fourkeys_to_twokeys');
__PACKAGE__->add_columns(
  'f_foo' => { data_type => 'integer' },
  'f_bar' => { data_type => 'integer' },
  'f_hello' => { data_type => 'integer' },
  'f_goodbye' => { data_type => 'integer' },
  't_artist' => { data_type => 'integer' },
  't_cd' => { data_type => 'integer' },
  'autopilot' => { data_type => 'character' },
  'pilot_sequence' => { data_type => 'integer', is_nullable => 1 },
);
__PACKAGE__->set_primary_key(
  qw/f_foo f_bar f_hello f_goodbye t_artist t_cd/
);

__PACKAGE__->belongs_to('fourkeys', 'DBICTest::Schema::FourKeys', {
  'foreign.foo' => 'self.f_foo',
  'foreign.bar' => 'self.f_bar',
  'foreign.hello' => 'self.f_hello',
  'foreign.goodbye' => 'self.f_goodbye',
});

__PACKAGE__->belongs_to('twokeys', 'DBICTest::Schema::TwoKeys', {
  'foreign.artist' => 'self.t_artist',
  'foreign.cd' => 'self.t_cd',
});

1;