demo-xf-app-1a/MobileApp1/Services/CorporationService.cs

56 lines
1.2 KiB
C#
Raw Permalink Normal View History

2021-07-13 13:57:44 +00:00
namespace MobileApp1.Services
{
public class CorporationService : ICorporationService
{
public CorporationService()
{
}
public string DisplayName { get; set; } = "";
public bool IsLoggedIn { get; set; } = false;
public string AuthToken { get; set; } = "";
public ServiceResult Login(string username, string password)
{
this.DisplayName = username;
this.IsLoggedIn = true;
return new ServiceResult()
{
IsSuccess = true,
Message = "Logged In"
};
}
public ServiceResult Logout()
{
this.DisplayName = string.Empty;
this.IsLoggedIn = false;
return new ServiceResult()
{
IsSuccess = true,
Message = "Logged Out"
};
}
public ServiceResult RequestPasswordReset(string username)
{
this.DisplayName = string.Empty;
this.IsLoggedIn = false;
return new ServiceResult()
{
IsSuccess = true,
Message = "Password Reset Requested"
};
}
}
}