Added control fields to group_app.
authorLennard de Rijk <ljvderijk@gmail.com>
Sat, 10 Jan 2009 13:50:41 +0000
changeset 795 8914adaa93a7
parent 794 19c24508c398
child 796 126a1ef235ec
Added control fields to group_app. Moved unnecessary fields containing questions about past participation from group_app to org_app. Updated the club_app public page to show the correct information using twoline layout. Patch by: Lennard de Rijk
app/soc/models/group_app.py
app/soc/models/org_app.py
app/soc/templates/soc/club_app/public.html
--- a/app/soc/models/group_app.py	Sat Jan 10 13:28:04 2009 +0000
+++ b/app/soc/models/group_app.py	Sat Jan 10 13:50:41 2009 +0000
@@ -74,17 +74,6 @@
       'Why is your group applying to participate?'
       ' What do you hope to gain by participating?'))
 
-  prior_participation = db.TextProperty(required=False,
-    verbose_name=ugettext_lazy(
-      'Has your group participated previously?'
-      ' If so, please summarize your involvement and any past successes'
-      ' and failures.'))
-
-  prior_application = db.TextProperty(required=False,
-    verbose_name=ugettext_lazy(
-      'If your group has not previously participated, have you applied in'
-      ' the past?  If so, for what sort of participation?'))
-
   pub_mailing_list = db.StringProperty(required=False,
     verbose_name=ugettext_lazy(
       'What is the main public mailing list for your group?'))
@@ -107,3 +96,17 @@
       ' Please be as specific as possible.'))
   member_criteria.help_text = ugettext_lazy(
     'Members include mentors, admininstrators, and the like.')
+  
+  # boolean to indicate if an application has been reviewed
+  reviewed = db.BooleanProperty(required=True, default=False,
+      verbose_name=ugettext_lazy('Has been reviewed')
+      )
+  # boolean to indicate if an application has been accepted
+  accepted = db.BooleanProperty(required=True, default=False,
+      verbose_name=ugettext_lazy('Has been accepted')
+      )
+  
+  # boolean to indicate that this application has been
+  # handled and turned into a group
+  application_completed = db.BooleanProperty(required=True, default=False,
+      verbose_name=ugettext_lazy('Has been completed'))
--- a/app/soc/models/org_app.py	Sat Jan 10 13:28:04 2009 +0000
+++ b/app/soc/models/org_app.py	Sat Jan 10 13:50:41 2009 +0000
@@ -39,7 +39,18 @@
   approach.  At that time, existing OrgApplication entities will be migrated
   (converted) to their new representations in the Datastore.
   """
+  
+  prior_participation = db.TextProperty(required=False,
+    verbose_name=ugettext_lazy(
+      'Has your group participated previously?'
+      ' If so, please summarize your involvement and any past successes'
+      ' and failures.'))
 
+  prior_application = db.TextProperty(required=False,
+    verbose_name=ugettext_lazy(
+      'If your group has not previously participated, have you applied in'
+      ' the past?  If so, for what sort of participation?'))
+  
   license_name = db.StringProperty(required=True,
     verbose_name=ugettext_lazy(
       'What license does your organization use?'))
--- a/app/soc/templates/soc/club_app/public.html	Sat Jan 10 13:28:04 2009 +0000
+++ b/app/soc/templates/soc/club_app/public.html	Sat Jan 10 13:50:41 2009 +0000
@@ -21,15 +21,16 @@
 {% block body %}
 <p>
  <table>
-  {% readonly_field_as_table_row entity.fields.name.label entity.name %}
-  {% readonly_field_as_table_row entity.fields.home_page.label entity.home_page %}
-  {% readonly_field_as_table_row entity.fields.description.label entity.description %}
-  {% readonly_field_as_table_row entity.fields.street.label entity.street %}
-  {% readonly_field_as_table_row entity.fields.city.label entity.city %}
-  {% readonly_field_as_table_row entity.fields.state.label entity.state %}
-  {% readonly_field_as_table_row entity.fields.country.label entity.country %}
-  {% readonly_field_as_table_row entity.fields.postalcode.label entity.postalcode %}
-  {% readonly_field_as_table_row entity.fields.phone.label entity.phone %}
+  {% readonly_field_as_twoline_table_row entity.fields.name.label entity.name %}
+  {% readonly_field_as_twoline_table_row entity.fields.applicant.label entity.applicant.link_id %}
+  {% readonly_field_as_twoline_table_row entity.fields.home_page.label entity.home_page %}
+  {% readonly_field_as_twoline_table_row entity.fields.email.label entity.email %}
+  {% readonly_field_as_twoline_table_row entity.fields.description.label entity.description %}
+  {% readonly_field_as_twoline_table_row entity.fields.why_applying.label entity.why_applying %}
+  {% readonly_field_as_twoline_table_row entity.fields.pub_mailing_list.label entity.pub_mailing_list %}
+  {% readonly_field_as_twoline_table_row entity.fields.irc_channel.label entity.irc_channel %}
+  {% readonly_field_as_twoline_table_row entity.fields.backup_admin.label entity.backup_admin.link_id %}
+  {% readonly_field_as_twoline_table_row entity.fields.member_criteria.label entity.member_criteria %}
  </table>
 </p>
 {% endblock %}