Sha256: cecc5afd47e76ed4cc0d62a84116b04248ad2678a1ffe04cc3a4bf275b281046
Contents?: true
Size: 751 Bytes
Versions: 3
Compression:
Stored size: 751 Bytes
Contents
# frozen_string_literal: true module Decidim module Forms module Admin # Custom helpers for questionnaire answers # module QuestionnaireAnswersHelper def first_table_th(answer) return translated_attribute answer.first_short_answer.question.body if answer.first_short_answer t("session_token", scope: "decidim.forms.user_answers_serializer") end def first_table_td(answer) return answer.first_short_answer.body if answer.first_short_answer answer.session_token end def display_percentage(number) number_to_percentage(number, precision: 0, strip_insignificant_zeros: true, locale: I18n.locale) end end end end end
Version data entries
3 entries across 3 versions & 1 rubygems