Пример #1
0
 public async Task <ActionResult <int> > CreateMedicalSpecialty([FromBody] MedicalSpecialtyModel model)
 {
     //return Created($"{AppConstants.API_URL_PREFIX}/medicalspecialties/", await Mediator.Send(new CreateMedicalSpecialtyCommand { Model = model }));
     return(Ok(await Mediator.Send(new CreateMedicalSpecialtyCommand {
         Model = model
     })));
 }
Пример #2
0
        public async Task <ActionResult> UpdateMedicalSpecialty([FromBody] MedicalSpecialtyModel model)
        {
            await Mediator.Send(new UpdateMedicalSpecialtyCommand { Model = model });

            return(NoContent());
        }