From: Sven Schöling Date: Fri, 22 Oct 2010 12:12:05 +0000 (+0200) Subject: Parts: buchungsgruppen und partsgroup verlinkt. X-Git-Tag: release-2.6.2beta1~92^2~1 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=997c9f2390c5cf472b221b75d55e1c866612219a;p=kivitendo-erp.git Parts: buchungsgruppen und partsgroup verlinkt. --- diff --git a/SL/DB/Part.pm b/SL/DB/Part.pm index 1acd8ef20..ce9738f32 100644 --- a/SL/DB/Part.pm +++ b/SL/DB/Part.pm @@ -18,6 +18,11 @@ __PACKAGE__->meta->add_relationships( class => 'SL::DB::Assembly', column_map => { id => 'id' }, }, + partsgroup => { + type => 'one to one', + class => 'SL::DB::PartsGroup', + column_map => { partsgroup_id => 'id' }, + }, ); __PACKAGE__->meta->initialize; @@ -103,6 +108,11 @@ sub available_units { shift->unit_obj->convertible_units; } +# autogenerated accessor is slightly off... +sub buchungsgruppe { + shift->buchungsgruppen(@_); +} + 1; __END__