public ResponseResult <List <String> > Get([FromBody] SymptomReq symptomReq) { ResponseResult <List <String> > result = new ResponseResult <List <String> >(); try { SymtomsService symtomsService = new SymtomsService(); result.Result = symtomsService.GetDiseaseBySymptomIds(symptomReq.Ids); // [{id: 1},{id:2}] } catch (Exception e) { result.IsSuccess = false; result.Message = e.Message; } return(result); }
public ResponseResult <List <Symptoms> > Get() { ResponseResult <List <Symptoms> > result = new ResponseResult <List <Symptoms> >(); try { SymtomsService symtomsService = new SymtomsService(); result.Result = symtomsService.GetSymptoms(); } catch (Exception e) { result.IsSuccess = false; result.Message = e.Message; } return(result); }