From fae8ba880e37cf9938daa02dc1db3131ff8da53d Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Tue, 4 Aug 2020 11:44:36 +0000 Subject: [PATCH] DO_NOT_PUSH: DBIx schema changes https://bugs.koha-community.org/show_bug.cgi?id=21066 Signed-off-by: Owen Leonard Signed-off-by: Katrin Fischer --- Koha/Schema/Result/OpacNews.pm | 34 +++++++++++++++++++++------------- 1 file changed, 21 insertions(+), 13 deletions(-) diff --git a/Koha/Schema/Result/OpacNews.pm b/Koha/Schema/Result/OpacNews.pm index ee4bc3b4a6..af61a88901 100644 --- a/Koha/Schema/Result/OpacNews.pm +++ b/Koha/Schema/Result/OpacNews.pm @@ -56,12 +56,11 @@ __PACKAGE__->table("opac_news"); is_nullable: 0 size: 50 -=head2 timestamp +=head2 publicationdate - data_type: 'timestamp' + data_type: 'date' datetime_undef_if_invalid: 1 - default_value: current_timestamp - is_nullable: 0 + is_nullable: 1 =head2 expirationdate @@ -80,6 +79,13 @@ __PACKAGE__->table("opac_news"); is_foreign_key: 1 is_nullable: 1 +=head2 updated_on + + data_type: 'timestamp' + datetime_undef_if_invalid: 1 + default_value: current_timestamp + is_nullable: 0 + =cut __PACKAGE__->add_columns( @@ -98,19 +104,21 @@ __PACKAGE__->add_columns( { data_type => "mediumtext", is_nullable => 0 }, "lang", { data_type => "varchar", default_value => "", is_nullable => 0, size => 50 }, - "timestamp", - { - data_type => "timestamp", - datetime_undef_if_invalid => 1, - default_value => \"current_timestamp", - is_nullable => 0, - }, + "publicationdate", + { data_type => "date", datetime_undef_if_invalid => 1, is_nullable => 1 }, "expirationdate", { data_type => "date", datetime_undef_if_invalid => 1, is_nullable => 1 }, "number", { data_type => "integer", is_nullable => 1 }, "borrowernumber", { data_type => "integer", is_foreign_key => 1, is_nullable => 1 }, + "updated_on", + { + data_type => "timestamp", + datetime_undef_if_invalid => 1, + default_value => \"current_timestamp", + is_nullable => 0, + }, ); =head1 PRIMARY KEY @@ -168,8 +176,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07049 @ 2020-07-23 08:50:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Db/JtTOlAdb+83PKZhbFCQ +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-08-04 13:24:59 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:HWEqEtcR/35q+tPIvTENIw sub koha_object_class { 'Koha::NewsItem'; -- 2.11.0