Skip to content

Commit

Permalink
feat(analytics): add support for calculated questions
Browse files Browse the repository at this point in the history
  • Loading branch information
open-dynaMIX committed Feb 10, 2023
1 parent 2bccc11 commit 196ab05
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions caluma/caluma_analytics/simple_table.py
Original file line number Diff line number Diff line change
Expand Up @@ -496,6 +496,7 @@ def _question_field(self, question):
question.TYPE_TEXTAREA,
question.TYPE_CHOICE,
question.TYPE_DYNAMIC_CHOICE,
question.TYPE_CALCULATED_FLOAT,
):
return FormAnswerField(
parent=self,
Expand Down Expand Up @@ -570,6 +571,7 @@ def supported_functions(self):
form_models.Question.TYPE_DATE: text_functions,
form_models.Question.TYPE_INTEGER: numeric_functions,
form_models.Question.TYPE_FLOAT: numeric_functions,
form_models.Question.TYPE_CALCULATED_FLOAT: numeric_functions,
}

return base_functions + function_support[self._question.type]
Expand Down

0 comments on commit 196ab05

Please sign in to comment.