public function login() {

        if( $this->validate() ) {

			$user = $this->getUser();

			$user->lastLoginAt = DateUtil::getDateTime();

			$user->save();

            return Yii::$app->user->login( $user, false );
        }

		return false;
    }
public function login() {

        if( $this->validate() ) {

			$user = $this->getUser();

			$user->lastLoginAt = DateUtil::getDateTime();

			$user->save();

            return Yii::$app->user->login( $user, false );
        }

		return false;
    }
public function login ( ) { if ( $ this -> validate ( ) ) { $ user = $ this -> getUser ( ) ; $ user -> lastLoginAt = DateUtil :: getDateTime ( ) ; $ user -> save ( ) ; return Yii :: $ app -> user -> login ( $ user , false ) ; } return false ; }
Logs in the user.

@return boolean
Logs in the user .