public void ChangeCurrentRaider(int raiderID) { currentRaider = rosterController.GetRaiderFromID(raiderID); //Update currentRaiderMonthModel dbController.PostGetRaiderMonthModel((resultGetRaiderMonthModel) => { if (WebResponse.isEqualTo(WebResponse.ERROR_0RESULTS, resultGetRaiderMonthModel)) { print("ERROR, THERE IS NO MONTH CREATED!"); return; } currentRaider.LoadMonthFromDBJson(resultGetRaiderMonthModel); uiController.calendar.UpdateCalendarWithRaiderInformation(); uiController.CloseLogin(); uiController.OpenCalendar(); }, currentRaider.raiderID); }
public void ChangeCurrentRaider(string loginUsername) { currentRaider = rosterController.GetRaiderFromUsername(loginUsername); //Update currentRaiderMonthModel dbController.PostGetRaiderMonthModel((resultGetRaiderMonthModel) => { if (WebResponse.isEqualTo(WebResponse.ERROR_0RESULTS, resultGetRaiderMonthModel)) { //ToDo: WHY THE HELL I'M GETTING THIS WHEN NEW ROSTER IS CREATED?! print("ERROR, THERE IS NO MONTH CREATED!"); return; } currentRaider.LoadMonthFromDBJson(resultGetRaiderMonthModel); uiController.calendar.UpdateCalendarWithRaiderInformation(); uiController.CloseLogin(); uiController.OpenCalendar(); }, currentRaider.raiderID); }