-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4570893
commit 2d2a6f1
Showing
6 changed files
with
82 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
from django.http import HttpResponseRedirect | ||
from formtools.preview import FormPreview | ||
|
||
|
||
class IndividualFormPreview(FormPreview): | ||
def done(self, request, cleaned_data): | ||
return HttpResponseRedirect('/form/success') | ||
|
||
|
||
class OrganizationFormPreview(FormPreview): | ||
def done(self, request, cleaned_data): | ||
return HttpResponseRedirect('/form/success') | ||
|
||
|
||
class SocialNetworksFormPreview(FormPreview): | ||
def done(self, request, cleaned_data): | ||
return HttpResponseRedirect('/form/success') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
fieldset > label { | ||
line-height: 3rem; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
document.getElementsByTagName('label') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{% extends 'surveys/base.html' %} | ||
{% load static %} | ||
{% load i18n %} | ||
{% load maps_extras %} | ||
{% block title %}{{ '2020 Ecosystem Survey'|titlify }}{% endblock %} | ||
{% block content %} | ||
<pre>{{ form_data | pprint }}</pre> | ||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
{% extends 'surveys/base.html' %} | ||
{% load static %} | ||
{% load i18n %} | ||
{% load maps_extras %} | ||
{% block title %}{{ '2020 Ecosystem Survey'|titlify }}{% endblock %} | ||
{% block content %} | ||
<div class="page-header"> | ||
<h1><span class="pc-ff--sans pc-fw--normal">Platform Co-op</span><br/> Directory</h1> | ||
<p class="subhead">2020 Survey of the International Cooperative Digital Ecosystem</p> | ||
</div> | ||
<h3>Do you need funding for your cooperative digital project?</h3> | ||
|
||
<div class="spacer"></div> | ||
Step {{ wizard.steps.step1 }} of {{ wizard.steps.count }} | ||
<form action="{% url 'index' %}" method="post"> | ||
{{ wizard.management_form }} | ||
{% if wizard.form.forms %} | ||
{{ wizard.form.management_form }} | ||
{% for form in wizard.form.forms %} | ||
{{ form }} | ||
{% endfor %} | ||
{% else %} | ||
{{ wizard.form }} | ||
{% endif %} | ||
|
||
{% csrf_token %} | ||
{% if error_message %}<p><strong>{{ error_message }}</strong></p>{% endif %} | ||
<fieldset> | ||
<legend><strong>Your contact information</strong></legend> | ||
<p>Please provide the contact information for the best person to reach out to should we have follow-up questions about the answers you have provided to the short form of our survey. This contact information will not be part of the index. It will not be published online.</p> | ||
<div class="spacer"></div> | ||
{{ individual_form }} | ||
<ul class="input-group"> | ||
<strong>{{ role_form.role.label }}</strong> | ||
{% for radio in role_form.role %} | ||
<li>{{ radio.tag }} | ||
<label for="{{ radio.id_for_label }}">{{ radio.choice_label }}</label> | ||
</li> | ||
{% endfor %} | ||
</ul> | ||
|
||
</fieldset> | ||
|
||
{% if wizard.steps.prev %} | ||
<button name="wizard_goto_step" type="submit" value="{{ wizard.steps.first }}">{% trans "first step" %}</button> | ||
<button name="wizard_goto_step" type="submit" value="{{ wizard.steps.prev }}">{% trans "prev step" %}</button> | ||
{% endif %} | ||
<input type="submit" value="{% trans "submit" %}"/> | ||
|
||
</form> | ||
|
||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters