From e64d05f6a7e905bed5c26eece7cb2331d1bd5354 Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Fri, 29 Aug 2025 17:30:12 -0300 Subject: [PATCH] Bug 39190: Adjust schema to new structure Signed-off-by: Tomas Cohen Arazi --- Koha/File/Transport.pm | 2 +- Koha/File/Transports.pm | 2 +- .../Result/{SftpServer.pm => FileTransport.pm} | 17 ++++++++--------- 3 files changed, 10 insertions(+), 11 deletions(-) rename Koha/Schema/Result/{SftpServer.pm => FileTransport.pm} (88%) diff --git a/Koha/File/Transport.pm b/Koha/File/Transport.pm index cdf17eac4ba..dc4d1cf75ea 100644 --- a/Koha/File/Transport.pm +++ b/Koha/File/Transport.pm @@ -304,7 +304,7 @@ Return type of Object relating to Schema Result =cut sub _type { - return 'SftpServer'; + return 'FileTransport'; } 1; diff --git a/Koha/File/Transports.pm b/Koha/File/Transports.pm index 932a7248696..c27728fcbb9 100644 --- a/Koha/File/Transports.pm +++ b/Koha/File/Transports.pm @@ -40,7 +40,7 @@ Return type of object, relating to Schema ResultSet =cut sub _type { - return 'SftpServer'; + return 'FileTransport'; } =head3 _polymorphic_field diff --git a/Koha/Schema/Result/SftpServer.pm b/Koha/Schema/Result/FileTransport.pm similarity index 88% rename from Koha/Schema/Result/SftpServer.pm rename to Koha/Schema/Result/FileTransport.pm index 75d50be03cd..8705d8ff326 100644 --- a/Koha/Schema/Result/SftpServer.pm +++ b/Koha/Schema/Result/FileTransport.pm @@ -1,12 +1,12 @@ use utf8; -package Koha::Schema::Result::SftpServer; +package Koha::Schema::Result::FileTransport; # Created by DBIx::Class::Schema::Loader # DO NOT MODIFY THE FIRST PART OF THIS FILE =head1 NAME -Koha::Schema::Result::SftpServer +Koha::Schema::Result::FileTransport =cut @@ -15,11 +15,11 @@ use warnings; use base 'DBIx::Class::Core'; -=head1 TABLE: C +=head1 TABLE: C =cut -__PACKAGE__->table("sftp_servers"); +__PACKAGE__->table("file_transports"); =head1 ACCESSORS @@ -96,9 +96,8 @@ __PACKAGE__->table("sftp_servers"); =head2 status - data_type: 'varchar' + data_type: 'longtext' is_nullable: 1 - size: 32 =head2 debug @@ -149,7 +148,7 @@ __PACKAGE__->add_columns( "upload_directory", { data_type => "mediumtext", is_nullable => 1 }, "status", - { data_type => "varchar", is_nullable => 1, size => 32 }, + { data_type => "longtext", is_nullable => 1 }, "debug", { data_type => "tinyint", default_value => 0, is_nullable => 0 }, ); @@ -167,8 +166,8 @@ __PACKAGE__->add_columns( __PACKAGE__->set_primary_key("id"); -# Created by DBIx::Class::Schema::Loader v0.07051 @ 2025-08-29 14:29:49 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Mr3SRG6aRllMJvaltvwgOw +# Created by DBIx::Class::Schema::Loader v0.07051 @ 2025-08-29 20:23:47 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:eeoKreXE9wfz12s4ENo5Tg __PACKAGE__->add_columns( '+passive' => { is_boolean => 1 }, -- 2.51.0