Clean up moderation layout

This commit is contained in:
Andreas Nedbal 2020-04-25 18:05:35 +02:00
parent ae4c68a10b
commit baf5ba698d
5 changed files with 29 additions and 32 deletions

View file

@ -0,0 +1,10 @@
= render 'moderation/moderation_nav'
.container.j2-page
.row
.col-md-3.col-sm-4.col-xs-12
= render 'tabs/moderation'
.col-md-9.col-sm-8.col-xs-12
= yield
- provide(:title, generate_title("Moderation"))
- parent_layout "base"

View file

@ -1,9 +0,0 @@
.col-md-3.col-sm-4.col-xs-12
.card.hidden-xs
.list-group
= list_group_item t('views.moderation.tabs.all'), moderation_path
= list_group_item t('views.general.answer').pluralize(2), moderation_path('answer')
= list_group_item t('views.general.comment').pluralize(2), moderation_path('comment')
= list_group_item t('views.general.user').pluralize(2), moderation_path('user')
= list_group_item t('views.general.question').pluralize(2), moderation_path('question')
= list_group_item 'Priority', moderation_priority_path

View file

@ -1,8 +1,2 @@
- provide(:title, generate_title("Moderation"))
= render 'moderation/moderation_nav'
.container.j2-page
.row
= render 'moderation/moderation_tabs'
.col-md-9.col-sm-8.col-xs-12
- @reports.each do |r|
= render 'moderation/moderationbox', report: r
- @reports.each do |r|
= render 'moderation/moderationbox', report: r

View file

@ -1,16 +1,10 @@
- provide(:title, generate_title("Moderation"))
= render 'moderation/moderation_nav'
.container.j2-page
%h2
- if @host.nil?
Users sorted by reports
- else
Users with the same IP
#users
.row
= render 'moderation/moderation_tabs'
.col-md-9.col-sm-9.col-xs-12
%h2
- if @host.nil?
Users sorted by reports
- else
Users with the same IP
#users
.row
- @users.each do |u, c|
.col-md-4.col-sm-12col-xs-12
= render 'moderation/userbox', user: u, count: c
- @users.each do |u, c|
.col-md-4.col-sm-12col-xs-12
= render 'moderation/userbox', user: u, count: c

View file

@ -0,0 +1,8 @@
.card.hidden-xs
.list-group
= list_group_item t('views.moderation.tabs.all'), moderation_path
= list_group_item t('views.general.answer').pluralize(2), moderation_path('answer')
= list_group_item t('views.general.comment').pluralize(2), moderation_path('comment')
= list_group_item t('views.general.user').pluralize(2), moderation_path('user')
= list_group_item t('views.general.question').pluralize(2), moderation_path('question')
= list_group_item 'Priority', moderation_priority_path