public function getUserByLogin(string $login)
    {
        $retval = null;

        if (strlen($login) > 0) {
            $nb_user = CNabuUser::findByLogin($this, $login);
            if ($nb_user instanceof CNabuUser && $nb_user->validateCustomer($this)) {
                $nb_user->setCustomer($this);
                $retval = $nb_user;
            }
        }

        return $retval;
    }
public function getUserByLogin(string $login)
    {
        $retval = null;

        if (strlen($login) > 0) {
            $nb_user = CNabuUser::findByLogin($this, $login);
            if ($nb_user instanceof CNabuUser && $nb_user->validateCustomer($this)) {
                $nb_user->setCustomer($this);
                $retval = $nb_user;
            }
        }

        return $retval;
    }
public function getUserByLogin ( string $ login ) { $ retval = null ; if ( strlen ( $ login ) > 0 ) { $ nb_user = CNabuUser :: findByLogin ( $ this , $ login ) ; if ( $ nb_user instanceof CNabuUser && $ nb_user -> validateCustomer ( $ this ) ) { $ nb_user -> setCustomer ( $ this ) ; $ retval = $ nb_user ; } } return $ retval ; }
Get a User instance owned by this Customer and identified by his login attribute.
@param string $login A login string to looking for.
@return CNabuUser|null Returns a User instance if found or null if not.
Get a User instance owned by this Customer and identified by his login attribute .