Revision 3ced230d
Von Moritz Bunkus vor mehr als 11 Jahren hinzugefügt
SL/DB/AuthClient.pm | ||
---|---|---|
1 |
# This file has been auto-generated only because it didn't exist. |
|
2 |
# Feel free to modify it at will; it will not be overwritten automatically. |
|
3 |
|
|
4 |
package SL::DB::AuthClient; |
|
5 |
|
|
6 |
use strict; |
|
7 |
|
|
8 |
use SL::DB::MetaSetup::AuthClient; |
|
9 |
|
|
10 |
# Creates get_all, get_all_count, get_all_iterator, delete_all and update_all. |
|
11 |
__PACKAGE__->meta->schema('auth'); |
|
12 |
|
|
13 |
__PACKAGE__->meta->make_manager_class; |
|
14 |
|
|
15 |
__PACKAGE__->meta->add_relationship( |
|
16 |
users => { |
|
17 |
type => 'many to many', |
|
18 |
map_class => 'SL::DB::AuthUserGroup', |
|
19 |
map_from => 'client', |
|
20 |
map_to => 'user', |
|
21 |
}, |
|
22 |
groups => { |
|
23 |
type => 'many to many', |
|
24 |
map_class => 'SL::DB::AuthUserGroup', |
|
25 |
map_from => 'client', |
|
26 |
map_to => 'group', |
|
27 |
}, |
|
28 |
); |
|
29 |
|
|
30 |
__PACKAGE__->meta->initialize; |
|
31 |
|
|
32 |
1; |
SL/DB/AuthClientGroup.pm | ||
---|---|---|
1 |
# This file has been auto-generated only because it didn't exist. |
|
2 |
# Feel free to modify it at will; it will not be overwritten automatically. |
|
3 |
|
|
4 |
package SL::DB::AuthClientGroup; |
|
5 |
|
|
6 |
use strict; |
|
7 |
|
|
8 |
use SL::DB::MetaSetup::AuthClientGroup; |
|
9 |
|
|
10 |
# Creates get_all, get_all_count, get_all_iterator, delete_all and update_all. |
|
11 |
__PACKAGE__->meta->schema('auth'); |
|
12 |
|
|
13 |
__PACKAGE__->meta->make_manager_class; |
|
14 |
|
|
15 |
1; |
SL/DB/AuthClientUser.pm | ||
---|---|---|
1 |
# This file has been auto-generated only because it didn't exist. |
|
2 |
# Feel free to modify it at will; it will not be overwritten automatically. |
|
3 |
|
|
4 |
package SL::DB::AuthClientUser; |
|
5 |
|
|
6 |
use strict; |
|
7 |
|
|
8 |
use SL::DB::MetaSetup::AuthClientUser; |
|
9 |
|
|
10 |
# Creates get_all, get_all_count, get_all_iterator, delete_all and update_all. |
|
11 |
__PACKAGE__->meta->schema('auth'); |
|
12 |
|
|
13 |
__PACKAGE__->meta->make_manager_class; |
|
14 |
|
|
15 |
1; |
SL/DB/AuthGroup.pm | ||
---|---|---|
25 | 25 |
class => 'SL::DB::AuthGroupRight', |
26 | 26 |
column_map => { id => 'group_id' }, |
27 | 27 |
}, |
28 |
clients => { |
|
29 |
type => 'many to many', |
|
30 |
map_class => 'SL::DB::AuthClient', |
|
31 |
map_from => 'group', |
|
32 |
map_to => 'client', |
|
33 |
}, |
|
28 | 34 |
); |
29 | 35 |
|
30 | 36 |
__PACKAGE__->meta->initialize; |
SL/DB/AuthUser.pm | ||
---|---|---|
27 | 27 |
class => 'SL::DB::AuthUserConfig', |
28 | 28 |
column_map => { id => 'user_id' }, |
29 | 29 |
}, |
30 |
clients => { |
|
31 |
type => 'many to many', |
|
32 |
map_class => 'SL::DB::AuthClient', |
|
33 |
map_from => 'user', |
|
34 |
map_to => 'client', |
|
35 |
}, |
|
30 | 36 |
); |
31 | 37 |
|
32 | 38 |
__PACKAGE__->meta->initialize; |
SL/DB/Helper/ALL.pm | ||
---|---|---|
5 | 5 |
use SL::DB::AccTransaction; |
6 | 6 |
use SL::DB::Assembly; |
7 | 7 |
use SL::DB::AuditTrail; |
8 |
use SL::DB::AuthClient; |
|
9 |
use SL::DB::AuthClientUser; |
|
10 |
use SL::DB::AuthClientGroup; |
|
8 | 11 |
use SL::DB::AuthGroup; |
9 | 12 |
use SL::DB::AuthGroupRight; |
10 | 13 |
use SL::DB::AuthUser; |
SL/DB/Helper/Mappings.pm | ||
---|---|---|
37 | 37 |
my %lxoffice_package_names = ( |
38 | 38 |
acc_trans => 'acc_transaction', |
39 | 39 |
audittrail => 'audit_trail', |
40 |
auth_group => 'auth_groups', |
|
41 |
auth_group_right => 'auth_group_rights', |
|
42 |
auth_user => 'auth_users', |
|
43 |
auth_user_config => 'auth_user_configs', |
|
44 |
auth_user_group => 'auth_user_groups', |
|
40 |
'auth.clients' => 'auth_client', |
|
41 |
'auth.clients_users' => 'auth_client_user', |
|
42 |
'auth.clients_groups' => 'auth_client_group', |
|
43 |
'auth.group' => 'auth_groups', |
|
44 |
'auth.group_right' => 'auth_group_rights', |
|
45 |
'auth.user' => 'auth_users', |
|
46 |
'auth.user_config' => 'auth_user_configs', |
|
47 |
'auth.user_group' => 'auth_user_groups', |
|
45 | 48 |
ar => 'invoice', |
46 | 49 |
ap => 'purchase_invoice', |
47 | 50 |
background_jobs => 'background_job', |
SL/DB/MetaSetup/AuthClient.pm | ||
---|---|---|
1 |
# This file has been auto-generated. Do not modify it; it will be overwritten |
|
2 |
# by rose_auto_create_model.pl automatically. |
|
3 |
package SL::DB::AuthClient; |
|
4 |
|
|
5 |
use strict; |
|
6 |
|
|
7 |
use base qw(SL::DB::Object); |
|
8 |
|
|
9 |
__PACKAGE__->meta->setup( |
|
10 |
table => 'clients', |
|
11 |
|
|
12 |
columns => [ |
|
13 |
id => { type => 'serial', not_null => 1 }, |
|
14 |
name => { type => 'text', not_null => 1 }, |
|
15 |
dbhost => { type => 'text', not_null => 1 }, |
|
16 |
dbport => { type => 'integer', default => 5432, not_null => 1 }, |
|
17 |
dbname => { type => 'text', not_null => 1 }, |
|
18 |
dbuser => { type => 'text', not_null => 1 }, |
|
19 |
dbpasswd => { type => 'text', not_null => 1 }, |
|
20 |
is_default => { type => 'boolean', default => 'false', not_null => 1 }, |
|
21 |
], |
|
22 |
|
|
23 |
primary_key_columns => [ 'id' ], |
|
24 |
|
|
25 |
unique_keys => [ |
|
26 |
[ 'dbhost', 'dbport', 'dbname' ], |
|
27 |
[ 'name' ], |
|
28 |
], |
|
29 |
); |
|
30 |
|
|
31 |
1; |
|
32 |
; |
SL/DB/MetaSetup/AuthClientGroup.pm | ||
---|---|---|
1 |
# This file has been auto-generated. Do not modify it; it will be overwritten |
|
2 |
# by rose_auto_create_model.pl automatically. |
|
3 |
package SL::DB::AuthClientGroup; |
|
4 |
|
|
5 |
use strict; |
|
6 |
|
|
7 |
use base qw(SL::DB::Object); |
|
8 |
|
|
9 |
__PACKAGE__->meta->setup( |
|
10 |
table => 'clients_groups', |
|
11 |
|
|
12 |
columns => [ |
|
13 |
client_id => { type => 'integer', not_null => 1 }, |
|
14 |
group_id => { type => 'integer', not_null => 1 }, |
|
15 |
], |
|
16 |
|
|
17 |
primary_key_columns => [ 'client_id', 'group_id' ], |
|
18 |
|
|
19 |
foreign_keys => [ |
|
20 |
client => { |
|
21 |
class => 'SL::DB::AuthClient', |
|
22 |
key_columns => { client_id => 'id' }, |
|
23 |
}, |
|
24 |
|
|
25 |
group => { |
|
26 |
class => 'SL::DB::AuthGroup', |
|
27 |
key_columns => { group_id => 'id' }, |
|
28 |
}, |
|
29 |
], |
|
30 |
); |
|
31 |
|
|
32 |
1; |
|
33 |
; |
SL/DB/MetaSetup/AuthClientUser.pm | ||
---|---|---|
1 |
# This file has been auto-generated. Do not modify it; it will be overwritten |
|
2 |
# by rose_auto_create_model.pl automatically. |
|
3 |
package SL::DB::AuthClientUser; |
|
4 |
|
|
5 |
use strict; |
|
6 |
|
|
7 |
use base qw(SL::DB::Object); |
|
8 |
|
|
9 |
__PACKAGE__->meta->setup( |
|
10 |
table => 'clients_users', |
|
11 |
|
|
12 |
columns => [ |
|
13 |
client_id => { type => 'integer', not_null => 1 }, |
|
14 |
user_id => { type => 'integer', not_null => 1 }, |
|
15 |
], |
|
16 |
|
|
17 |
primary_key_columns => [ 'client_id', 'user_id' ], |
|
18 |
|
|
19 |
foreign_keys => [ |
|
20 |
client => { |
|
21 |
class => 'SL::DB::AuthClient', |
|
22 |
key_columns => { client_id => 'id' }, |
|
23 |
}, |
|
24 |
|
|
25 |
user => { |
|
26 |
class => 'SL::DB::AuthUser', |
|
27 |
key_columns => { user_id => 'id' }, |
|
28 |
}, |
|
29 |
], |
|
30 |
); |
|
31 |
|
|
32 |
1; |
|
33 |
; |
Auch abrufbar als: Unified diff
Rose-Models für Mandantentabellen