public IHttpActionResult Put(Commission commission) { var commissionManager = new CommissionManagement(); apiResponse = new ApiResponse(); commissionManager.Update(commission); apiResponse.Data = commission; return(Ok(apiResponse)); }
public IHttpActionResult GetCommission(Commission cedulaJuridicaDeHotel) { var commissionManager = new CommissionManagement(); apiResponse = new ApiResponse(); var commission = commissionManager.getCommission(cedulaJuridicaDeHotel); apiResponse.Data = commission; return(Ok(apiResponse)); }
public IHttpActionResult Post(Commission commission) { try { var commissionManager = new CommissionManagement(); commissionManager.Create(commission); apiResponse = new ApiResponse(); return(Ok(apiResponse)); } catch (Exception e) { return(InternalServerError(e)); } }
public IHttpActionResult Post3(Commission commission) { try { var commissionManager = new CommissionManagement(); var tmpCommission = commissionManager.IsAdminHotelRegistered(commission.Id); apiResponse = new ApiResponse(); apiResponse.Data = tmpCommission; return(Ok(apiResponse)); } catch (Exception e) { return(InternalServerError(e)); } }
public async System.Threading.Tasks.Task <IHttpActionResult> Post2Async(EmailMembership email) { try { var commissionManager = new CommissionManagement(); await commissionManager.Email(email); apiResponse = new ApiResponse(); return(Ok(apiResponse)); } catch (Exception e) { return(InternalServerError(e)); } }