Bug 8798: DBIx::Class base classes for all Koha tables
[koha.git] / Koha / Schema / Result / HoldFillTarget.pm
1 package Koha::Schema::Result::HoldFillTarget;
2
3 # Created by DBIx::Class::Schema::Loader
4 # DO NOT MODIFY THE FIRST PART OF THIS FILE
5
6 use strict;
7 use warnings;
8
9 use base 'DBIx::Class::Core';
10
11
12 =head1 NAME
13
14 Koha::Schema::Result::HoldFillTarget
15
16 =cut
17
18 __PACKAGE__->table("hold_fill_targets");
19
20 =head1 ACCESSORS
21
22 =head2 borrowernumber
23
24   data_type: 'integer'
25   is_foreign_key: 1
26   is_nullable: 0
27
28 =head2 biblionumber
29
30   data_type: 'integer'
31   is_foreign_key: 1
32   is_nullable: 0
33
34 =head2 itemnumber
35
36   data_type: 'integer'
37   is_foreign_key: 1
38   is_nullable: 0
39
40 =head2 source_branchcode
41
42   data_type: 'varchar'
43   is_foreign_key: 1
44   is_nullable: 1
45   size: 10
46
47 =head2 item_level_request
48
49   data_type: 'tinyint'
50   default_value: 0
51   is_nullable: 0
52
53 =cut
54
55 __PACKAGE__->add_columns(
56   "borrowernumber",
57   { data_type => "integer", is_foreign_key => 1, is_nullable => 0 },
58   "biblionumber",
59   { data_type => "integer", is_foreign_key => 1, is_nullable => 0 },
60   "itemnumber",
61   { data_type => "integer", is_foreign_key => 1, is_nullable => 0 },
62   "source_branchcode",
63   { data_type => "varchar", is_foreign_key => 1, is_nullable => 1, size => 10 },
64   "item_level_request",
65   { data_type => "tinyint", default_value => 0, is_nullable => 0 },
66 );
67 __PACKAGE__->set_primary_key("itemnumber");
68
69 =head1 RELATIONS
70
71 =head2 borrowernumber
72
73 Type: belongs_to
74
75 Related object: L<Koha::Schema::Result::Borrower>
76
77 =cut
78
79 __PACKAGE__->belongs_to(
80   "borrowernumber",
81   "Koha::Schema::Result::Borrower",
82   { borrowernumber => "borrowernumber" },
83   { on_delete => "CASCADE", on_update => "CASCADE" },
84 );
85
86 =head2 biblionumber
87
88 Type: belongs_to
89
90 Related object: L<Koha::Schema::Result::Biblio>
91
92 =cut
93
94 __PACKAGE__->belongs_to(
95   "biblionumber",
96   "Koha::Schema::Result::Biblio",
97   { biblionumber => "biblionumber" },
98   { on_delete => "CASCADE", on_update => "CASCADE" },
99 );
100
101 =head2 itemnumber
102
103 Type: belongs_to
104
105 Related object: L<Koha::Schema::Result::Item>
106
107 =cut
108
109 __PACKAGE__->belongs_to(
110   "itemnumber",
111   "Koha::Schema::Result::Item",
112   { itemnumber => "itemnumber" },
113   { on_delete => "CASCADE", on_update => "CASCADE" },
114 );
115
116 =head2 source_branchcode
117
118 Type: belongs_to
119
120 Related object: L<Koha::Schema::Result::Branch>
121
122 =cut
123
124 __PACKAGE__->belongs_to(
125   "source_branchcode",
126   "Koha::Schema::Result::Branch",
127   { branchcode => "source_branchcode" },
128   { join_type => "LEFT", on_delete => "CASCADE", on_update => "CASCADE" },
129 );
130
131
132 # Created by DBIx::Class::Schema::Loader v0.07000 @ 2012-09-02 08:44:15
133 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:/h3AEVRMJgs51+fyRzpLaQ
134
135
136 # You can replace this text with custom content, and it will be preserved on regeneration
137 1;