Added simple moderate feature in My page

This commit is contained in:
Christoph Haas 2021-02-14 18:48:48 +01:00
parent 953cd056aa
commit ce7198b713
5 changed files with 39 additions and 9 deletions

View file

@ -71,15 +71,15 @@ class Screenshot < ApplicationRecord
end
# Brief text describing the status of this screenshots (for admins)
# def adminstatus
# if self.markedfordelete
# "Removal requested > #{self.delete_reason}"
# elsif self.approved
# 'Public'
# else
# fa_icon('hourglass') + 'Waiting for approval'
# end
# end
def adminstatus
if self.markedfordelete
"Removal requested > #{self.delete_reason}"
elsif self.approved
'Public'
else
fa_icon('hourglass') + 'Waiting for approval'
end
end
# Publish a screenshot from the moderation queue
def approve!