Show abilities to hide/unhide properly

This commit is contained in:
Christoph Haas 2021-03-21 22:02:56 +01:00
parent a8b6e672c8
commit cc76ebcc28
2 changed files with 6 additions and 6 deletions

View file

@ -7,13 +7,13 @@
span class="label adminlabel #{@statuscolor}"
= @statustext
- if can?(:hide, screenshot)
- if !screenshot.hidden && screenshot.approved && can?(:hide, screenshot)
a.button.small.bordered.radius.warning[
href=hide_screenshot_path(screenshot.id)
onclick="return confirm('Really hide the screenshot from public view?');"
] #{fa_icon 'eye-slash'} Hide
- if can?(:unhide, screenshot)
- if screenshot.hidden && screenshot.approved && can?(:unhide, screenshot)
a.button.small.bordered.radius.warning[
href=unhide_screenshot_path(screenshot.id)
] #{fa_icon 'eye'} Un-Hide