MetaSetup neu generiert
[kivitendo-erp.git] / SL / DB / MetaSetup / AuthClientUser.pm
index 85d0ef9..88a5177 100644 (file)
@@ -6,29 +6,29 @@ use strict;
 
 use base qw(SL::DB::Object);
 
-__PACKAGE__->meta->setup(
-  table   => 'clients_users',
-  schema  => 'auth',
-
-  columns => [
-    client_id => { type => 'integer', not_null => 1 },
-    user_id   => { type => 'integer', not_null => 1 },
-  ],
-
-  primary_key_columns => [ 'client_id', 'user_id' ],
-
-  foreign_keys => [
-    client => {
-      class       => 'SL::DB::AuthClient',
-      key_columns => { client_id => 'id' },
-    },
-
-    user => {
-      class       => 'SL::DB::AuthUser',
-      key_columns => { user_id => 'id' },
-    },
-  ],
+__PACKAGE__->meta->table('clients_users');
+__PACKAGE__->meta->schema('auth');
+
+__PACKAGE__->meta->columns(
+  client_id => { type => 'integer', not_null => 1 },
+  user_id   => { type => 'integer', not_null => 1 },
+);
+
+__PACKAGE__->meta->primary_key_columns([ 'client_id', 'user_id' ]);
+
+__PACKAGE__->meta->foreign_keys(
+  client => {
+    class       => 'SL::DB::AuthClient',
+    key_columns => { client_id => 'id' },
+  },
+
+  user => {
+    class       => 'SL::DB::AuthUser',
+    key_columns => { user_id => 'id' },
+  },
 );
 
+# __PACKAGE__->meta->initialize;
+
 1;
 ;