예제 #1
0
 public Discipline AddDiscipline(string name, int sportId, int scaleId, string description)
 {
     try
     {
         var d = new Discipline();
         d.Description = description;
         d.Name = name;
         d.ScaleId = scaleId;
         d.SportId = sportId;
         db.Discipline.InsertOnSubmit(d);
         db.SubmitChanges();
         return d;
     }
     catch (Exception e)
     {
         return null;
     }
 }
예제 #2
0
 partial void DeleteDiscipline(Discipline instance);
예제 #3
0
 partial void UpdateDiscipline(Discipline instance);
예제 #4
0
 partial void InsertDiscipline(Discipline instance);
예제 #5
0
		private void detach_Discipline(Discipline entity)
		{
			this.SendPropertyChanging();
			entity.Sports = null;
		}
예제 #6
0
		private void attach_Discipline(Discipline entity)
		{
			this.SendPropertyChanging();
			entity.Sports = this;
		}