From 40ba02f02d88060cd0f9bf9671855c7189e0a179 Mon Sep 17 00:00:00 2001 From: Victor Grousset/tuxayo Date: Wed, 22 Jul 2020 21:23:00 +0200 Subject: [PATCH] Bug 24986: DBIC Schema files + fix of bug 23081 backport Bug 23081 backported the DBIC changes instead of regenerating the files. Thus the checksum weren't matching because 19.05 also had other changes to the schema so the same changes result in a different checksum. The small changes were manually undone and the DBIC were regenerated. So this commit contains the changes for both patchsets. Signed-off-by: Victor Grousset/tuxayo --- Koha/Schema/Result/Borrower.pm | 99 +++++++++------------------ Koha/Schema/Result/Deletedborrower.pm | 99 +++++++++------------------ Koha/Schema/Result/Deleteditem.pm | 11 ++- Koha/Schema/Result/Item.pm | 11 ++- 4 files changed, 72 insertions(+), 148 deletions(-) diff --git a/Koha/Schema/Result/Borrower.pm b/Koha/Schema/Result/Borrower.pm index 70007115d2..5499a48809 100644 --- a/Koha/Schema/Result/Borrower.pm +++ b/Koha/Schema/Result/Borrower.pm @@ -62,15 +62,13 @@ __PACKAGE__->table("borrowers"); =head2 streetnumber - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 10 =head2 streettype - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 50 =head2 address @@ -94,9 +92,8 @@ __PACKAGE__->table("borrowers"); =head2 zipcode - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 25 =head2 country @@ -115,9 +112,8 @@ __PACKAGE__->table("borrowers"); =head2 mobile - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 50 =head2 fax @@ -137,23 +133,20 @@ __PACKAGE__->table("borrowers"); =head2 B_streetnumber accessor: 'b_streetnumber' - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 10 =head2 B_streettype accessor: 'b_streettype' - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 50 =head2 B_address accessor: 'b_address' - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 100 =head2 B_address2 @@ -176,9 +169,8 @@ __PACKAGE__->table("borrowers"); =head2 B_zipcode accessor: 'b_zipcode' - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 25 =head2 B_country @@ -339,33 +331,28 @@ __PACKAGE__->table("borrowers"); =head2 altcontactfirstname - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 255 =head2 altcontactsurname - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 255 =head2 altcontactaddress1 - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 255 =head2 altcontactaddress2 - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 255 =head2 altcontactaddress3 - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 255 =head2 altcontactstate @@ -374,9 +361,8 @@ __PACKAGE__->table("borrowers"); =head2 altcontactzipcode - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 50 =head2 altcontactcountry @@ -385,9 +371,8 @@ __PACKAGE__->table("borrowers"); =head2 altcontactphone - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 50 =head2 smsalertnumber @@ -475,9 +460,9 @@ __PACKAGE__->add_columns( "initials", { data_type => "mediumtext", is_nullable => 1 }, "streetnumber", - { data_type => "varchar", is_nullable => 1, size => 10 }, + { data_type => "tinytext", is_nullable => 1 }, "streettype", - { data_type => "varchar", is_nullable => 1, size => 50 }, + { data_type => "tinytext", is_nullable => 1 }, "address", { data_type => "longtext", is_nullable => 1 }, "address2", @@ -487,7 +472,7 @@ __PACKAGE__->add_columns( "state", { data_type => "mediumtext", is_nullable => 1 }, "zipcode", - { data_type => "varchar", is_nullable => 1, size => 25 }, + { data_type => "tinytext", is_nullable => 1 }, "country", { data_type => "mediumtext", is_nullable => 1 }, "email", @@ -495,7 +480,7 @@ __PACKAGE__->add_columns( "phone", { data_type => "mediumtext", is_nullable => 1 }, "mobile", - { data_type => "varchar", is_nullable => 1, size => 50 }, + { data_type => "tinytext", is_nullable => 1 }, "fax", { data_type => "longtext", is_nullable => 1 }, "emailpro", @@ -503,26 +488,11 @@ __PACKAGE__->add_columns( "phonepro", { data_type => "mediumtext", is_nullable => 1 }, "B_streetnumber", - { - accessor => "b_streetnumber", - data_type => "varchar", - is_nullable => 1, - size => 10, - }, + { accessor => "b_streetnumber", data_type => "tinytext", is_nullable => 1 }, "B_streettype", - { - accessor => "b_streettype", - data_type => "varchar", - is_nullable => 1, - size => 50, - }, + { accessor => "b_streettype", data_type => "tinytext", is_nullable => 1 }, "B_address", - { - accessor => "b_address", - data_type => "varchar", - is_nullable => 1, - size => 100, - }, + { accessor => "b_address", data_type => "mediumtext", is_nullable => 1 }, "B_address2", { accessor => "b_address2", data_type => "mediumtext", is_nullable => 1 }, "B_city", @@ -530,12 +500,7 @@ __PACKAGE__->add_columns( "B_state", { accessor => "b_state", data_type => "mediumtext", is_nullable => 1 }, "B_zipcode", - { - accessor => "b_zipcode", - data_type => "varchar", - is_nullable => 1, - size => 25, - }, + { accessor => "b_zipcode", data_type => "tinytext", is_nullable => 1 }, "B_country", { accessor => "b_country", data_type => "mediumtext", is_nullable => 1 }, "B_email", @@ -603,23 +568,23 @@ __PACKAGE__->add_columns( "sort2", { data_type => "varchar", is_nullable => 1, size => 80 }, "altcontactfirstname", - { data_type => "varchar", is_nullable => 1, size => 255 }, + { data_type => "mediumtext", is_nullable => 1 }, "altcontactsurname", - { data_type => "varchar", is_nullable => 1, size => 255 }, + { data_type => "mediumtext", is_nullable => 1 }, "altcontactaddress1", - { data_type => "varchar", is_nullable => 1, size => 255 }, + { data_type => "mediumtext", is_nullable => 1 }, "altcontactaddress2", - { data_type => "varchar", is_nullable => 1, size => 255 }, + { data_type => "mediumtext", is_nullable => 1 }, "altcontactaddress3", - { data_type => "varchar", is_nullable => 1, size => 255 }, + { data_type => "mediumtext", is_nullable => 1 }, "altcontactstate", { data_type => "mediumtext", is_nullable => 1 }, "altcontactzipcode", - { data_type => "varchar", is_nullable => 1, size => 50 }, + { data_type => "mediumtext", is_nullable => 1 }, "altcontactcountry", { data_type => "mediumtext", is_nullable => 1 }, "altcontactphone", - { data_type => "varchar", is_nullable => 1, size => 50 }, + { data_type => "mediumtext", is_nullable => 1 }, "smsalertnumber", { data_type => "varchar", is_nullable => 1, size => 50 }, "sms_provider_id", @@ -1529,8 +1494,8 @@ Composing rels: L -> ordernumber __PACKAGE__->many_to_many("ordernumbers", "aqorder_users", "ordernumber"); -# Created by DBIx::Class::Schema::Loader v0.07046 @ 2019-04-25 10:08:38 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:3qd/l8OkObSn8gTKTsHrkA +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-07-22 19:19:25 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:EpBTAOkC0dghJduMNEwUiQ __PACKAGE__->belongs_to( "guarantor", diff --git a/Koha/Schema/Result/Deletedborrower.pm b/Koha/Schema/Result/Deletedborrower.pm index e9c28b1cc5..5518c3b0da 100644 --- a/Koha/Schema/Result/Deletedborrower.pm +++ b/Koha/Schema/Result/Deletedborrower.pm @@ -62,15 +62,13 @@ __PACKAGE__->table("deletedborrowers"); =head2 streetnumber - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 10 =head2 streettype - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 50 =head2 address @@ -94,9 +92,8 @@ __PACKAGE__->table("deletedborrowers"); =head2 zipcode - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 25 =head2 country @@ -115,9 +112,8 @@ __PACKAGE__->table("deletedborrowers"); =head2 mobile - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 50 =head2 fax @@ -137,23 +133,20 @@ __PACKAGE__->table("deletedborrowers"); =head2 B_streetnumber accessor: 'b_streetnumber' - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 10 =head2 B_streettype accessor: 'b_streettype' - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 50 =head2 B_address accessor: 'b_address' - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 100 =head2 B_address2 @@ -176,9 +169,8 @@ __PACKAGE__->table("deletedborrowers"); =head2 B_zipcode accessor: 'b_zipcode' - data_type: 'varchar' + data_type: 'tinytext' is_nullable: 1 - size: 25 =head2 B_country @@ -337,33 +329,28 @@ __PACKAGE__->table("deletedborrowers"); =head2 altcontactfirstname - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 255 =head2 altcontactsurname - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 255 =head2 altcontactaddress1 - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 255 =head2 altcontactaddress2 - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 255 =head2 altcontactaddress3 - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 255 =head2 altcontactstate @@ -372,9 +359,8 @@ __PACKAGE__->table("deletedborrowers"); =head2 altcontactzipcode - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 50 =head2 altcontactcountry @@ -383,9 +369,8 @@ __PACKAGE__->table("deletedborrowers"); =head2 altcontactphone - data_type: 'varchar' + data_type: 'mediumtext' is_nullable: 1 - size: 50 =head2 smsalertnumber @@ -472,9 +457,9 @@ __PACKAGE__->add_columns( "initials", { data_type => "mediumtext", is_nullable => 1 }, "streetnumber", - { data_type => "varchar", is_nullable => 1, size => 10 }, + { data_type => "tinytext", is_nullable => 1 }, "streettype", - { data_type => "varchar", is_nullable => 1, size => 50 }, + { data_type => "tinytext", is_nullable => 1 }, "address", { data_type => "longtext", is_nullable => 1 }, "address2", @@ -484,7 +469,7 @@ __PACKAGE__->add_columns( "state", { data_type => "mediumtext", is_nullable => 1 }, "zipcode", - { data_type => "varchar", is_nullable => 1, size => 25 }, + { data_type => "tinytext", is_nullable => 1 }, "country", { data_type => "mediumtext", is_nullable => 1 }, "email", @@ -492,7 +477,7 @@ __PACKAGE__->add_columns( "phone", { data_type => "mediumtext", is_nullable => 1 }, "mobile", - { data_type => "varchar", is_nullable => 1, size => 50 }, + { data_type => "tinytext", is_nullable => 1 }, "fax", { data_type => "longtext", is_nullable => 1 }, "emailpro", @@ -500,26 +485,11 @@ __PACKAGE__->add_columns( "phonepro", { data_type => "mediumtext", is_nullable => 1 }, "B_streetnumber", - { - accessor => "b_streetnumber", - data_type => "varchar", - is_nullable => 1, - size => 10, - }, + { accessor => "b_streetnumber", data_type => "tinytext", is_nullable => 1 }, "B_streettype", - { - accessor => "b_streettype", - data_type => "varchar", - is_nullable => 1, - size => 50, - }, + { accessor => "b_streettype", data_type => "tinytext", is_nullable => 1 }, "B_address", - { - accessor => "b_address", - data_type => "varchar", - is_nullable => 1, - size => 100, - }, + { accessor => "b_address", data_type => "mediumtext", is_nullable => 1 }, "B_address2", { accessor => "b_address2", data_type => "mediumtext", is_nullable => 1 }, "B_city", @@ -527,12 +497,7 @@ __PACKAGE__->add_columns( "B_state", { accessor => "b_state", data_type => "mediumtext", is_nullable => 1 }, "B_zipcode", - { - accessor => "b_zipcode", - data_type => "varchar", - is_nullable => 1, - size => 25, - }, + { accessor => "b_zipcode", data_type => "tinytext", is_nullable => 1 }, "B_country", { accessor => "b_country", data_type => "mediumtext", is_nullable => 1 }, "B_email", @@ -588,23 +553,23 @@ __PACKAGE__->add_columns( "sort2", { data_type => "varchar", is_nullable => 1, size => 80 }, "altcontactfirstname", - { data_type => "varchar", is_nullable => 1, size => 255 }, + { data_type => "mediumtext", is_nullable => 1 }, "altcontactsurname", - { data_type => "varchar", is_nullable => 1, size => 255 }, + { data_type => "mediumtext", is_nullable => 1 }, "altcontactaddress1", - { data_type => "varchar", is_nullable => 1, size => 255 }, + { data_type => "mediumtext", is_nullable => 1 }, "altcontactaddress2", - { data_type => "varchar", is_nullable => 1, size => 255 }, + { data_type => "mediumtext", is_nullable => 1 }, "altcontactaddress3", - { data_type => "varchar", is_nullable => 1, size => 255 }, + { data_type => "mediumtext", is_nullable => 1 }, "altcontactstate", { data_type => "mediumtext", is_nullable => 1 }, "altcontactzipcode", - { data_type => "varchar", is_nullable => 1, size => 50 }, + { data_type => "mediumtext", is_nullable => 1 }, "altcontactcountry", { data_type => "mediumtext", is_nullable => 1 }, "altcontactphone", - { data_type => "varchar", is_nullable => 1, size => 50 }, + { data_type => "mediumtext", is_nullable => 1 }, "smsalertnumber", { data_type => "varchar", is_nullable => 1, size => 50 }, "sms_provider_id", @@ -649,8 +614,8 @@ __PACKAGE__->add_columns( ); -# Created by DBIx::Class::Schema::Loader v0.07046 @ 2019-04-25 10:08:38 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:hzKeGjtecf3VyEvaBhDmUg +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-07-22 19:19:25 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:29hi9QI9+xTuI+pl16KhgQ # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Koha/Schema/Result/Deleteditem.pm b/Koha/Schema/Result/Deleteditem.pm index ad4d70966e..43d513a8ee 100644 --- a/Koha/Schema/Result/Deleteditem.pm +++ b/Koha/Schema/Result/Deleteditem.pm @@ -156,8 +156,8 @@ __PACKAGE__->table("deleteditems"); =head2 issues data_type: 'smallint' - is_nullable: 0 default_value: 0 + is_nullable: 1 =head2 renewals @@ -342,10 +342,7 @@ __PACKAGE__->add_columns( "coded_location_qualifier", { data_type => "varchar", is_nullable => 1, size => 10 }, "issues", - { data_type => "smallint", - is_nullable => 0, - default_value => 0, - }, + { data_type => "smallint", default_value => 0, is_nullable => 1 }, "renewals", { data_type => "smallint", is_nullable => 1 }, "reserves", @@ -410,8 +407,8 @@ __PACKAGE__->add_columns( __PACKAGE__->set_primary_key("itemnumber"); -# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-03-18 22:07:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:cIWMKg2PVVOrSp1uLtpJbg +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-07-22 19:19:25 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:llTK+rfkEb1xD+BBeYlYmg # You can replace this text with custom content, and it will be preserved on regeneration diff --git a/Koha/Schema/Result/Item.pm b/Koha/Schema/Result/Item.pm index 7ad0876020..c4c63181f9 100644 --- a/Koha/Schema/Result/Item.pm +++ b/Koha/Schema/Result/Item.pm @@ -159,8 +159,8 @@ __PACKAGE__->table("items"); =head2 issues data_type: 'smallint' - is_nullable: 0 default_value: 0 + is_nullable: 1 =head2 renewals @@ -356,10 +356,7 @@ __PACKAGE__->add_columns( "coded_location_qualifier", { data_type => "varchar", is_nullable => 1, size => 10 }, "issues", - { data_type => "smallint", - is_nullable => 0, - default_value => 0, - }, + { data_type => "smallint", default_value => 0, is_nullable => 1 }, "renewals", { data_type => "smallint", is_nullable => 1 }, "reserves", @@ -720,8 +717,8 @@ __PACKAGE__->has_many( ); -# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-03-18 22:07:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ni/Dx4JeBoVK8NwlM3lw5Q +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-07-22 19:19:25 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:gv53TABUmPU/oeRI88Eomg __PACKAGE__->belongs_to( biblioitem => "Koha::Schema::Result::Biblioitem", "biblioitemnumber" ); -- 2.39.5