示例#1
0
 //**********************************************************
 //* Добавление нового состояния Vm
 //**********************************************************
 public static void AddState(String description)
 {
     using (SandBoxDataContext db = new SandBoxDataContext())
     {
         Int32 maxState = (from s in db.VmStates orderby s.State select s.State).Max();
         VmState vmState = new VmState { State = maxState + 1, Description = description };
         db.VmStates.InsertOnSubmit(vmState);
         db.SubmitChanges();
     }
 }
示例#2
0
 partial void DeleteVmState(VmState instance);
示例#3
0
 partial void UpdateVmState(VmState instance);
示例#4
0
 partial void InsertVmState(VmState instance);
示例#5
0
		private void detach_VmStates(VmState entity)
		{
			this.SendPropertyChanging();
			entity.Vm = null;
		}
示例#6
0
		private void attach_VmStates(VmState entity)
		{
			this.SendPropertyChanging();
			entity.Vm = this;
		}