Пример #1
0
 public int AddCarModel(int carBrandId, string name)
 {
     CarModel newCarModel = new CarModel
     {
         CarBrandId = carBrandId,
         Name = name
     };
     db.CarModels.InsertOnSubmit(newCarModel);
     Save();
     return newCarModel.Id;
 }
Пример #2
0
 partial void DeleteCarModel(CarModel instance);
Пример #3
0
 partial void UpdateCarModel(CarModel instance);
Пример #4
0
 partial void InsertCarModel(CarModel instance);
Пример #5
0
		private void detach_CarModels(CarModel entity)
		{
			this.SendPropertyChanging();
			entity.CarBrand = null;
		}
Пример #6
0
		private void attach_CarModels(CarModel entity)
		{
			this.SendPropertyChanging();
			entity.CarBrand = this;
		}