Пример #1
0
 public override bool Delete(Invoice toDelete)
 {
     try
     {
         toDelete = SimbaToursEastAfricaDbContext.Invoices.SingleOrDefault(p => p.InvoiceId == toDelete.InvoiceId);
         SimbaToursEastAfricaDbContext.Remove(toDelete);
         return(true);
     }
     catch (Exception e)
     {
         return(false);
     }
 }
Пример #2
0
 public override bool Delete(HotelBooking toDelete)
 {
     try
     {
         toDelete = SimbaToursEastAfricaDbContext.HotelBookings.SingleOrDefault(p => p.HotelBookingId == toDelete.HotelBookingId);
         SimbaToursEastAfricaDbContext.Remove(toDelete);
         return(true);
     }
     catch (Exception e)
     {
         return(false);
     }
 }
Пример #3
0
 public override bool Delete(TourClientExtraCharge toDelete)
 {
     try
     {
         toDelete = SimbaToursEastAfricaDbContext.TourClientExtraCharges.SingleOrDefault(p => p.TourClientExtraChargesId == toDelete.TourClientExtraChargesId);
         SimbaToursEastAfricaDbContext.Remove(toDelete);
         return(true);
     }
     catch (Exception e)
     {
         return(false);
     }
 }