summaryrefslogtreecommitdiff
path: root/LedgerSMB/DBObject/User.pm
diff options
context:
space:
mode:
authoraurynn_cmd <aurynn_cmd@4979c152-3d1c-0410-bac9-87ea11338e46>2008-09-22 21:45:11 +0000
committeraurynn_cmd <aurynn_cmd@4979c152-3d1c-0410-bac9-87ea11338e46>2008-09-22 21:45:11 +0000
commit61ea910a5ba61a7c5eed2d679d1f25c431c449a8 (patch)
treed9fc1f2f34dde7d8d742258671ad66999b2c375a /LedgerSMB/DBObject/User.pm
parent081b2af1a72788c4c3bd9e769d90155ad72e26cb (diff)
Major changes to the Admin interface for Edit User. Minor tweaks to Person, Location and Employee.sql as needed.
git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@2331 4979c152-3d1c-0410-bac9-87ea11338e46
Diffstat (limited to 'LedgerSMB/DBObject/User.pm')
-rw-r--r--LedgerSMB/DBObject/User.pm8
1 files changed, 6 insertions, 2 deletions
diff --git a/LedgerSMB/DBObject/User.pm b/LedgerSMB/DBObject/User.pm
index 18bfca9a..7682acbe 100644
--- a/LedgerSMB/DBObject/User.pm
+++ b/LedgerSMB/DBObject/User.pm
@@ -74,15 +74,19 @@ sub get {
funcname=>'person__list_locations',
args=>[ $self->{user}->{entity_id} ]
);
- $self->{location} = \@loc;
+ $self->{locations} = \@loc;
my @contacts = $self->exec_method(
funcname=>"person__list_contacts",
args=>[$self->{user}->{entity_id} ]
);
+ $self->{contacts} = \@contacts;
my @rolstore;
for my $role (@roles) {
- push @rolstore, $role->{'admin__get_roles_for_user'}; # Only one key=>value pair
+ my $rolname = $role->{'admin__get_roles_for_user'};
+ my $company = $self->{company};
+ $rolname =~ s/lsmb_${company}__//gi;
+ push @rolstore, $rolname; # Only one key=>value pair
}
$self->{roles} = \@rolstore;