Preferences/Schema/Result/CustomDataUniqueValues.pm

filter: Statementstmt 100% 18 / 18 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 3 / 3 Podpod n/a totaltotal 100% 21 / 21 CC 1 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« Preferences.pm ↑ Summary Preferences/Schema/Result/PrfDefaultValues.pm »
1 package OpusVL::Preferences::Schema::Result::CustomDataUniqueValues;
2  
3 1 ▶use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 1 ▶use MooseX::NonMoose;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 1 ▶use namespace::autoclean;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 1 extends 'DBIx::Class::Core';
7  
8 1 __PACKAGE__->table("prf_unique_vals");
9 1 __PACKAGE__->add_columns
10 (
11 id => {
12 data_type => 'int',
13 is_auto_increment => 1,
14 },
15 value_id => {
16 data_type => 'integer',
17 is_nullable => 0,
18 },
19 value => {
20 data_type => 'text',
21 is_nullable => 1,
22 },
23 prf_owner_type_id =>
24 {
25 data_type => "integer",
26 is_nullable => 0,
27 },
28 name =>
29 {
30 data_type => 'varchar',
31 is_nullable => 0
32 },
33 );
34  
35 1 __PACKAGE__->set_primary_key("id");
36  
37 1 __PACKAGE__->add_unique_constraint([ qw/value_id prf_owner_type_id name/ ]);
38 1 __PACKAGE__->add_unique_constraint([ qw/value prf_owner_type_id name/ ]);
39  
40 1 __PACKAGE__->belongs_to(field =>
41 "OpusVL::Preferences::Schema::Result::PrfDefault",
42 {
43 "foreign.prf_owner_type_id" => "self.prf_owner_type_id",
44 "foreign.name" => "self.name",
45 });
46  
47 1 __PACKAGE__->belongs_to(parent_value =>
48 "OpusVL::Preferences::Schema::Result::PrfPreference",
49 {
50 "foreign.prf_owner_type_id" => "self.prf_owner_type_id",
51 "foreign.name" => "self.name",
52 "foreign.prf_preference_id" => "self.value_id"
53 });
54  
55  
56 1 1;
57  
58 __END__
59  
60 =pod
61  
62 =encoding UTF-8
63  
64 =head1 NAME
65  
66 OpusVL::Preferences::Schema::Result::CustomDataUniqueValues
67  
68 =head1 VERSION
69  
70 version 0.24
71  
72 =head1 DESCRIPTION
73  
74 =head1 METHODS
75  
76 =head1 ATTRIBUTES
77  
78 =head2 id
79  
80 =head2 value_id
81  
82 =head2 value
83  
84 =head2 field_id
85  
86 =head2 field
87  
88 =head2 parent_value
89  
90 =head1 LICENSE AND COPYRIGHT
91  
92 Copyright 2013 OpusVL.
93  
94 This software is licensed according to the "IP Assignment Schedule" provided with the development project.
95  
96 =head1 AUTHOR
97  
98 OpusVL - www.opusvl.com
99  
100 =head1 COPYRIGHT AND LICENSE
101  
102 This software is copyright (c) 2011 by OpusVL - www.opusvl.com.
103  
104 This is free software; you can redistribute it and/or modify it under
105 the same terms as the Perl 5 programming language system itself.
106  
107 =cut
« Preferences.pm ↑ Summary Preferences/Schema/Result/PrfDefaultValues.pm »