public static void AddAvailability(string day, string daytime, int userid) { //Call Availability class to add Availability av = new Availability(userid, day, daytime); av.Add(); }
public static void RemoveAvailability(string day, string daytime, int userid) { //Call Availability class to remove Availability av = new Availability(userid, day, daytime); av.Remove(); }
/// <summary> /// Removes availability from the main user /// </summary> /// <param name="av">The details of the availability</param> /// <param name="message">The message of the error</param> /// <returns>Success</returns> public bool RemoveAvailability(Availabilitydetails av, out string message) { Availability a = new Availability(MainUser.ID, av.Day, av.Daytime); a.Remove(); message = "Availability added"; return true; }