Example #1
0
        public IActionResult GetAllInvoiceTotals()
        {
            var invoices = _repository.GetInvoiceTotals();
            var isEmpty  = !invoices.Any();

            if (isEmpty)
            {
                return(NotFound("No invoices found"));
            }
            return(Ok(invoices));
        }