@@ -, +, @@ --- Koha/Schema/Result/Borrower.pm | 19 +++++++++++++++++-- Koha/Schema/Result/Suggestion.pm | 40 ++++++++++++++++++++++++++++++++++++++-- 2 files changed, 55 insertions(+), 4 deletions(-) --- a/Koha/Schema/Result/Borrower.pm +++ a/Koha/Schema/Result/Borrower.pm @@ -1459,6 +1459,21 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); +=head2 suggestions_lastmodificationbies + +Type: has_many + +Related object: L + +=cut + +__PACKAGE__->has_many( + "suggestions_lastmodificationbies", + "Koha::Schema::Result::Suggestion", + { "foreign.lastmodificationby" => "self.borrowernumber" }, + { cascade_copy => 0, cascade_delete => 0 }, +); + =head2 suggestions_managedbies Type: has_many @@ -1635,8 +1650,8 @@ Composing rels: L -> ordernumber __PACKAGE__->many_to_many("ordernumbers", "aqorder_users", "ordernumber"); -# Created by DBIx::Class::Schema::Loader v0.07046 @ 2019-10-10 14:31:00 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:GjJLIOViIFRm185Yjl9vYA +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2019-11-14 15:44:37 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:k/fQoZD8MLNdsPJXyhlXdw __PACKAGE__->add_columns( '+anonymized' => { is_boolean => 1 }, --- a/Koha/Schema/Result/Suggestion.pm +++ a/Koha/Schema/Result/Suggestion.pm @@ -77,6 +77,18 @@ __PACKAGE__->table("suggestions"); datetime_undef_if_invalid: 1 is_nullable: 1 +=head2 lastmodificationby + + data_type: 'integer' + is_foreign_key: 1 + is_nullable: 1 + +=head2 lastmodificationdate + + data_type: 'date' + datetime_undef_if_invalid: 1 + is_nullable: 1 + =head2 STATUS accessor: 'status' @@ -228,6 +240,10 @@ __PACKAGE__->add_columns( { data_type => "integer", is_foreign_key => 1, is_nullable => 1 }, "rejecteddate", { data_type => "date", datetime_undef_if_invalid => 1, is_nullable => 1 }, + "lastmodificationby", + { data_type => "integer", is_foreign_key => 1, is_nullable => 1 }, + "lastmodificationdate", + { data_type => "date", datetime_undef_if_invalid => 1, is_nullable => 1 }, "STATUS", { accessor => "status", @@ -379,6 +395,26 @@ __PACKAGE__->belongs_to( }, ); +=head2 lastmodificationby + +Type: belongs_to + +Related object: L + +=cut + +__PACKAGE__->belongs_to( + "lastmodificationby", + "Koha::Schema::Result::Borrower", + { borrowernumber => "lastmodificationby" }, + { + is_deferrable => 1, + join_type => "LEFT", + on_delete => "SET NULL", + on_update => "CASCADE", + }, +); + =head2 managedby Type: belongs_to @@ -440,8 +476,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07046 @ 2019-03-11 12:56:41 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:UsG/gxLa0HMMbcpbscV29Q +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2019-11-14 15:44:38 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:qZuiiZgd+ry97OSngYckSA # You can replace this text with custom content, and it will be preserved on regeneration --