Preferences/Schema/Result/PrfDefaultValues.pm

filter: Statementstmt 100% 18 / 18 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 4 / 4 Podpod n/a totaltotal 100% 22 / 22 CC 1 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« Preferences/Schema/Result/CustomDataUniqueValues.pm ↑ Summary Preferences/Schema/Result/PrfOwnerType.pm »
1 package OpusVL::Preferences::Schema::Result::PrfDefaultValues;
2  
3 1 ▶use 5.010;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 1 ▶use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 1 ▶use MooseX::NonMoose;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 1 ▶use namespace::autoclean;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 1 extends 'DBIx::Class::Core';
8  
9 1 __PACKAGE__->table('prf_default_values');
10  
11 1 __PACKAGE__->add_columns(
12 'id' => {
13 data_type => "int",
14 is_auto_increment => 1,
15 is_nullable => 0,
16 },
17 'value' => {
18 data_type => 'text',
19 is_nullable => 1,
20 },
21 'prf_owner_type_id' => {
22 data_type => 'integer',
23 is_nullable => 0,
24 },
25 name => {
26 data_type => "varchar",
27 is_nullable => 0,
28 },
29 display_order =>
30 {
31 data_type => 'int',
32 is_nullable => 0,
33 default_value => 1,
34 },
35 );
36  
37 1 __PACKAGE__->set_primary_key("id");
38  
39 1 __PACKAGE__->belongs_to(
40 'field' => 'OpusVL::Preferences::Schema::Result::PrfDefault',
41 {
42 "foreign.name" => "self.name",
43 "foreign.prf_owner_type_id" => "self.prf_owner_type_id",
44 }
45 );
46  
47 1 __PACKAGE__->meta->make_immutable();
48  
49  
50 1 1;
51  
52  
53  
54 =head1 DESCRIPTION
55  
56 Helpfully, this stores the actual default values for fields. Redundantly,
57 because prf_defaults already has a default_value column.
58  
59 =head1 METHODS
60  
61 =head1 ATTRIBUTES
62  
63 =head2 field
64  
65 =head2 id
66  
67 =head2 value
68  
69 =head2 prf_owner_type_id
70  
71 =head2 name
72  
73  
74 =head1 LICENSE AND COPYRIGHT
75  
76 Copyright 2012 OpusVL.
77  
78 This software is licensed according to the "IP Assignment Schedule" provided with the development project.
79  
80 =cut
« Preferences/Schema/Result/CustomDataUniqueValues.pm ↑ Summary Preferences/Schema/Result/PrfOwnerType.pm »