X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;ds=sidebyside;f=SL%2FDB%2FOrder.pm;h=864da21efc69519fff007b6aa055bf7437e37555;hb=cf085911ff3fd52515487d5adb55b04082593539;hp=d71caae9aa855d616712d371cf34ab5ea89fabad;hpb=14a3e368263875c060e62202acb5e8d39ca0458d;p=kivitendo-erp.git diff --git a/SL/DB/Order.pm b/SL/DB/Order.pm index d71caae9a..864da21ef 100644 --- a/SL/DB/Order.pm +++ b/SL/DB/Order.pm @@ -1,5 +1,6 @@ package SL::DB::Order; +use utf8; use strict; use SL::RecordLinks; @@ -8,10 +9,6 @@ use SL::DB::MetaSetup::Order; use SL::DB::Manager::Order; use SL::DB::Invoice; -__PACKAGE__->attr_number($_, places => -2) for qw(amount netamount marge_total marge_percent); -__PACKAGE__->attr_date($_) for qw(transdate reqdate); -__PACKAGE__->attr_percent($_) for qw(marge_percent); - __PACKAGE__->meta->add_relationship( orderitems => { type => 'one to many', @@ -20,13 +17,25 @@ __PACKAGE__->meta->add_relationship( manager_args => { with_objects => [ 'part' ] } - } + }, + periodic_invoices_config => { + type => 'one to one', + class => 'SL::DB::PeriodicInvoicesConfig', + column_map => { id => 'oe_id' }, + }, + periodic_invoices => { + type => 'one to many', + class => 'SL::DB::PeriodicInvoice', + column_map => { id => 'oe_id' }, + }, ); __PACKAGE__->meta->initialize; # methods +sub items { goto &orderitems; } + sub type { my $self = shift; @@ -102,6 +111,6 @@ Nothing here yet. =head1 AUTHOR - Sven Schöling +Sven Schöling =cut