Bugzilla – Attachment 33331 Details for
Bug 8836
Resurrect Rotating Collections
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 8836: Update DBIx
Bug-8836-Update-DBIx.patch (text/plain), 3.00 KB, created by
Tomás Cohen Arazi (tcohen)
on 2014-11-06 18:30:16 UTC
(
hide
)
Description:
Bug 8836: Update DBIx
Filename:
MIME Type:
Creator:
Tomás Cohen Arazi (tcohen)
Created:
2014-11-06 18:30:16 UTC
Size:
3.00 KB
patch
obsolete
>From c96ab7d19dfe0733f924ba6bb4026c62a53e2a75 Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@gmail.com> >Date: Thu, 6 Nov 2014 15:28:19 -0300 >Subject: [PATCH] Bug 8836: Update DBIx > >Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com> >--- > Koha/Schema/Result/Branch.pm | 19 +++++++++++++++++-- > Koha/Schema/Result/Collection.pm | 34 ++++++++++++++++++++++++++++------ > 2 files changed, 45 insertions(+), 8 deletions(-) > >diff --git a/Koha/Schema/Result/Branch.pm b/Koha/Schema/Result/Branch.pm >index 68a92d9..106123a 100644 >--- a/Koha/Schema/Result/Branch.pm >+++ b/Koha/Schema/Result/Branch.pm >@@ -337,6 +337,21 @@ __PACKAGE__->has_many( > { cascade_copy => 0, cascade_delete => 0 }, > ); > >+=head2 collections >+ >+Type: has_many >+ >+Related object: L<Koha::Schema::Result::Collection> >+ >+=cut >+ >+__PACKAGE__->has_many( >+ "collections", >+ "Koha::Schema::Result::Collection", >+ { "foreign.colBranchcode" => "self.branchcode" }, >+ { cascade_copy => 0, cascade_delete => 0 }, >+); >+ > =head2 course_items > > Type: has_many >@@ -498,8 +513,8 @@ Composing rels: L</branchrelations> -> categorycode > __PACKAGE__->many_to_many("categorycodes", "branchrelations", "categorycode"); > > >-# Created by DBIx::Class::Schema::Loader v0.07039 @ 2014-10-27 10:44:50 >-# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:WRCu1ThkQVx+o7/ECe0j2A >+# Created by DBIx::Class::Schema::Loader v0.07039 @ 2014-11-06 15:26:36 >+# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:CGNPB/MkGLOihDThj43/4A > > > # You can replace this text with custom content, and it will be preserved on regeneration >diff --git a/Koha/Schema/Result/Collection.pm b/Koha/Schema/Result/Collection.pm >index 4f435de..38353ea 100644 >--- a/Koha/Schema/Result/Collection.pm >+++ b/Koha/Schema/Result/Collection.pm >@@ -48,10 +48,9 @@ __PACKAGE__->table("collections"); > > accessor: 'col_branchcode' > data_type: 'varchar' >+ is_foreign_key: 1 > is_nullable: 1 >- size: 4 >- >-branchcode for branch where item should be held. >+ size: 10 > > =cut > >@@ -77,8 +76,9 @@ __PACKAGE__->add_columns( > { > accessor => "col_branchcode", > data_type => "varchar", >+ is_foreign_key => 1, > is_nullable => 1, >- size => 4, >+ size => 10, > }, > ); > >@@ -94,9 +94,31 @@ __PACKAGE__->add_columns( > > __PACKAGE__->set_primary_key("colId"); > >+=head1 RELATIONS >+ >+=head2 col_branchcode >+ >+Type: belongs_to >+ >+Related object: L<Koha::Schema::Result::Branch> >+ >+=cut >+ >+__PACKAGE__->belongs_to( >+ "col_branchcode", >+ "Koha::Schema::Result::Branch", >+ { branchcode => "colBranchcode" }, >+ { >+ is_deferrable => 1, >+ join_type => "LEFT", >+ on_delete => "CASCADE", >+ on_update => "CASCADE", >+ }, >+); >+ > >-# Created by DBIx::Class::Schema::Loader v0.07039 @ 2014-08-18 13:01:05 >-# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:4QFGZYwbv0aj6eXdn7vO9A >+# Created by DBIx::Class::Schema::Loader v0.07039 @ 2014-11-06 15:26:36 >+# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:gb7EYny5ULsZw8rYQQ/hjA > > > # You can replace this text with custom content, and it will be preserved on regeneration >-- >1.9.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 8836
:
12560
|
16746
|
19118
|
19119
|
19337
|
19339
|
21008
|
21009
|
21010
|
21011
|
23966
|
23967
|
23968
|
23969
|
23970
|
23971
|
23976
|
28140
|
28141
|
30838
|
30921
|
31087
|
32361
|
32362
|
32588
|
32589
|
32690
|
32691
|
32693
|
32773
|
32774
|
32973
|
32974
|
32975
|
32976
|
32994
|
32999
|
33000
|
33001
|
33002
|
33045
|
33046
|
33047
|
33048
|
33050
|
33051
|
33058
|
33059
|
33060
|
33061
|
33062
|
33063
|
33064
|
33065
|
33066
|
33068
|
33070
|
33095
|
33096
|
33097
|
33098
|
33099
|
33100
|
33101
|
33102
|
33103
|
33330
| 33331 |
33374