mirror of
https://github.com/edcommonwealth/sqm-dashboards.git
synced 2026-03-09 07:28:41 -07:00
Unify how we sort SQM Categories
This commit is contained in:
parent
934d0bda0e
commit
882fa84de9
8 changed files with 57 additions and 4 deletions
|
|
@ -1,7 +1,8 @@
|
|||
class SqmCategory < ActiveRecord::Base
|
||||
include FriendlyId
|
||||
|
||||
friendly_id :name, use: [:slugged]
|
||||
|
||||
scope :sorted, ->() { order(:sort_index) }
|
||||
|
||||
has_many :subcategories
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue