X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/kivitendo-erp.git/blobdiff_plain/7ade1b958af3fdd2b7532973da0e7825d23eda96..ada964d139eb652502bbdec96adf8634e49d8872:/SL/DB/MetaSetup/Price.pm diff --git a/SL/DB/MetaSetup/Price.pm b/SL/DB/MetaSetup/Price.pm index bb6f0fd38..d1c35dc8b 100644 --- a/SL/DB/MetaSetup/Price.pm +++ b/SL/DB/MetaSetup/Price.pm @@ -6,29 +6,27 @@ use strict; use base qw(SL::DB::Object); -__PACKAGE__->meta->setup( - table => 'prices', - - columns => [ - parts_id => { type => 'integer' }, - pricegroup_id => { type => 'integer' }, - price => { type => 'numeric', precision => 5, scale => 15 }, - id => { type => 'serial', not_null => 1 }, - ], - - primary_key_columns => [ 'id' ], - - foreign_keys => [ - parts => { - class => 'SL::DB::Part', - key_columns => { parts_id => 'id' }, - }, - - pricegroup => { - class => 'SL::DB::Pricegroup', - key_columns => { pricegroup_id => 'id' }, - }, - ], +__PACKAGE__->meta->table('prices'); + +__PACKAGE__->meta->columns( + id => { type => 'serial', not_null => 1 }, + parts_id => { type => 'integer' }, + price => { type => 'numeric', precision => 5, scale => 15 }, + pricegroup_id => { type => 'integer' }, +); + +__PACKAGE__->meta->primary_key_columns([ 'id' ]); + +__PACKAGE__->meta->foreign_keys( + parts => { + class => 'SL::DB::Part', + key_columns => { parts_id => 'id' }, + }, + + pricegroup => { + class => 'SL::DB::Pricegroup', + key_columns => { pricegroup_id => 'id' }, + }, ); 1;