public async Task <JsonResult> DeleteAsync(int customerId) { var res = await _apiContext.DeleteRequest("Customers/" + customerId); if (res.Value.ToString() != "200") { Response.StatusCode = 404; return(null); } return(res); }
public async Task <JsonResult> DeleteAsync(int id) { var res = await _apiContext.DeleteRequest("Categories/" + id); if (res.Value.ToString() == "400") { Response.StatusCode = 400; return(new JsonResult("Wystąpił błąd podczas usuwania kategorii")); } else { return(res); } }
public async Task DeleteAsync(int productId) { await _apiContext.DeleteRequest("Products/" + productId); }
public async Task <JsonResult> Delete(int serviceId) { var res = await _apiContext.DeleteRequest("Services/" + serviceId); return(res); }
public async Task DeleteAsync(int id) { await _apiContext.DeleteRequest("Vouchers/" + id); }