AproJo/DB/Schema/Result/Party.pm

filter: Statementstmt 100% 16 / 16 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 3 / 3 Podpod n/a totaltotal 100% 19 / 19 CC 1 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« AproJo/DB/Schema/Result/Orderitem.pm ↑ Summary AproJo/DB/Schema/Result/Preference.pm »
1 package AproJo::DB::Schema::Result::Party;
2  
3 2 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 2 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 2 ▶use base 'DBIx::Class::Core';
Subroutine BEGIN: called CC=1 SCAR=0.0
7  
8 2 __PACKAGE__->table("parties");
9  
10 2 __PACKAGE__->add_columns(
11 "party_id",
12 {data_type => "integer", is_auto_increment => 1, is_nullable => 0},
13 "name",
14 {data_type => "varchar", is_nullable => 0, size => 50},
15 "address_id",
16 {data_type => "integer", is_nullable => 0, is_foreign_key => 1},
17 "billingaddress_id",
18 {data_type => "integer", is_nullable => 0, is_foreign_key => 1},
19 "deliveryaddress_id",
20 {data_type => "integer", is_nullable => 0, is_foreign_key => 1},
21 "comment",
22 {data_type => "text", default_value => '', is_nullable => 1},
23 );
24  
25 2 __PACKAGE__->set_primary_key("party_id");
26  
27 2 __PACKAGE__->has_one(
28 'address',
29 'AproJo::DB::Schema::Result::Address',
30 {'foreign.address_id' => 'self.address_id'},
31 {cascade_delete => 0}
32 );
33  
34 2 __PACKAGE__->might_have(
35 'billingaddress',
36 'AproJo::DB::Schema::Result::Address',
37 {'foreign.address_id' => 'self.billingaddress_id'},
38 {cascade_delete => 0}
39 );
40  
41 2 __PACKAGE__->might_have(
42 'deliveryaddress',
43 'AproJo::DB::Schema::Result::Address',
44 {'foreign.address_id' => 'self.deliveryaddress_id'},
45 {cascade_delete => 0}
46 );
47  
48 2 1;
« AproJo/DB/Schema/Result/Orderitem.pm ↑ Summary AproJo/DB/Schema/Result/Preference.pm »