// DELETE: api/BookingLight/5 public void Delete(int id) { try { BookingLightDAL.Delete(id); } catch (Exception ex) { throw ex; } }
// POST: api/BookingLight public void Post([FromBody] BookingLight value) { try { BookingLightDAL.Insert(value); } catch (Exception ex) { throw ex; } }
// PUT: api/BookingLight/5 public void Put(string id, [FromBody] BookingLight value) { try { BookingLightDAL.Update(id, value); } catch (Exception ex) { throw ex; } }
// GET: api/BookingLight public IEnumerable <BookingLight> Get() { List <BookingLight> data = null; try { data = BookingLightDAL.GetAll(); } catch (Exception ex) { throw ex; } return(data); }