kivitendo/SL/DB/MetaSetup/Unit.pm @ bc8c26f3
82515b2d | Sven Schöling | # This file has been auto-generated. Do not modify it; it will be overwritten
|
||
# by rose_auto_create_model.pl automatically.
|
||||
package SL::DB::Unit;
|
||||
use strict;
|
||||
use base qw(SL::DB::Object);
|
||||
b8b112a3 | Sven Schöling | __PACKAGE__->meta->table('units');
|
||
__PACKAGE__->meta->columns(
|
||||
base_unit => { type => 'varchar', length => 20 },
|
||||
a3511b2d | Moritz Bunkus | factor => { type => 'numeric', precision => 20, scale => 5 },
|
||
b8b112a3 | Sven Schöling | id => { type => 'serial', not_null => 1 },
|
||
3eb3d1b1 | Moritz Bunkus | name => { type => 'varchar', length => 20, not_null => 1 },
|
||
sortkey => { type => 'integer', not_null => 1 },
|
||||
type => { type => 'varchar', length => 20 },
|
||||
82515b2d | Sven Schöling | );
|
||
b8b112a3 | Sven Schöling | __PACKAGE__->meta->primary_key_columns([ 'name' ]);
|
||
__PACKAGE__->meta->unique_keys([ 'id' ]);
|
||||
__PACKAGE__->meta->foreign_keys(
|
||||
unit => {
|
||||
class => 'SL::DB::Unit',
|
||||
key_columns => { base_unit => 'name' },
|
||||
},
|
||||
);
|
||||
82515b2d | Sven Schöling | 1;
|
||
;
|