public bool ValidateResponse(QuestionTemplate questionTemplate) { bool validate = false; try { _obsService.ValidateResponse(Encounter.Id, Encounter.ClientId, questionTemplate.Id, questionTemplate.GetResponse()); validate = true; questionTemplate.ErrorSummary = string.Empty; } catch (NullReferenceException ex) { } catch (Exception e) { questionTemplate.ErrorSummary = "Response required !"; try { _dialogService.ShowErrorToast(e.Message, 6000); } catch (Exception exception) { } } return(validate); }
public bool ValidateResponse(QuestionTemplate questionTemplate) { bool validate = false; try { _obsService.ValidateResponse(Encounter.Id, Encounter.ClientId, questionTemplate.Id, questionTemplate.GetResponse()); validate = true; questionTemplate.ErrorSummary = string.Empty; } catch (NullReferenceException ex) { } catch (Exception e) { questionTemplate.ErrorSummary = e.Message; } return(validate); }