예제 #1
0
 public async Task <CreateComplaintVm> Create(CreateComplaintCommand command)
 {
     return(await Mediator.Send(command));
 }
예제 #2
0
        public async Task <ActionResult> CreateComplaint([FromBody] CreateComplaintCommand createComplaintCommand, ApiVersion apiVersion)
        {
            var newComplaintId = await Mediator.Send(createComplaintCommand);

            return(CreatedAtAction(nameof(GetComplaint), new { complaintId = newComplaintId, version = apiVersion.ToString() }, new { id = newComplaintId }));
        }
 public async Task <ActionResult <int> > Create(CreateComplaintCommand command)
 {
     return(await Mediator.Send(command));
 }