send email form: only accessible for logged-in users
This commit is contained in:
parent
a3716050e9
commit
70e53daadf
1 changed files with 8 additions and 0 deletions
|
@ -133,6 +133,10 @@ class SendEmailForm(NodeView):
|
||||||
|
|
||||||
__call__ = innerHtml
|
__call__ = innerHtml
|
||||||
|
|
||||||
|
def checkPermissions(self):
|
||||||
|
return (not self.isAnonymous and
|
||||||
|
super(SendEmailForm, self).checkPermissions())
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def macro(self):
|
def macro(self):
|
||||||
return organize_macros.macros['send_email']
|
return organize_macros.macros['send_email']
|
||||||
|
@ -181,6 +185,10 @@ class SendEmailForm(NodeView):
|
||||||
|
|
||||||
class SendEmail(FormController):
|
class SendEmail(FormController):
|
||||||
|
|
||||||
|
def checkPermissions(self):
|
||||||
|
return (not self.isAnonymous and
|
||||||
|
super(SendEmail, self).checkPermissions())
|
||||||
|
|
||||||
def update(self):
|
def update(self):
|
||||||
form = self.request.form
|
form = self.request.form
|
||||||
subject = form.get('subject') or u''
|
subject = form.get('subject') or u''
|
||||||
|
|
Loading…
Add table
Reference in a new issue