X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=SL%2FDB%2FMetaSetup%2FSepaExportItem.pm;h=b24588af7552cbddcf49325b71594f6f570fe61c;hb=11aeaa07186197c61dfe610d2a5c981754fd2e9d;hp=cd2152bedba059930dd1b9431db93782ca92c98a;hpb=eb58f1087cd0cab8ba186b5dad150d98ca3ecd2b;p=kivitendo-erp.git diff --git a/SL/DB/MetaSetup/SepaExportItem.pm b/SL/DB/MetaSetup/SepaExportItem.pm index cd2152bed..b24588af7 100644 --- a/SL/DB/MetaSetup/SepaExportItem.pm +++ b/SL/DB/MetaSetup/SepaExportItem.pm @@ -4,52 +4,56 @@ package SL::DB::SepaExportItem; use strict; -use base qw(SL::DB::Object); - -__PACKAGE__->meta->setup( - table => 'sepa_export_items', - - columns => [ - id => { type => 'integer', not_null => 1, sequence => 'id' }, - sepa_export_id => { type => 'integer', not_null => 1 }, - ap_id => { type => 'integer' }, - chart_id => { type => 'integer', not_null => 1 }, - amount => { type => 'numeric', precision => 5, scale => 25 }, - reference => { type => 'varchar', length => 35 }, - requested_execution_date => { type => 'date' }, - executed => { type => 'boolean', default => 'false' }, - execution_date => { type => 'date' }, - our_iban => { type => 'varchar', length => 100 }, - our_bic => { type => 'varchar', length => 100 }, - vc_iban => { type => 'varchar', length => 100 }, - vc_bic => { type => 'varchar', length => 100 }, - end_to_end_id => { type => 'varchar', length => 35 }, - ar_id => { type => 'integer' }, - ], - - primary_key_columns => [ 'id' ], - - foreign_keys => [ - ap => { - class => 'SL::DB::PurchaseInvoice', - key_columns => { ap_id => 'id' }, - }, - - ar => { - class => 'SL::DB::Invoice', - key_columns => { ar_id => 'id' }, - }, - - chart => { - class => 'SL::DB::Chart', - key_columns => { chart_id => 'id' }, - }, - - sepa_export => { - class => 'SL::DB::SepaExport', - key_columns => { sepa_export_id => 'id' }, - }, - ], +use parent qw(SL::DB::Object); + +__PACKAGE__->meta->table('sepa_export_items'); + +__PACKAGE__->meta->columns( + amount => { type => 'numeric', precision => 25, scale => 5 }, + ap_id => { type => 'integer' }, + ar_id => { type => 'integer' }, + chart_id => { type => 'integer', not_null => 1 }, + end_to_end_id => { type => 'varchar', length => 35 }, + executed => { type => 'boolean', default => 'false' }, + execution_date => { type => 'date' }, + id => { type => 'integer', not_null => 1, sequence => 'id' }, + our_bic => { type => 'varchar', length => 100 }, + our_depositor => { type => 'text' }, + our_iban => { type => 'varchar', length => 100 }, + payment_type => { type => 'text', default => 'without_skonto' }, + reference => { type => 'varchar', length => 140 }, + requested_execution_date => { type => 'date' }, + sepa_export_id => { type => 'integer', not_null => 1 }, + skonto_amount => { type => 'numeric', precision => 25, scale => 5 }, + vc_bic => { type => 'varchar', length => 100 }, + vc_depositor => { type => 'text' }, + vc_iban => { type => 'varchar', length => 100 }, + vc_mandate_date_of_signature => { type => 'date' }, + vc_mandator_id => { type => 'text' }, +); + +__PACKAGE__->meta->primary_key_columns([ 'id' ]); + +__PACKAGE__->meta->foreign_keys( + ap => { + class => 'SL::DB::PurchaseInvoice', + key_columns => { ap_id => 'id' }, + }, + + ar => { + class => 'SL::DB::Invoice', + key_columns => { ar_id => 'id' }, + }, + + chart => { + class => 'SL::DB::Chart', + key_columns => { chart_id => 'id' }, + }, + + sepa_export => { + class => 'SL::DB::SepaExport', + key_columns => { sepa_export_id => 'id' }, + }, ); 1;