Skip to content

Commit

Permalink
Creates a more designed landing page
Browse files Browse the repository at this point in the history
For discussion
  • Loading branch information
caprenter authored and Bjwebb committed Aug 4, 2015
1 parent 56ba783 commit 4a2f00c
Show file tree
Hide file tree
Showing 4 changed files with 56 additions and 2 deletions.
5 changes: 5 additions & 0 deletions cove/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,11 @@
'cove-360': _('360Giving Data Tool'),
'default': _('Cove'),
},
'application_strapline': {
'cove-ocds': _('Convert, Validate, Explore Open Contracting Data'),
'cove-360': _('Convert, Validate, Explore 360Giving Data'),
'default': _('Convert, Validate, Explore'),
},
'schema_url': { # Schema url for the package schema (does not yet exist for 360)
'cove-ocds': 'http://ocds.open-contracting.org/standard/r/1__0__RC/release-package-schema.json',
'default': None
Expand Down
1 change: 1 addition & 0 deletions cove/templates/base_generic.html
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
<div class="row">
<div class="col-md-8">
{% block h1 %}<h1 class="application-name"><a href="{% url 'cove:index' %}">{{ application_name }}</a></h1>{% endblock %}
<p>{{ application_strapline }}</p>
</div><!--col-md-8-->
<div class="col-md-4">
<form class="language-select" action="{% url 'set_language' %}" method="post">
Expand Down
39 changes: 37 additions & 2 deletions cove/templates/multi_index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,42 @@

{% block content %}

<h2><a href="{% url 'cove-360:index' %}">{% trans '360Giving Data Tool' %}</a></h2>
<h2><a href="{% url 'cove-ocds:index' %}">{% trans 'Open Contracting Data Tool' %}</a></h2>
<div class="row">
<div class="col-sm-6 col-md-5 col-md-offset-1">
<div class="thumbnail">
{% load staticfiles %}
<img src="{% static 'dataexplore/360Giving-logo.png' %}" width=200 height=200 alt="{% trans '360Giving Logo' %}">
<div class="caption">
<h3>{% trans '360Giving Data Standard' %}</h3>
<p>{% blocktrans %}360Giving provides support for grantmakers to publish their grants data openly, to understand their data, and to use the data to create online tools that make grant-making more effective.{% endblocktrans %}</p><br>
<p><a href="{% url 'cove-360:index' %}" class="btn btn-primary" role="button">{% trans '360Giving Data Tool' %}</a>
</div>
</div>
</div>

<div class="col-sm-6 col-md-5">
<div class="thumbnail">
{% load staticfiles %}
<img src="{% static 'dataexplore/lKMj_JJ4_400x400.jpeg' %}" width=200 height=200 alt="{% trans 'Open Contracting Logo' %}">
<div class="caption">
<h3>{% trans 'Open Contracting Data Standard' %}</h3>
<p>{% blocktrans %}The Open Contracting Data Standard promotes the effective use of contracting data, helping users to “follow the money”, and it provides a clear template for governments wishing to disclose their data.{% endblocktrans %}</p><br>
<p><a href="{% url 'cove-ocds:index' %}" class="btn btn-primary" role="button">{% trans 'Open Contracting Data Tool' %}</a>
</div>
</div>
</div>
</div>

<div class="jumbotron">
<p>{% trans 'Creating and using Open Data is made easier when there are good tools to help.' %}</p>
<p>{% trans 'CoVE exisits to help people:' %}</p>
<ul>
<li>{% trans 'Convert data between common formats (e.g. csv to json)' %}</li>
<li>{% trans 'Validate data against rules' %}</li>
<li>{% trans 'Explore data, that machines find easy, but humans find harder to read' %}</li>
</ul>
<!--<p>CoVE is pretty good at Converting right now, and we're working on Validation and Exploration all the time.</p>
<p>CoVE is currently designed to work with data built to the 360Giving and Open Contracting data standards.</p>-->
</div>

{% endblock %}
13 changes: 13 additions & 0 deletions fts/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,19 @@ def server_url(request, live_server):
return live_server.url


def test_index_page_banner(server_url, browser):
browser.get(server_url)
assert 'This tool is alpha. Please report any problems on GitHub issues.' in browser.find_element_by_tag_name('body').text


def test_index_page(server_url, browser):
browser.get(server_url)
assert 'CoVE' in browser.find_element_by_tag_name('body').text
assert '360Giving Data Tool' in browser.find_element_by_tag_name('body').text
assert 'Open Contracting Data Tool' in browser.find_element_by_tag_name('body').text
assert 'Creating and using Open Data is made easier when there are good tools to help.' in browser.find_element_by_tag_name('body').text


def test_index_page_ocds(server_url, browser):
browser.get(server_url + '/ocds/')
assert 'Open Contracting Data Tool' in browser.find_element_by_tag_name('body').text
Expand Down

0 comments on commit 4a2f00c

Please sign in to comment.