Files
openfoodnetwork/app/views/admin/reports/index.html.haml
Jean-Baptiste Bellet 214a470896 Remove the report Subtype selector in the Rendering Options section
+ add all sub-reports in the index page
all of this is behind a feature toggle
2022-06-13 14:39:12 +02:00

24 lines
913 B
Plaintext

- content_for :page_title do
= t(:listing_reports)
.columns.twelve
%table.index
%thead
%tr
%th= t(:name)
%th= t(:description)
%tbody
- @reports.each do |report_type, report_subtypes|
%tr
%td
- name = I18n.t(:name, scope: [:admin, :reports, report_type])
- url = main_app.admin_report_url(report_type: report_type)
= link_to name, url
%td
- begin
= I18n.t!(:description, scope: [:admin, :reports, report_type])
- if feature? :report_inverse_columns_logic, spree_current_user
= render partial: "report_subtype", locals: { report_subtypes: report_subtypes, report_type: report_type }
- rescue I18n::MissingTranslationData
= render partial: "report_subtype", locals: { report_subtypes: report_subtypes, report_type: report_type }