Module: Quby

Defined in:
app/helpers/quby/application_helper.rb,
lib/quby.rb,
lib/quby/engine.rb,
lib/quby/version.rb,
lib/quby/settings.rb,
lib/quby/answers/api.rb,
lib/quby/answers/dsl.rb,
lib/quby/pdf_renderer.rb,
lib/quby/answers/repos.rb,
lib/quby/markdown_parser.rb,
lib/quby/answers/repos/base.rb,
lib/quby/questionnaires/api.rb,
lib/quby/questionnaires/dsl.rb,
lib/quby/questionnaires/repos.rb,
app/helpers/quby/layout_helper.rb,
app/helpers/quby/answers_helper.rb,
lib/quby/answers/entities/score.rb,
lib/quby/answers/entities/answer.rb,
lib/quby/answers/repos/disk_repo.rb,
lib/quby/answers/entities/outcome.rb,
lib/quby/answers/entities/patient.rb,
lib/quby/answers/entities/subscore.rb,
lib/quby/answers/repos/memory_repo.rb,
lib/quby/questionnaires/repos/base.rb,
lib/quby/answers/entities/respondent.rb,
lib/quby/questionnaires/deserializer.rb,
lib/quby/questionnaires/entities/flag.rb,
lib/quby/questionnaires/entities/item.rb,
lib/quby/questionnaires/entities/text.rb,
lib/quby/answers/services/build_answer.rb,
lib/quby/questionnaires/entities/panel.rb,
lib/quby/questionnaires/entities/table.rb,
app/controllers/quby/answers_controller.rb,
lib/quby/questionnaires/entities/fields.rb,
lib/quby/questionnaires/repos/disk_repo.rb,
lib/quby/questionnaires/entities/textvar.rb,
lib/quby/answers/services/updates_answers.rb,
lib/quby/questionnaires/entities/question.rb,
lib/quby/questionnaires/repos/memory_repo.rb,
lib/quby/answers/services/answer_validator.rb,
lib/quby/answers/services/score_calculator.rb,
app/controllers/quby/application_controller.rb,
lib/quby/questionnaires/entities/definition.rb,
lib/quby/questionnaires/entities/validation.rb,
lib/quby/answers/services/answer_validations.rb,
lib/quby/answers/services/outcome_calculation.rb,
lib/quby/answers/services/text_transformation.rb,
lib/quby/questionnaires/entities/score_schema.rb,
lib/quby/answers/services/attribute_calculator.rb,
lib/quby/answers/services/filters_answer_value.rb,
lib/quby/questionnaires/entities/outcome_table.rb,
lib/quby/questionnaires/entities/questionnaire.rb,
lib/quby/questionnaires/repos/bundle_disk_repo.rb,
lib/quby/questionnaires/entities/charting/chart.rb,
lib/quby/questionnaires/entities/charting/charts.rb,
lib/quby/questionnaires/entities/question_option.rb,
lib/quby/questionnaires/entities/subscore_schema.rb,
lib/quby/questionnaires/entities/visibility_rule.rb,
lib/quby/questionnaires/entities/score_calculation.rb,
lib/quby/questionnaires/entities/charting/bar_chart.rb,
lib/quby/questionnaires/entities/charting/plottable.rb,
lib/quby/questionnaires/entities/charting/line_chart.rb,
lib/quby/questionnaires/entities/charting/radar_chart.rb,
lib/quby/questionnaires/entities/charting/overview_chart.rb,
lib/quby/questionnaires/entities/questions/date_question.rb,
lib/quby/questionnaires/entities/questions/text_question.rb,
lib/quby/questionnaires/entities/questions/float_question.rb,
lib/quby/questionnaires/entities/questions/radio_question.rb,
lib/quby/questionnaires/entities/questions/select_question.rb,
lib/quby/questionnaires/entities/questions/string_question.rb,
lib/quby/questionnaires/entities/questions/integer_question.rb,
lib/quby/questionnaires/entities/questions/checkbox_question.rb,
lib/quby/questionnaires/entities/questions/deprecated_question.rb

Overview

rubocop:disable LineLength

Defined Under Namespace

Modules: Answers, AnswersHelper, ApplicationHelper, LayoutHelper, PdfRenderer, Questionnaires, TableBackend, TextTransformation Classes: AnswersController, ApplicationController, ArrayAttributeValidValidator, AttributeValidValidator, BaseError, Engine, HTMLWithPants, InvalidAuthorizationError, InvalidQuestionnaireDefinitionError, MarkdownParser, MissingAuthorizationError, NoServerSideValidationInTestError, Settings, TimestampExpiredError, TimestampValidationError, TokenValidationError, TypeValidator, ValidationError

Constant Summary collapse

VERSION =
"5.3.1"

Class Method Summary collapse

Class Method Details

.answer_repo=(repo) ⇒ Object



31
32
33
34
# File 'lib/quby.rb', line 31

def answer_repo=(repo)
  @answer_repo = repo
  @answers_api = nil
end

.answersObject

Quby public API


49
50
51
# File 'lib/quby.rb', line 49

def answers
  @answers_api ||= Quby::Answers::API.new answer_repo: Quby.send(:answer_repo)
end

.fixtures_pathObject



41
42
43
# File 'lib/quby.rb', line 41

def fixtures_path
  File.expand_path File.join('..', '..', 'spec', 'fixtures'), __FILE__
end

.questionnaire_repo=(repo) ⇒ Object



36
37
38
39
# File 'lib/quby.rb', line 36

def questionnaire_repo=(repo)
  @questionnaire_repo = repo
  @questionnaires_api = nil
end

.questionnairesObject



53
54
55
# File 'lib/quby.rb', line 53

def questionnaires
  @questionnaires_api ||= Quby::Questionnaires::API.new questionnaire_repo: Quby.send(:questionnaire_repo)
end

.show_exceptionsObject

Quby configuration


23
24
25
# File 'lib/quby.rb', line 23

def show_exceptions
  @show_exceptions
end

.show_exceptions=(bool) ⇒ Object



27
28
29
# File 'lib/quby.rb', line 27

def show_exceptions=(bool)
  @show_exceptions = bool
end