Revision 45f8d9ff snf-astakos-app/astakos/im/widgets.py
b/snf-astakos-app/astakos/im/widgets.py | ||
---|---|---|
62 | 62 |
is_hidden=True |
63 | 63 |
def render(self, *args, **kwargs): |
64 | 64 |
return '' |
65 |
|
|
66 |
class ApprovalTermsWidget(forms.CheckboxInput): |
|
67 |
""" |
|
68 |
A CheckboxInput class with a link to the approval terms. |
|
69 |
""" |
|
70 |
def __init__(self, attrs=None, check_test=bool, terms_uri='', terms_label=_('Read the terms')): |
|
71 |
super(ApprovalTermsWidget, self).__init__(attrs, check_test) |
|
72 |
self.uri = terms_uri |
|
73 |
self.label = terms_label |
|
74 |
|
|
75 |
def render(self, name, value, attrs=None): |
|
76 |
html = super(ApprovalTermsWidget, self).render(name, value, attrs) |
|
77 |
return html |
Also available in: Unified diff