Changeset 465
- Timestamp:
- 10/03/09 03:26:10 (15 years ago)
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
LATMOS-Accounts-Web/lib/LATMOS/Accounts/Web/Model/AttrForms.pm
r464 r465 32 32 postalCode => [ 'Code postal' ], 33 33 postOfficeBox => [ 'BP' ], 34 department => [ 'Département' , 'select-N:group'],34 department => [ 'Département' ], 35 35 streetAddress => [ 'Rue', 'textarea' ], 36 36 title => [ 'Fonction' ], -
LATMOS-Accounts/lib/LATMOS/Accounts/Bases/Sql/User.pm
r464 r465 78 78 directReports => 'directReports', 79 79 managedObjects => 'managedObjects', 80 department => 'department', 80 81 otheraddress => 'otheraddress', 81 82 mainaddress => 'mainaddress', … … 136 137 } 137 138 return \@res; 139 } elsif ($field eq 'department') { 140 my $sth = $self->db->prepare_cached( 141 q{ 142 select name from "group" join 143 group_attributes on "group".ikey = group_attributes.okey 144 where okey in (select okey from group_attributes_users where value = ?) 145 and attr = ? and value = ? 146 } 147 ); 148 $sth->execute($self->id, 'sutype', 'dpmt'); 149 my @res; 150 while (my $res = $sth->fetchrow_hashref) { 151 push(@res, $res->{name}); 152 } 153 return join(',', @res); 138 154 } elsif ($field eq 'managedObjects') { 139 155 my $sth = $self->db->prepare_cached(
Note: See TracChangeset
for help on using the changeset viewer.