public static async void UpdateUserPresentationData() { if (UserPresentationData == default(UserPresentationData)) { UserPresentationData = new UserPresentationData(); } UserData = (await RestApi.GetCurrentUserData()).data; UserPresentationData.Update(UserData.fullname, UserData.email); }
public static async void Logout() { await RestApi.Logout(); RestApi = new RestApi(); UserData = new UserDataToggl(); UserPresentationData = new UserPresentationData(); ActualRunningTaskData = new TaskPresentationLayout(); Workspaces = new List <WorkspaceToggl>(); Projects = new List <ProjectToggl>(); TimeEntries = new List <TimeEntries>(); RunningTask = new TimeEntries(); History = new List <HistoryRowPresentationData>(); }
public static async void UpdateUserDataToServer() { UserData = (await RestApi.UpdateUserData(UserPresentationData.FullName, UserPresentationData.Email)).data; UserPresentationData.Update(UserData.fullname, UserData.email); }