public IHttpActionResult Bill(PrepareInvoiceParams parameters) { try { var invoiceNum = _invoiceService.BillProject(parameters.ProjectId, parameters.InvoiceUserRequests); return(Created(Url.Link("InvoiceDetails", new { invoiceNumber = invoiceNum }), invoiceNum)); } catch (Exception ex) { return(BadRequest(ex.Message)); } }
public List <InvoiceRecalculationResult> Recalculate(PrepareInvoiceParams parameters) { return(_invoiceService.RecalculateInvoiceInfo(parameters.ProjectId, parameters.InvoiceUserRequests)); }