public HttpResponseMessage GetSupplierFuelsPricesByAdmin(int adminId) { ItemsResponse <SupplierFuelsPrices> response = new ItemsResponse <SupplierFuelsPrices>(); response.Items = SupplierFuelsPricesService.GetSupplierFuelsPricesByAdminClientID(adminId); return(Request.CreateResponse(response)); }
public HttpResponseMessage DeleteSupplierFuelsPrice(int adminId, int supplierId) { SuccessResponse response = new SuccessResponse(); SupplierFuelsPricesService.DeleteSupplierFuelsPrice(adminId, supplierId); return(Request.CreateResponse(response)); }
public HttpResponseMessage GetListOfSupplierFuelsPrices() { ItemsResponse <SupplierFuelsPrices> response = new ItemsResponse <SupplierFuelsPrices>(); response.Items = SupplierFuelsPricesService.GetListOfSupplierFuelsPrices(); return(Request.CreateResponse(response)); }
public HttpResponseMessage GetSupplierFuelsPrice(int id) { ItemResponse <SupplierFuelsPrices> response = new ItemResponse <SupplierFuelsPrices>(); response.Item = SupplierFuelsPricesService.GetSupplierFuelsPrice(id); return(Request.CreateResponse(response)); }
public HttpResponseMessage GetSupplierFuelPricesByICAO(int adminId, string icao) { ItemsResponse <SupplierFuelsPrices> response = new ItemsResponse <SupplierFuelsPrices>(); response.Items = SupplierFuelsPricesService.GetSupplierFuelsPricesByICAO(adminId, icao); return(Request.CreateResponse(response)); }
public HttpResponseMessage UpdateSupplierFuelsPrice(UpdateSupplierFuelsPriceRequest model) { if (!ModelState.IsValid) { return(Request.CreateErrorResponse(HttpStatusCode.BadRequest, ModelState)); } SuccessResponse response = new SuccessResponse(); SupplierFuelsPricesService.UpdateSupplierFuelsPrice(model); return(Request.CreateResponse(response)); }
public HttpResponseMessage AddSupplierFuelsPrice(AddSupplierFuelsPriceRequest model) { if (!ModelState.IsValid) { return(Request.CreateErrorResponse(HttpStatusCode.BadRequest, ModelState)); } ItemResponse <int> response = new ItemResponse <int>(); response.Item = SupplierFuelsPricesService.UpdateSupplierFuelsPrice(model); return(Request.CreateResponse(response)); }