From 1024d23887639c9c6304ddc540392d08b7904fd9 Mon Sep 17 00:00:00 2001 From: Josef Moravec Date: Mon, 25 Jun 2018 08:32:55 +0000 Subject: [PATCH] Bug 17705: Update Schema --- Koha/Schema/Result/Accountline.pm | 19 ++++- Koha/Schema/Result/PosTerminalTransaction.pm | 111 +++++++++++++++++++++++++++ 2 files changed, 128 insertions(+), 2 deletions(-) create mode 100644 Koha/Schema/Result/PosTerminalTransaction.pm diff --git a/Koha/Schema/Result/Accountline.pm b/Koha/Schema/Result/Accountline.pm index 1af530c..95551b3 100644 --- a/Koha/Schema/Result/Accountline.pm +++ b/Koha/Schema/Result/Accountline.pm @@ -242,9 +242,24 @@ __PACKAGE__->belongs_to( }, ); +=head2 pos_terminal_transactions -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2018-04-19 12:18:02 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:FUX/e/s202yrUtP3c13lfw +Type: has_many + +Related object: L + +=cut + +__PACKAGE__->has_many( + "pos_terminal_transactions", + "Koha::Schema::Result::PosTerminalTransaction", + { "foreign.accountlines_id" => "self.accountlines_id" }, + { cascade_copy => 0, cascade_delete => 0 }, +); + + +# Created by DBIx::Class::Schema::Loader v0.07042 @ 2018-06-25 08:26:01 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:9d9xV01mRkjqCYkJXQwt1g # You can replace this text with custom content, and it will be preserved on regeneration diff --git a/Koha/Schema/Result/PosTerminalTransaction.pm b/Koha/Schema/Result/PosTerminalTransaction.pm new file mode 100644 index 0000000..8d4d5a4 --- /dev/null +++ b/Koha/Schema/Result/PosTerminalTransaction.pm @@ -0,0 +1,111 @@ +use utf8; +package Koha::Schema::Result::PosTerminalTransaction; + +# Created by DBIx::Class::Schema::Loader +# DO NOT MODIFY THE FIRST PART OF THIS FILE + +=head1 NAME + +Koha::Schema::Result::PosTerminalTransaction + +=cut + +use strict; +use warnings; + +use base 'DBIx::Class::Core'; + +=head1 TABLE: C + +=cut + +__PACKAGE__->table("pos_terminal_transactions"); + +=head1 ACCESSORS + +=head2 id + + data_type: 'integer' + is_auto_increment: 1 + is_nullable: 0 + +=head2 accountlines_id + + data_type: 'integer' + is_foreign_key: 1 + is_nullable: 0 + +=head2 status + + data_type: 'varchar' + default_value: 'new' + is_nullable: 0 + size: 32 + +=head2 response_code + + data_type: 'varchar' + is_nullable: 1 + size: 5 + +=head2 message_log + + data_type: 'text' + is_nullable: 1 + +=cut + +__PACKAGE__->add_columns( + "id", + { data_type => "integer", is_auto_increment => 1, is_nullable => 0 }, + "accountlines_id", + { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, + "status", + { + data_type => "varchar", + default_value => "new", + is_nullable => 0, + size => 32, + }, + "response_code", + { data_type => "varchar", is_nullable => 1, size => 5 }, + "message_log", + { data_type => "text", is_nullable => 1 }, +); + +=head1 PRIMARY KEY + +=over 4 + +=item * L + +=back + +=cut + +__PACKAGE__->set_primary_key("id"); + +=head1 RELATIONS + +=head2 accountline + +Type: belongs_to + +Related object: L + +=cut + +__PACKAGE__->belongs_to( + "accountline", + "Koha::Schema::Result::Accountline", + { accountlines_id => "accountlines_id" }, + { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, +); + + +# Created by DBIx::Class::Schema::Loader v0.07042 @ 2018-06-25 08:26:01 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:RHIh885cy/PU13oaA+0t9g + + +# You can replace this text with custom code or comments, and it will be preserved on regeneration +1; -- 2.1.4