X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/614c48e031ff86a158dfea7eeb2bc255d806c972..2065624062cd59d7d21a6e1f39ae433a9668301e:/SL/DB/Employee.pm diff --git a/SL/DB/Employee.pm b/SL/DB/Employee.pm index 8da20c0b9..0c321b62f 100644 --- a/SL/DB/Employee.pm +++ b/SL/DB/Employee.pm @@ -27,4 +27,14 @@ sub safe_name { return $self->name || $self->login; } +sub auth_user { + my ($self) = @_; + + die 'not an accessor' if scalar(@_) > 1; + + require SL::DB::AuthUser; + + return SL::DB::Manager::AuthUser->find_by(login => $self->login); +} + 1;