views: convert mod dashboard + admin user edit page to simple form.

Fixes bug with the user level select dropdown on the mod dashboard page
missing the builder level.
This commit is contained in:
evazion
2019-08-18 11:20:14 -05:00
parent d7d4a63e69
commit 576b4feb3b
6 changed files with 15 additions and 74 deletions

View File

@@ -3,9 +3,9 @@ module Moderator
class Report
attr_reader :min_date, :max_level
def initialize(min_date, max_level)
@min_date = min_date.present? ? min_date.to_date : 1.week.ago
@max_level = max_level.present? ? max_level.to_i : User::Levels::MEMBER
def initialize(min_date: 1.week.ago.to_date, max_level: User::Levels::MEMBER)
@min_date = min_date
@max_level = max_level.to_i
end
def artists