mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2024-11-28 10:06:08 -05:00
0768b533e2
Caching older (at least 16 days) Stripe invoices in analytics collection, which will be updated once a day via the analytics server cron job.
56 lines
2.1 KiB
CoffeeScript
56 lines
2.1 KiB
CoffeeScript
module.exports.handlers =
|
|
'analytics_log_event': 'analytics/analytics_log_event_handler'
|
|
'analytics_perday': 'analytics/analytics_perday_handler'
|
|
'analytics_string': 'analytics/analytics_string_handler'
|
|
'analytics_stripe_invoice': 'analytics/analytics_stripe_invoice_handler'
|
|
# TODO: Disabling this until we know why our app servers CPU grows out of control.
|
|
# 'analytics_users_active': 'analytics/analytics_users_active_handler'
|
|
'article': 'articles/article_handler'
|
|
'campaign': 'campaigns/campaign_handler'
|
|
'clan': 'clans/clan_handler'
|
|
'level': 'levels/level_handler'
|
|
'level_component': 'levels/components/level_component_handler'
|
|
'level_feedback': 'levels/feedbacks/level_feedback_handler'
|
|
'level_session': 'levels/sessions/level_session_handler'
|
|
'level_system': 'levels/systems/level_system_handler'
|
|
'patch': 'patches/patch_handler'
|
|
'payment': 'payments/payment_handler'
|
|
'purchase': 'purchases/purchase_handler'
|
|
'thang_type': 'levels/thangs/thang_type_handler'
|
|
'user': 'users/user_handler'
|
|
'user_code_problem': 'user_code_problems/user_code_problem_handler'
|
|
'user_remark': 'users/remarks/user_remark_handler'
|
|
'mail_sent': 'mail/sent/mail_sent_handler'
|
|
'achievement': 'achievements/achievement_handler'
|
|
'earned_achievement': 'achievements/earned_achievement_handler'
|
|
'poll': 'polls/poll_handler'
|
|
'prepaid': 'prepaids/prepaid_handler'
|
|
'subscription': 'payments/subscription_handler'
|
|
'trial_request': 'trial_requests/trial_request_handler'
|
|
'user_polls_record': 'polls/user_polls_record_handler'
|
|
|
|
module.exports.routes =
|
|
[
|
|
'routes/admin'
|
|
'routes/auth'
|
|
'routes/contact'
|
|
'routes/db'
|
|
'routes/file'
|
|
'routes/folder'
|
|
'routes/github'
|
|
'routes/languages'
|
|
'routes/mail'
|
|
'routes/sprites'
|
|
'routes/queue'
|
|
'routes/stacklead'
|
|
'routes/stripe'
|
|
]
|
|
|
|
mongoose = require 'mongoose'
|
|
module.exports.modules = modules = # by collection name
|
|
'achievements': 'Achievement'
|
|
'level.sessions': 'level.session'
|
|
'users': 'User'
|
|
|
|
mongoose.modelNameByCollection = (collection) ->
|
|
mongoose.model modules[collection] if collection of modules
|