X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=SL%2FDB%2FMetaSetup%2FAuthUserGroup.pm;h=6b470cf6c6fe2d689edfaf7c242840cd0a7c4ca0;hb=766f5705ecb9cd56adfbffd94c871959bb64c6fd;hp=226921f3c236771ba8d5a92da9655faad781a225;hpb=841d44c00aae1166a0721e40dc2f9ffb7b9ac5b5;p=kivitendo-erp.git diff --git a/SL/DB/MetaSetup/AuthUserGroup.pm b/SL/DB/MetaSetup/AuthUserGroup.pm index 226921f3c..6b470cf6c 100644 --- a/SL/DB/MetaSetup/AuthUserGroup.pm +++ b/SL/DB/MetaSetup/AuthUserGroup.pm @@ -6,29 +6,29 @@ use strict; use base qw(SL::DB::Object); -__PACKAGE__->meta->setup( - table => 'user_group', - schema => 'auth', - - columns => [ - user_id => { type => 'integer', not_null => 1 }, - group_id => { type => 'integer', not_null => 1 }, - ], - - primary_key_columns => [ 'user_id', 'group_id' ], - - foreign_keys => [ - group => { - class => 'SL::DB::AuthGroup', - key_columns => { group_id => 'id' }, - }, - - user => { - class => 'SL::DB::AuthUser', - key_columns => { user_id => 'id' }, - }, - ], +__PACKAGE__->meta->table('user_group'); +__PACKAGE__->meta->schema('auth'); + +__PACKAGE__->meta->columns( + user_id => { type => 'integer', not_null => 1 }, + group_id => { type => 'integer', not_null => 1 }, +); + +__PACKAGE__->meta->primary_key_columns([ 'user_id', 'group_id' ]); + +__PACKAGE__->meta->foreign_keys( + group => { + class => 'SL::DB::AuthGroup', + key_columns => { group_id => 'id' }, + }, + + user => { + class => 'SL::DB::AuthUser', + key_columns => { user_id => 'id' }, + }, ); +# __PACKAGE__->meta->initialize; + 1; ;