mirror of
https://github.com/overleaf/overleaf.git
synced 2025-02-11 22:43:04 +00:00
16 lines
473 B
CoffeeScript
16 lines
473 B
CoffeeScript
|
|
NotificationsHandler = require("./NotificationsHandler")
|
|
|
|
module.exports =
|
|
|
|
groupPlan: (user, licence)->
|
|
key : "join-sub-#{licence.subscription_id}"
|
|
|
|
create: (callback = ->)->
|
|
messageOpts =
|
|
groupName: licence.name
|
|
subscription_id: licence.subscription_id
|
|
NotificationsHandler.createNotification user._id, key, "joinSubscriptionInvite", messageOpts, callback
|
|
|
|
read: (callback = ->)->
|
|
NotificationsHandler.markAsReadWithKey user._id, key, callback
|