Skip to content
This repository

Adding back in the checkbox to agree to the rules #88

Merged
merged 1 commit into from over 1 year ago

2 participants

Ross Bruniges Andrew Hayward
Ross Bruniges
Collaborator

Hasn't been there since I re-styled the page, and would have dis-allowed all new sign-ups being able to compete!

Andrew Hayward
Collaborator

Arguably the warnr stuff could/should have been in a separate commit/pull request, but I'll let it slide this time!

But otherwise, all looks fine to me.

Ross Bruniges
Collaborator

Thanks Andrew!

Ross Bruniges rossbruniges merged commit d8ccf23 into from December 06, 2012
Ross Bruniges rossbruniges closed this December 06, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Showing 1 unique commit by 1 author.

Dec 06, 2012
Ross Bruniges So it turns out when you don't display a required field a form will n…
…ever successfully submit
78a16ca
This page is out of date. Refresh to see the latest.
9  gameon/base/static/base/css/libs/warnr.css
... ...
@@ -0,0 +1,9 @@
  1
+#app_stage_box {
  2
+    background: #FFFF00;
  3
+    padding: 0.5em 0;
  4
+    color: 827600;
  5
+}
  6
+#app_stage_box a {
  7
+    font-weight: bold;
  8
+    text-decoration: underline;
  9
+}
9  gameon/base/static/base/css/master.css
@@ -12,15 +12,6 @@ body {
12 12
     background: linear-gradient(to right,  #379e9e 0%,#37d09e 100%); /* W3C */
13 13
     filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#379e9e', endColorstr='#37d09e',GradientType=1 ); /* IE6-9 */
14 14
 }
15  
-#app_stage_box {
16  
-    background: #FFFF00;
17  
-    padding: 0.5em 0;
18  
-    color: 827600;
19  
-}
20  
-#app_stage_box a {
21  
-    font-weight: bold;
22  
-    text-decoration: underline;
23  
-}
24 15
 a:link,
25 16
 a:visited,
26 17
 a:focus,
3  gameon/base/templates/base.html
@@ -8,6 +8,9 @@
8 8
     <link rel="stylesheet" href="//www.mozilla.org/tabzilla/media/css/tabzilla.css">
9 9
     <link rel="stylesheet" href="{{ static('base/css/libs/normalize.css') }}">
10 10
     <link rel="stylesheet" href="{{ static('base/css/master.css') }}">
  11
+    {% if APP_MSG %}
  12
+        <link rel="stylesheet" href="{{ static('base/css/libs/warnr.css') }}">
  13
+    {% endif %}
11 14
     <!--[if lt IE 9]>
12 15
         <script type="text/javascript" src="//html5shim.googlecode.com/svn/trunk/html5.js"></script>
13 16
     <![endif]-->
7  gameon/submissions/templates/submissions/create.html
@@ -14,6 +14,13 @@
14 14
         <h1 class="busta shout">{% block view_title %}Submit Your Game{% endblock %}</h1>
15 15
     </header>
16 16
     <div class="busta">
  17
+        {% if messages %}
  18
+            <div class="shout-box">
  19
+                {% for m in messages %}
  20
+                    {{ m|safe }}
  21
+                {% endfor %}
  22
+            </div>
  23
+        {% endif %}
17 24
         <form action="" method="post" enctype="multipart/form-data">
18 25
             {{ csrf() }}
19 26
             <div class="form_wrapper">
10  gameon/users/templates/users/profile_edit.html
@@ -4,7 +4,7 @@
4 4
 <link rel="stylesheet" href="{{ static('base/css/forms.css') }}">
5 5
 {% endblock %}
6 6
 
7  
-{% block page_title %}Edit Profile{% endblock %}
  7
+{% block page_title %}{% if page_mode == 'edit' %}Edit{% else %}Create{% endif %} Profile{% endblock %}
8 8
 {% block page_id %}edit_profile{% endblock %}
9 9
 {% block section_class %}profile{% endblock %}
10 10
 
@@ -56,6 +56,14 @@ <h1 class="busta shout">
56 56
                     </label>
57 57
                     {{ form.website }}
58 58
                 </div>
  59
+                {% if form.agreement %}
  60
+                    <div class="field">
  61
+                        {{ form.agreement }}
  62
+                        <label for="id_agreement" class="announce">
  63
+                            {{ form.agreement.label }}
  64
+                        </label>
  65
+                    </div>
  66
+                {% endif %}
59 67
                 <div class="field">
60 68
                     <input type="submit" name="submit" value="Submit" class="cta" />
61 69
                 </div>
1  gameon/users/views.py
@@ -53,6 +53,7 @@ def edit(request, template='users/profile_edit.html'):
53 53
                 The only reason anyone will want to create an account is to
54 54
                 submit a game, so take them right there
55 55
                 """
  56
+                messages.success(request, _('<strong>Profile created.</strong> Now you can submit your first game!'))
56 57
                 return redirect(reverse('submissions.create_entry'))
57 58
     else:
58 59
         form = form_class(instance=profile)
Commit_comment_tip

Tip: You can add notes to lines in a file. Hover to the left of a line to make a note

Something went wrong with that request. Please try again.