public IHttpActionResult UpdateEntity([FromBody] TicketHistoryDTO ticketHistory) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } _ticketHistoryService.Update(ticketHistory); return(StatusCode(HttpStatusCode.NoContent)); }
public TicketHistory Create(TicketHistoryDTO dto) { return(new TicketHistory() { TicketHistoryId = dto.TicketHistoryId, TicketHisDtime = dto.TicketHisDtime, TicketId = dto.TicketId, UserId = dto.UserId, TicketStatusCode = dto.TicketStatusCode }); }
public List <TicketHistoryDTO> GetTicketHistory(TicketHistoryDTO ticketHistoryDTO) { return(new ITCircleDAO.ApplicationDAO().getTicketHistory(ticketHistoryDTO)); }
public IHttpActionResult Post([FromBody] TicketHistoryDTO ticketHistory) { var ticketHistoryAdded = _ticketHistoryService.Add(ticketHistory); return(CreatedAtRoute("DefaultApi", new { id = ticketHistory.TicketHistoryId }, ticketHistoryAdded)); }