Commits

Panayiotis Lipiridis committed d1ea1e6

The body of the feedback form changed to message and minor changes in form fields

Comments (0)

Files changed (5)

 ################################################################################
 class FeedbackForm(wtf.Form):
   subject = wtf.TextField('Subject', [wtf.validators.required()])
-  feedback = wtf.TextAreaField('Feedback', [wtf.validators.required()])
+  message = wtf.TextAreaField('Message', [wtf.validators.required()])
   email = wtf.TextField('Email (optional)', [
       wtf.validators.optional(),
       wtf.validators.email("That doesn't look like an email"),
             form.subject.data,
           ),
         reply_to=form.email.data or config.CONFIG_DB.feedback_email,
-        body='%s\n\n%s' % (form.feedback.data, form.email.data)
+        body='%s\n\n%s' % (form.message.data, form.email.data)
       )
     flask.flash('Thank you for your feedback!', category='success')
     return flask.redirect(flask.url_for('welcome'))

main/templates/bit/form_select_field.html

-<div class='control-group {% if form_field.errors %}error{% endif %}'>
+<div class="control-group {% if form_field.errors %} error {% endif %}">
   {{form_field.label(class='control-label')}}
-  <div class='controls'>
+  <div class="controls">
     {{form_field(class='span4')}}
     {% for error in form_field.errors %}
-      <span class='help-inline'>{{error}}</span>
+      <span class="help-block">{{error}}</span>
     {% endfor %}
     {% if form_field.description %}
       <span class="help-block">{{form_field.description}}</span>

main/templates/bit/form_text_field.html

-<div class='control-group {% if form_field.errors %}error{% endif %}'>
+<div class="control-group {% if form_field.errors %} error {% endif %}">
   {{form_field.label(class='control-label')}}
-  <div class='controls'>
+  <div class="controls">
     {{form_field(class='span4')}}
     {% for error in form_field.errors %}
-      <span class='help-inline'>{{error}}</span>
+      <span class="help-block">{{error}}</span>
     {% endfor %}
     {% if form_field.description %}
       <span class="help-block">{{form_field.description}}</span>

main/templates/bit/form_textarea_field.html

-<div class='control-group {% if form_field.errors %}error{% endif %}'>
+<div class="control-group {% if form_field.errors %} error {% endif %}">
   {{form_field.label(class='control-label')}}
-  <div class='controls'>
+  <div class="controls">
     {{form_field(class='span4', rows=8)}}
     {% for error in form_field.errors %}
-      <span class='help-inline'>{{error}}</span>
+      <span class="help-block">{{error}}</span>
     {% endfor %}
     {% if form_field.description %}
       <span class="help-block">{{form_field.description}}</span>

main/templates/feedback.html

           {% set form_field = form.subject %}
           {% include 'bit/form_text_field.html' %}
 
-          {% set form_field = form.feedback %}
+          {% set form_field = form.message %}
           {% include 'bit/form_textarea_field.html' %}
 
           {% set form_field = form.email %}