Пример #1
0
    public async Task <ActionResult> Login(string username, string password)
    {
        var response = await writer.UsersAuthentificationLogin(username, Cryptography.Base64Encode(password));

        if (response.IsSuccess)
        {
            this.SignInUser(username, false);

            if (response.IsSuccess == true)
            {
                return(RedirectToAction("Index", "Dashboard", new { @isLoggin = true }));
            }
        }


        return(RedirectToAction("signin", "Home", new { @status = AuthStatus.Status(AuthStatusType.LoginFailed) }));
    }