def __init__(self, *args, **kwargs):
super(MessageRecipientForm, self).__init__(*args, **kwargs)
self.helper = FormHelper()
self.helper.form_class = 'form-horizontal'
self.helper.label_class = 'col-md-3'
self.helper.field_class = 'col-md-8'
self.fields['recipient_approved_public'].label = "I agree to publish this message and display it publicly in the Happiness Archive."
self.fields['recipient_approved_public_named'].label = "... and I agree to display our names publicly too."
self.fields['recipient_approved_public_named'].help_text = "Note: We only publish information if both the sender and the recipients agree."
self.helper.layout = Layout(
Fieldset("Privacy and permissions", 'recipient_approved_public', 'recipient_approved_public_named'),
HTML("<br>"),
Submit('submit', 'Save privacy choices', css_class='btn-lg centered'),
)
评论列表
文章目录