SF.net SVN: morphix: [2592] trunk/morphixlivekiosk/scripts/mbuild/web/views .py

[email protected] Fri, 09 Nov 2007 16:25:58 -0800
Newsgroups gmane.linux.morphix.cvs
Message-ID <[email protected]>
Revision: 2592
          http://morphix.svn.sourceforge.net/morphix/?rev=2592&view=rev
Author:   gandalfar
Date:     2007-11-09 16:25:57 -0800 (Fri, 09 Nov 2007)

Log Message:
-----------
fixed the choices being always True

Modified Paths:
--------------
    trunk/morphixlivekiosk/scripts/mbuild/web/views.py

Modified: trunk/morphixlivekiosk/scripts/mbuild/web/views.py
===================================================================
--- trunk/morphixlivekiosk/scripts/mbuild/web/views.py	2007-11-09 23:36:01 UTC (rev 2591)
+++ trunk/morphixlivekiosk/scripts/mbuild/web/views.py	2007-11-10 00:25:57 UTC (rev 2592)
@@ -11,17 +11,17 @@
 
 def index(request):
   class BuildForm(forms.Form):
-    brand_name = forms.CharField(max_length=150, required=True, label="What Brand name would you like to use?")
+    brand_name = forms.CharField(max_length=150, required=True, label="What Brand name would you like to use?", initial="Morphix LiveKiosk")
     graphics = forms.ImageField(required=False, label="Graphics file (1024x768, 32pps, any format works best)")
-    homepage = forms.CharField(max_length=150, required=True, label="Desired homepage http://")
-    nav_bar = forms.BooleanField(widget=forms.RadioSelect(choices=[(True, 'Yes'), (False, 'No')]),
-            initial=True, label="Should the Navigation Bar be visable?")
-    dhcp = forms.BooleanField(widget=forms.RadioSelect(choices=[(True, 'Yes'), (False, 'No')]),
-            initial=True, label="Use DHCP?")
-    flash = forms.BooleanField(widget=forms.RadioSelect(choices=[(True, 'Yes'), (False, 'No')]),
-            label="Include Flash?", initial=False)
-    java = forms.BooleanField(widget=forms.RadioSelect(choices=[(True, 'Yes'), (False, 'No')]),
-            label="Include Java?", initial=False)
+    homepage = forms.CharField(max_length=150, required=True, label="Desired homepage http://", initial="www.morphix.org")
+    nav_bar = forms.BooleanField(widget=forms.RadioSelect(choices=[("1", 'Yes'), ("0", 'No')]),
+            initial="1", label="Should the Navigation Bar be visable?")
+    dhcp = forms.BooleanField(widget=forms.RadioSelect(choices=[("1", 'Yes'), ("0", 'No')]),
+            initial="1", label="Use DHCP?")
+    flash = forms.BooleanField(widget=forms.RadioSelect(choices=[("1", 'Yes'), ("0", 'No')]),
+            label="Include Flash?", initial="0")
+    java = forms.BooleanField(widget=forms.RadioSelect(choices=[("1", 'Yes'), ("0", 'No')]),
+            label="Include Java?", initial="0")
 
   if request.POST:
     form = BuildForm(request.POST, request.FILES)


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/