//********************************************************** //* Добавление новой Vm //********************************************************** public static void AddVm(String name, Int32 type, Int32 system, Int32 userId, Int32 envType, String description = "null") { using (SandBoxDataContext db = new SandBoxDataContext()) { Vm vm = new Vm { Name = name, Type = type, System = system, State = 1, CreatedBy = userId, CreatedDate = DateTime.Now, EnvId = 0, EnvType = envType, EnvMac = "null", EnvIp = "null", Description = description }; db.Vms.InsertOnSubmit(vm); db.SubmitChanges(); } //TableUpdated(Table.VMS); }
partial void UpdateVm(Vm instance);
partial void DeleteVm(Vm instance);
partial void InsertVm(Vm instance);