Beispiel #1
0
        public async Task MarkOutgoingInvoiceAsPaid(MarkOutgoingInvoiceAsPaidModel model)
        {
            var command = new MarkOutgoingInvoiceAsPaidCommand(
                model.UserId,
                model.InvoiceId,
                model.PaymentDate);

            await Bus.Send(command);
        }
Beispiel #2
0
        public async Task <IActionResult> MarkOutgoingInvoiceAsPaid([FromBody] MarkOutgoingInvoiceAsPaidModel model)
        {
            if (!ModelState.IsValid)
            {
                return(BadRequest(ModelState));
            }

            await WorkerServices.MarkOutgoingInvoiceAsPaid(model);

            return(Ok());
        }