2021-11-25 23:07:38 +11:00
|
|
|
- content_for :page_title do
|
|
|
|
= t('admin.trends.preview_card_providers.title')
|
|
|
|
|
2022-03-03 04:57:44 +11:00
|
|
|
%p= t('admin.trends.preview_card_providers.description_html')
|
|
|
|
|
|
|
|
%hr.spacer/
|
|
|
|
|
2021-11-25 23:07:38 +11:00
|
|
|
.filters
|
|
|
|
.filter-subset
|
|
|
|
%strong= t('admin.tags.review')
|
|
|
|
%ul
|
|
|
|
%li= filter_link_to t('generic.all'), status: nil
|
|
|
|
%li= filter_link_to t('admin.trends.approved'), status: 'approved'
|
|
|
|
%li= filter_link_to t('admin.trends.rejected'), status: 'rejected'
|
2024-09-20 18:51:37 +10:00
|
|
|
%li= filter_link_to safe_join([t('admin.accounts.moderation.pending'), "(#{PreviewCardProvider.unreviewed.count})"], ' '), status: 'pending_review'
|
2021-11-25 23:07:38 +11:00
|
|
|
.back-link
|
|
|
|
= link_to admin_trends_links_path do
|
2024-04-24 02:43:49 +10:00
|
|
|
= material_symbol 'chevron_left'
|
2021-11-25 23:07:38 +11:00
|
|
|
= t('admin.trends.links.title')
|
|
|
|
|
|
|
|
%hr.spacer/
|
|
|
|
|
2024-06-14 19:54:22 +10:00
|
|
|
= form_with model: @form, url: batch_admin_trends_links_preview_card_providers_path do |f|
|
2021-11-25 23:07:38 +11:00
|
|
|
= hidden_field_tag :page, params[:page] || 1
|
|
|
|
|
2022-02-25 10:34:14 +11:00
|
|
|
- Trends::PreviewCardProviderFilter::KEYS.each do |key|
|
2021-11-25 23:07:38 +11:00
|
|
|
= hidden_field_tag key, params[key] if params[key].present?
|
|
|
|
|
2023-07-13 19:12:51 +10:00
|
|
|
.batch-table
|
2021-11-25 23:07:38 +11:00
|
|
|
.batch-table__toolbar
|
|
|
|
%label.batch-table__toolbar__select.batch-checkbox-all
|
|
|
|
= check_box_tag :batch_checkbox_all, nil, false
|
|
|
|
.batch-table__toolbar__actions
|
2024-04-24 02:43:49 +10:00
|
|
|
= f.button safe_join([material_symbol('check'), t('admin.trends.allow')]),
|
2024-03-15 22:19:00 +11:00
|
|
|
class: 'table-action-link',
|
|
|
|
data: { confirm: t('admin.reports.are_you_sure') },
|
|
|
|
name: :approve,
|
|
|
|
type: :submit
|
2024-04-24 02:43:49 +10:00
|
|
|
= f.button safe_join([material_symbol('close'), t('admin.trends.disallow')]),
|
2024-03-15 22:19:00 +11:00
|
|
|
class: 'table-action-link',
|
|
|
|
data: { confirm: t('admin.reports.are_you_sure') },
|
|
|
|
name: :reject,
|
|
|
|
type: :submit
|
2021-11-25 23:07:38 +11:00
|
|
|
|
|
|
|
.batch-table__body
|
|
|
|
- if @preview_card_providers.empty?
|
|
|
|
= nothing_here 'nothing-here--under-tabs'
|
|
|
|
- else
|
|
|
|
= render partial: 'preview_card_provider', collection: @preview_card_providers, locals: { f: f }
|
|
|
|
|
|
|
|
= paginate @preview_card_providers
|