line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
13
|
|
|
13
|
|
43262
|
use utf8; |
|
13
|
|
|
|
|
31
|
|
|
13
|
|
|
|
|
102
|
|
2
|
|
|
|
|
|
|
package Biblio::Zotero::DB::Schema::Result::ItemData; |
3
|
|
|
|
|
|
|
$Biblio::Zotero::DB::Schema::Result::ItemData::VERSION = '0.003'; |
4
|
|
|
|
|
|
|
# Created by DBIx::Class::Schema::Loader |
5
|
|
|
|
|
|
|
# DO NOT MODIFY THE FIRST PART OF THIS FILE |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
|
8
|
13
|
|
|
13
|
|
887
|
use strict; |
|
13
|
|
|
|
|
32
|
|
|
13
|
|
|
|
|
392
|
|
9
|
13
|
|
|
13
|
|
89
|
use warnings; |
|
13
|
|
|
|
|
30
|
|
|
13
|
|
|
|
|
370
|
|
10
|
|
|
|
|
|
|
|
11
|
13
|
|
|
13
|
|
64
|
use base 'DBIx::Class::Core'; |
|
13
|
|
|
|
|
34
|
|
|
13
|
|
|
|
|
4642
|
|
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
__PACKAGE__->table("itemData"); |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
__PACKAGE__->add_columns( |
18
|
|
|
|
|
|
|
"itemid", |
19
|
|
|
|
|
|
|
{ data_type => "int", is_foreign_key => 1, is_nullable => 0 }, |
20
|
|
|
|
|
|
|
"fieldid", |
21
|
|
|
|
|
|
|
{ data_type => "int", is_foreign_key => 1, is_nullable => 0 }, |
22
|
|
|
|
|
|
|
"valueid", |
23
|
|
|
|
|
|
|
{ data_type => "", is_foreign_key => 1, is_nullable => 1 }, |
24
|
|
|
|
|
|
|
); |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
__PACKAGE__->set_primary_key("itemid", "fieldid"); |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
__PACKAGE__->belongs_to( |
31
|
|
|
|
|
|
|
"fieldid", |
32
|
|
|
|
|
|
|
"Biblio::Zotero::DB::Schema::Result::Field", |
33
|
|
|
|
|
|
|
{ fieldid => "fieldid" }, |
34
|
|
|
|
|
|
|
{ is_deferrable => 0, on_delete => "NO ACTION", on_update => "NO ACTION" }, |
35
|
|
|
|
|
|
|
); |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
__PACKAGE__->belongs_to( |
39
|
|
|
|
|
|
|
"itemid", |
40
|
|
|
|
|
|
|
"Biblio::Zotero::DB::Schema::Result::Item", |
41
|
|
|
|
|
|
|
{ itemid => "itemid" }, |
42
|
|
|
|
|
|
|
{ is_deferrable => 0, on_delete => "NO ACTION", on_update => "NO ACTION" }, |
43
|
|
|
|
|
|
|
); |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
__PACKAGE__->belongs_to( |
47
|
|
|
|
|
|
|
"valueid", |
48
|
|
|
|
|
|
|
"Biblio::Zotero::DB::Schema::Result::ItemDataValue", |
49
|
|
|
|
|
|
|
{ valueid => "valueid" }, |
50
|
|
|
|
|
|
|
{ |
51
|
|
|
|
|
|
|
is_deferrable => 0, |
52
|
|
|
|
|
|
|
join_type => "LEFT", |
53
|
|
|
|
|
|
|
on_delete => "NO ACTION", |
54
|
|
|
|
|
|
|
on_update => "NO ACTION", |
55
|
|
|
|
|
|
|
}, |
56
|
|
|
|
|
|
|
); |
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
|
59
|
|
|
|
|
|
|
# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-07-02 23:02:38 |
60
|
|
|
|
|
|
|
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:roFvJq1zvhoDYyltiT55LQ |
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
# NOTE: extended DBIC schema below |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
# TODO: document |
66
|
|
|
|
|
|
|
sub field_value { |
67
|
129
|
|
|
129
|
0
|
355
|
my ($self) = @_; |
68
|
129
|
|
|
|
|
3142
|
return $self->fieldid->fieldname => $self->valueid->value; |
69
|
|
|
|
|
|
|
} |
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
1; |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
__END__ |