public IActionResult Post([FromBody] Patient value)
        {
            try
            {
                _patientService.AddOrUpdate(value);
                Mess mess = new Mess {
                    val1 = "aa", val2 = "bb", val3 = "cc", val4 = "dd"
                };

                _dashboardHostedService.DoWork(mess);
                return(Ok());
            }
            catch (Exception)
            {
                return(BadRequest());
            }
        }
Ejemplo n.º 2
0
        public void AddOrUpdate(PatientRequestDTO entity)
        {
            var addCommand = _mapper.Map <Patient>(entity);

            _patientService.AddOrUpdate(addCommand);
        }