partial void DeleteSpeaker(Speaker instance);
partial void UpdateSpeaker(Speaker instance);
partial void InsertSpeaker(Speaker instance);
private void detach_Speakers(Speaker entity) { this.SendPropertyChanging(); entity.User = null; }
private void attach_Speakers(Speaker entity) { this.SendPropertyChanging(); entity.User = this; }
public static void Propose(string Email, string SessionTitle, string SessionAbstract) { var ctx = new ICCData(); int eId = Event.GetNextEvent().Id; var session = new Session() { Title = SessionTitle, Abstract = SessionAbstract, EventId = eId }; ctx.Sessions.InsertOnSubmit(session); ctx.SubmitChanges(); var user = ctx.Users.Where(u => string.Compare(u.Email, Email, true) == 0).FirstOrDefault(); Speaker speak = new Speaker() { SessionId = session.Id, UserId = user.Id }; ctx.Speakers.InsertOnSubmit(speak); ctx.SubmitChanges(); }