Esempio n. 1
0
        public async Task <IActionResult> SubmitOutbreak([FromBody] SubmitOutbreak command)
        {
            await rules
            .RequireSettingInformation()
            .RequireDocumentsWhenAfterActionReportCompleted()
            .RequireModeOfTransmission()
            .RequireHumanSpecimenConfirmation()
            .Apply(command, ModelState);

            if (ModelState.IsValid)
            {
                await service.Execute(command);

                return(Ok());
            }

            return(BadRequest(ModelState));
        }
Esempio n. 2
0
 public async Task Execute(SubmitOutbreak command)
 {
     command.ReviewStatus = OutbreakReviewStatus.Pending;
     await SaveOutbreak(command);
 }