Show Moderate link in topbar. Add menu icons.
This commit is contained in:
parent
117239ee87
commit
ec43f47f92
3 changed files with 25 additions and 7 deletions
|
|
@ -51,6 +51,12 @@ class Package < ApplicationRecord
|
|||
where(id: subselect )
|
||||
end
|
||||
|
||||
# Return a list of packages that have screenshots to be moderated
|
||||
def self.need_moderation
|
||||
Package.joins(:screenshots).where('screenshots.approved=false or screenshots.markedfordelete=true').distinct(:name)
|
||||
end
|
||||
|
||||
|
||||
# Return a query of all packages that have screenshots
|
||||
def self.without_screenshots
|
||||
# Query for all packages who's ID does not appear in a screenshot's "package_id" field
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue