View | Details | Raw Unified | Return to bug 15516
Collapse All | Expand All

(-)a/Koha/Schema/Result/HoldGroup.pm (+95 lines)
Line 0 Link Here
1
use utf8;
2
package Koha::Schema::Result::HoldGroup;
3
4
# Created by DBIx::Class::Schema::Loader
5
# DO NOT MODIFY THE FIRST PART OF THIS FILE
6
7
=head1 NAME
8
9
Koha::Schema::Result::HoldGroup
10
11
=cut
12
13
use strict;
14
use warnings;
15
16
use base 'DBIx::Class::Core';
17
18
=head1 TABLE: C<hold_groups>
19
20
=cut
21
22
__PACKAGE__->table("hold_groups");
23
24
=head1 ACCESSORS
25
26
=head2 hold_group_id
27
28
  data_type: 'integer'
29
  extra: {unsigned => 1}
30
  is_auto_increment: 1
31
  is_nullable: 0
32
33
=cut
34
35
__PACKAGE__->add_columns(
36
  "hold_group_id",
37
  {
38
    data_type => "integer",
39
    extra => { unsigned => 1 },
40
    is_auto_increment => 1,
41
    is_nullable => 0,
42
  },
43
);
44
45
=head1 PRIMARY KEY
46
47
=over 4
48
49
=item * L</hold_group_id>
50
51
=back
52
53
=cut
54
55
__PACKAGE__->set_primary_key("hold_group_id");
56
57
=head1 RELATIONS
58
59
=head2 old_reserves
60
61
Type: has_many
62
63
Related object: L<Koha::Schema::Result::OldReserve>
64
65
=cut
66
67
__PACKAGE__->has_many(
68
  "old_reserves",
69
  "Koha::Schema::Result::OldReserve",
70
  { "foreign.hold_group_id" => "self.hold_group_id" },
71
  { cascade_copy => 0, cascade_delete => 0 },
72
);
73
74
=head2 reserves
75
76
Type: has_many
77
78
Related object: L<Koha::Schema::Result::Reserve>
79
80
=cut
81
82
__PACKAGE__->has_many(
83
  "reserves",
84
  "Koha::Schema::Result::Reserve",
85
  { "foreign.hold_group_id" => "self.hold_group_id" },
86
  { cascade_copy => 0, cascade_delete => 0 },
87
);
88
89
90
# Created by DBIx::Class::Schema::Loader v0.07046 @ 2021-03-01 12:31:35
91
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Yyoi3ftG604iVM3A/uY9ew
92
93
94
# You can replace this text with custom code or comments, and it will be preserved on regeneration
95
1;
(-)a/Koha/Schema/Result/OldReserve.pm (-2 / +36 lines)
Lines 207-212 Is the hpld placed at item level Link Here
207
207
208
Is this a non priority hold
208
Is this a non priority hold
209
209
210
=head2 hold_group_id
211
212
  data_type: 'integer'
213
  extra: {unsigned => 1}
214
  is_foreign_key: 1
215
  is_nullable: 1
216
210
=cut
217
=cut
211
218
212
__PACKAGE__->add_columns(
219
__PACKAGE__->add_columns(
Lines 270-275 __PACKAGE__->add_columns( Link Here
270
  { data_type => "tinyint", default_value => 0, is_nullable => 0 },
277
  { data_type => "tinyint", default_value => 0, is_nullable => 0 },
271
  "non_priority",
278
  "non_priority",
272
  { data_type => "tinyint", default_value => 0, is_nullable => 0 },
279
  { data_type => "tinyint", default_value => 0, is_nullable => 0 },
280
  "hold_group_id",
281
  {
282
    data_type => "integer",
283
    extra => { unsigned => 1 },
284
    is_foreign_key => 1,
285
    is_nullable => 1,
286
  },
273
);
287
);
274
288
275
=head1 PRIMARY KEY
289
=head1 PRIMARY KEY
Lines 326-331 __PACKAGE__->belongs_to( Link Here
326
  },
340
  },
