Allow items to be grouped on mod detail pages

This commit is contained in:
Andrew Miner
2015-01-30 13:03:10 -08:00
parent a365217890
commit 6e3843731b
11 changed files with 763 additions and 589 deletions
+3
View File
@@ -14,9 +14,12 @@ Recipe = require './recipe'
module.exports = class Item extends BaseModel
@Group = Other:'Other'
constructor: (attributes={}, options={})->
if not attributes.name? then throw new Error 'attributes.name is required'
attributes.group ?= Item.Group.Other
attributes.isGatherable ?= false
attributes.slug ?= _.slugify attributes.name
options.logEvents ?= false