Example #1
0
        public IHttpActionResult Post(Guid id, CompletePreparationCommand cmd)
        {
            try
            {
                var command = new CompleteOrder(id, cmd.Version);
                handler.Handle(command);

                return Ok();
            }
            catch (AggregateNotFoundException)
            {
                return NotFound();
            }
            catch (AggregateDeletedException)
            {
                return Conflict();
            }
        }