示例#1
0
 public int InsertCTShipCar(CTShipCar sc)
 {
     CTShipCar ct = db.CTShipCars.SingleOrDefault(n => n.idshipcar == sc.idshipcar && n.idhd == sc.idhd);
     if (ct == null)
     {
         db.CTShipCars.InsertOnSubmit(sc);
         db.SubmitChanges();
         return 1;
     }
     else
     {
         ct.idhd = sc.idhd;
         db.SubmitChanges();
         return 2;
     }
 }
示例#2
0
 partial void DeleteCTShipCar(CTShipCar instance);
示例#3
0
 partial void UpdateCTShipCar(CTShipCar instance);
示例#4
0
 partial void InsertCTShipCar(CTShipCar instance);
示例#5
0
		private void detach_CTShipCars(CTShipCar entity)
		{
			this.SendPropertyChanging();
			entity.ShipCar = null;
		}
示例#6
0
		private void attach_CTShipCars(CTShipCar entity)
		{
			this.SendPropertyChanging();
			entity.ShipCar = this;
		}