From bc0b2364b1a22ecc9662ddfce1a4bd314f38f79b Mon Sep 17 00:00:00 2001 From: Leif Johansson Date: Tue, 20 Sep 2011 11:01:05 +0200 Subject: removed entity model, celery --- coip/apps/userprofile/forms.py | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 coip/apps/userprofile/forms.py (limited to 'coip/apps/userprofile/forms.py') diff --git a/coip/apps/userprofile/forms.py b/coip/apps/userprofile/forms.py new file mode 100644 index 0000000..dd42ccf --- /dev/null +++ b/coip/apps/userprofile/forms.py @@ -0,0 +1,30 @@ +''' +Created on Aug 19, 2011 + +@author: leifj +''' + +from form_utils.forms import BetterForm +from django.forms.fields import CharField +from django.forms.widgets import Textarea + + +class AddSSHKeyForm(BetterForm): + sshkey = CharField(label='SSH Key',widget=Textarea(attrs={'cols': 60, 'rows': 6})) + class Meta: + fieldsets = [ + ('key',{'fields':['sshkey'], + 'legend': 'Please provide your SSH key.', + 'description': 'Cut and paste your SSH key into the text field. Note that you should only submit the .pub-file and never the private key.', + 'classes': ['step','submit_step']}) + ] + +class AddCertificateForm(BetterForm): + certificate = CharField(label='PEM X509 Certificate',widget=Textarea(attrs={'cols': 60, 'rows': 6})) + class Meta: + fieldsets = [ + ('key',{'fields':['certificate'], + 'legend': 'Please provide your personal certificate.', + 'description': 'Cut and paste your PEM format X509 Certificate into the text field.', + 'classes': ['step','submit_step']}) + ] \ No newline at end of file -- cgit v1.1