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

57 lines
1.3 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;
2022-09-30 17:06:31 +00:00
return ServiceResult.Create(true, "Logged In");
2021-07-13 13:57:44 +00:00
}
public ServiceResult Logout()
{
this.DisplayName = string.Empty;
this.IsLoggedIn = false;
2022-09-30 17:06:31 +00:00
return ServiceResult.Create(true, "Logged Out");
2021-07-13 13:57:44 +00:00
}
public ServiceResult RequestPasswordReset(string username)
{
this.DisplayName = string.Empty;
this.IsLoggedIn = false;
2022-09-30 17:06:31 +00:00
return ServiceResult.Create(true, "Password Reset Requested");
}
public WelcomePackResult RetrieveWelcomePack()
{
System.Threading.Thread.Sleep(1000);
return new WelcomePackResult()
2021-07-13 13:57:44 +00:00
{
IsSuccess = true,
2022-09-30 17:06:31 +00:00
Message = "",
MessagesCount = 0,
NoticesCount = 0
2021-07-13 13:57:44 +00:00
};
}
}
}