From f5267bae7eaef86a87696df6440476e9256ef435 Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Wed, 7 Apr 2021 14:56:12 +0200 Subject: [PATCH] Bug 14233: DBIC schema changes Signed-off-by: Martin Renvoize Signed-off-by: Jonathan Druart --- Koha/Schema/Result/Letter.pm | 33 ++++++++++++++++++++++++++++++--- 1 file changed, 30 insertions(+), 3 deletions(-) diff --git a/Koha/Schema/Result/Letter.pm b/Koha/Schema/Result/Letter.pm index 62a0d65eaa..613c4d9b27 100644 --- a/Koha/Schema/Result/Letter.pm +++ b/Koha/Schema/Result/Letter.pm @@ -23,6 +23,14 @@ __PACKAGE__->table("letter"); =head1 ACCESSORS +=head2 id + + data_type: 'integer' + is_auto_increment: 1 + is_nullable: 0 + +primary key identifier + =head2 module data_type: 'varchar' @@ -114,6 +122,8 @@ last modification =cut __PACKAGE__->add_columns( + "id", + { data_type => "integer", is_auto_increment => 1, is_nullable => 0 }, "module", { data_type => "varchar", default_value => "", is_nullable => 0, size => 20 }, "code", @@ -156,6 +166,20 @@ __PACKAGE__->add_columns( =over 4 +=item * L + +=back + +=cut + +__PACKAGE__->set_primary_key("id"); + +=head1 UNIQUE CONSTRAINTS + +=head2 C + +=over 4 + =item * L =item * L @@ -170,7 +194,10 @@ __PACKAGE__->add_columns( =cut -__PACKAGE__->set_primary_key("module", "code", "branchcode", "message_transport_type", "lang"); +__PACKAGE__->add_unique_constraint( + "letter_uniq_1", + ["module", "code", "branchcode", "message_transport_type", "lang"], +); =head1 RELATIONS @@ -190,8 +217,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07049 @ 2021-01-21 13:39:29 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:KsiHfYDT9WzuiTET1Y/BhA +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2021-02-11 12:33:50 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:qqdTVEicMu5rHppY5qsEuA sub koha_object_class { 'Koha::Notice::Template';