327
);
341
);
328
342
343
=head2 hold_group
344
345
Type: belongs_to
346
347
Related object: L<Koha::Schema::Result::HoldGroup>
348
349
=cut
350
351
__PACKAGE__->belongs_to(
352
  "hold_group",
353
  "Koha::Schema::Result::HoldGroup",
354
  { hold_group_id => "hold_group_id" },
355
  {
356
    is_deferrable => 1,
357
    join_type     => "LEFT",
358
    on_delete     => "SET NULL",
359
    on_update     => "CASCADE",
360
  },
361
);
362
329
=head2 itemnumber
363
=head2 itemnumber
330
364
331
Type: belongs_to
365
Type: belongs_to
Lines 367-374 __PACKAGE__->belongs_to( Link Here
367
);
401
);
368
402
369
403
370
# Created by DBIx::Class::Schema::Loader v0.07049 @ 2021-01-21 13:39:29
404
# Created by DBIx::Class::Schema::Loader v0.07046 @ 2021-03-01 12:31:35
371
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:aVQsdX811LswCsWyBqkSbQ
405
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ZhaIUZS8JtmZJCreb1Lk/g
372
406
373
__PACKAGE__->belongs_to(
407
__PACKAGE__->belongs_to(
374
  "item",
408
  "item",
(-)a/Koha/Schema/Result/Reserve.pm (-3 / +36 lines)
Lines 206-211 Is the hpld placed at item level Link Here
206
206
207
Is this a non priority hold
207
Is this a non priority hold
208
208
209
=head2 hold_group_id
210
211
  data_type: 'integer'
212
  extra: {unsigned => 1}
213
  is_foreign_key: 1
214
  is_nullable: 1
215
209
=cut
216
=cut
210
217
211
__PACKAGE__->add_columns(
218
__PACKAGE__->add_columns(
Lines 279-284 __PACKAGE__->add_columns( Link Here
279
  { data_type => "tinyint", default_value => 0, is_nullable => 0 },
286
  { data_type => "tinyint", default_value => 0, is_nullable => 0 },
280
  "non_priority",
287
  "non_priority",
281
  { data_type => "tinyint", default_value => 0, is_nullable => 0 },
288
  { data_type => "tinyint", default_value => 0, is_nullable => 0 },
289
  "hold_group_id",
290
  {
291
    data_type => "integer",
292
    extra => { unsigned => 1 },
293
    is_foreign_key => 1,
294
    is_nullable => 1,
295
  },
282
);
296
);
283
297
284
=head1 PRIMARY KEY
298
=head1 PRIMARY KEY
Lines 380-385 __PACKAGE__->belongs_to( Link Here
380
  },
394
  },
381
);
395
);
382
396
397
=head2 hold_group
398
399
Type: belongs_to
400
401
Related object: L<Koha::Schema::Result::HoldGroup>
402
403
=cut
404
405
__PACKAGE__->belongs_to(
406
  "hold_group",
407
  "Koha::Schema::Result::HoldGroup",
408
  { hold_group_id => "hold_group_id" },
409
  {
410
    is_deferrable => 1,
411
    join_type     => "LEFT",
412
    on_delete     => "SET NULL",
413
    on_update     => "CASCADE",
414
  },
415
);
416
383
=head2 itemnumber
417
=head2 itemnumber
384
418
385
Type: belongs_to
419
Type: belongs_to
Lines 421-428 __PACKAGE__->belongs_to( Link Here
421
);
455
);
422
456
423
457
424
# Created by DBIx::Class::Schema::Loader v0.07049 @ 2021-01-21 13:39:29
458
# Created by DBIx::Class::Schema::Loader v0.07046 @ 2021-03-01 12:31:35
425
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:BlMb2M0MEmFuTiMSSBEseg
459
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:PCfSB1ngg2OLc4jnAcI/pw
426
460
427
__PACKAGE__->belongs_to(
461
__PACKAGE__->belongs_to(
428
  "item",
462
  "item",
429
- 

Return to bug 15516