Module: ComplaintsHelper
- Defined in:
- /var/apps/qpixel/app/helpers/complaints_helper.rb
Instance Method Summary collapse
- #content_type(key) ⇒ Object
- #content_types ⇒ Object
- #content_types_select_options ⇒ Object
- #enabled_report_types ⇒ Object
- #outcome(key) ⇒ Object
- #outcomes_select_options ⇒ Object
- #report_type(key) ⇒ Object
- #report_types ⇒ Object
- #report_types_select_options ⇒ Object
- #status(key) ⇒ Object
- #statuses ⇒ Object
- #statuses_select_options ⇒ Object
Instance Method Details
#content_type(key) ⇒ Object
6 7 8 |
# File '/var/apps/qpixel/app/helpers/complaints_helper.rb', line 6 def content_type(key) value_for('content_types', key) end |
#content_types ⇒ Object
2 3 4 |
# File '/var/apps/qpixel/app/helpers/complaints_helper.rb', line 2 def content_types value_for('content_types') || [] end |
#content_types_select_options ⇒ Object
10 11 12 |
# File '/var/apps/qpixel/app/helpers/complaints_helper.rb', line 10 def ('content_types') end |
#enabled_report_types ⇒ Object
34 35 36 |
# File '/var/apps/qpixel/app/helpers/complaints_helper.rb', line 34 def enabled_report_types report_types.select { |_k, t| t['enabled'] } end |
#outcome(key) ⇒ Object
18 19 20 |
# File '/var/apps/qpixel/app/helpers/complaints_helper.rb', line 18 def outcome(key) value_for('outcomes', key) end |
#outcomes_select_options ⇒ Object
14 15 16 |
# File '/var/apps/qpixel/app/helpers/complaints_helper.rb', line 14 def ('outcomes') end |
#report_type(key) ⇒ Object
30 31 32 |
# File '/var/apps/qpixel/app/helpers/complaints_helper.rb', line 30 def report_type(key) value_for('report_types', key) end |
#report_types ⇒ Object
22 23 24 |
# File '/var/apps/qpixel/app/helpers/complaints_helper.rb', line 22 def report_types value_for('report_types') || [] end |
#report_types_select_options ⇒ Object
26 27 28 |
# File '/var/apps/qpixel/app/helpers/complaints_helper.rb', line 26 def ('report_types') end |
#status(key) ⇒ Object
46 47 48 |
# File '/var/apps/qpixel/app/helpers/complaints_helper.rb', line 46 def status(key) value_for('statuses', key) end |
#statuses ⇒ Object
38 39 40 |
# File '/var/apps/qpixel/app/helpers/complaints_helper.rb', line 38 def statuses value_for('statuses') || [] end |
#statuses_select_options ⇒ Object
42 43 44 |
# File '/var/apps/qpixel/app/helpers/complaints_helper.rb', line 42 def ('statuses') end |