codecombat/app/models/Campaign.coffee

11 lines
425 B
CoffeeScript
Raw Normal View History

CocoModel = require './CocoModel'
schema = require 'schemas/models/campaign.schema'
module.exports = class Campaign extends CocoModel
@className: 'Campaign'
@schema: schema
urlRoot: '/db/campaign'
saveBackups: true
2014-12-22 16:21:57 -05:00
@denormalizedLevelProperties: _.keys(_.omit(schema.properties.levels.additionalProperties.properties, ['unlocks', 'position', 'rewards']))
@denormalizedCampaignProperties: ['name', 'i18n', 'slug']