public static void DeleteOnSubmit(this DbSet<ShippingMethod> source, ShippingMethod shippingMethod)
 {
     source.Remove(shippingMethod);
 }
 public static void InsertOnSubmit(this DbSet<ShippingMethod> source, ShippingMethod shippingMethod)
 {
     if (shippingMethod.ShippingMethodID == default(int))
     {
         // New entity
         source.Add(shippingMethod);
     }
     else
     {
         // Existing entity
         source.Attach(shippingMethod);
     }
 }