mirror of
https://github.com/vale981/Vulcan
synced 2025-03-10 04:26:41 -04:00
16 lines
No EOL
444 B
JavaScript
16 lines
No EOL
444 B
JavaScript
Template[getTemplate('invites')].helpers({
|
|
canCurrentUserInvite: function(){
|
|
var currentUser = Meteor.user();
|
|
return currentUser && (currentUser.inviteCount > 0 && canInvite(currentUser));
|
|
},
|
|
|
|
invitesLeft: function(){
|
|
var currentUser = Meteor.user();
|
|
return currentUser ? currentUser.inviteCount : 0;
|
|
},
|
|
|
|
invitesSchema: function() {
|
|
// expose schema for Invites (used by AutoForm)
|
|
return InviteSchema;
|
|
}
|
|
}); |