aboutsummaryrefslogtreecommitdiffstats
path: root/mediagoblin/edit/forms.py
diff options
context:
space:
mode:
authorcfdv <caldavis@gmail.com>2011-06-18 16:42:22 -0500
committercfdv <caldavis@gmail.com>2011-06-18 16:42:22 -0500
commit630b57a366d10495a89d392c9b02cf432e6a1599 (patch)
treec4ba80c7be6535fe2eb8f9d07e7a072643b94edb /mediagoblin/edit/forms.py
parent279d925e757d9756e09e14316f0d85b6e20624ea (diff)
downloadmediagoblin-630b57a366d10495a89d392c9b02cf432e6a1599.tar.lz
mediagoblin-630b57a366d10495a89d392c9b02cf432e6a1599.tar.xz
mediagoblin-630b57a366d10495a89d392c9b02cf432e6a1599.zip
baby step towards enabling profile edits
adds * url and bio fields to database * form for editing the user profile * route to the edit profile controller * view for the profile editing page * template for the profile editing page * link to edit profile in the welcome page still needs * thorough inspection to see if it makes sense * tests * ?
Diffstat (limited to 'mediagoblin/edit/forms.py')
-rw-r--r--mediagoblin/edit/forms.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/mediagoblin/edit/forms.py b/mediagoblin/edit/forms.py
index ea25141d..fb4930a2 100644
--- a/mediagoblin/edit/forms.py
+++ b/mediagoblin/edit/forms.py
@@ -25,3 +25,10 @@ class EditForm(wtforms.Form):
slug = wtforms.TextField(
'Slug')
description = wtforms.TextAreaField('Description of this work')
+
+class EditProfileForm(wtforms.Form):
+ url = wtforms.TextField(
+ 'website URL',
+ [wtforms.validators.URL(message='Improperly formed URL')])
+ bio = wtforms.TextAreaField('bio',
+ [wtforms.validators.Length(min=0, max=500)])