public void RemoveFromWaitingList(int memberID, string movieID) { Member me = this.GetMember_MemberID(memberID); Movie mo = this.GetMovie_MovieID(movieID); if (me != null && mo != null) { WaitingList wa = this.GetWaitObject(memberID, movieID); if (wa != null) { this.videoDB.WaitingLists.DeleteOnSubmit(wa); this.videoDB.SubmitChanges(); } } }
public void AddToWaitingList(int memberID, string movieID, DateTime timeNow) { Member me = this.GetMember_MemberID(memberID); Movie mo = this.GetMovie_MovieID(movieID); if (me != null && movieID != null && timeNow != default(DateTime)) { WaitingList wa = this.GetWaitObject(memberID, movieID); if (wa == null) { this.videoDB.WaitingLists.InsertOnSubmit(new WaitingList { MemberID = memberID, MovieID = movieID, WaitDate = timeNow }); this.videoDB.SubmitChanges(); } } }