Tidied app.py so that it only contains controller logic. Added error handling for if number of entrants exceeds number of possible identifiers Updated test coverage to test for all identifiers, as well as error case
32 lines
1.6 KiB
HTML
32 lines
1.6 KiB
HTML
{% extends "bootstrap/base.html" %}
|
|
|
|
{% block styles %}
|
|
{{super()}}
|
|
<link rel="stylesheet"
|
|
href="{{url_for('static', filename='mystyle.css')}}">
|
|
{% endblock %}
|
|
|
|
{% block title %}Wigan Homebrew Club Competition Entry{% endblock %}
|
|
|
|
{% block content %}
|
|
<div class="container">
|
|
<div class="jumbotron text-center" id="my-jumbotron">
|
|
<h2 class="my-title">Wigan Homebrew Club Competition Entry</h2>
|
|
</div>
|
|
<div class="row">
|
|
<div class="col-md-2"></div>
|
|
<div class="col-md-8 content-div">
|
|
{% if error == None %}
|
|
<p>You have been entered into the competition to brew a <strong>{{ brew_name }}</strong>, which will be judged at the meeting in <strong>{{ brew_month }}</strong>.</p>
|
|
<p>To make sure your beer isn't easily identifiable, most people tend to use brown bottles of either 330ml or 500ml size. You probably don't want to put your own label on the bottle!</p>
|
|
<br/>
|
|
<div class="alert alert-success lead" role="alert"> <span class="glyphicon glyphicon-tags" aria-hidden="true"></span> Please mark all of your bottlecaps with the following identifier: <strong>{{ identifier }}</strong></div>
|
|
{% else %}
|
|
<p>Unfortunately it has not been possible to enter you into the competition at this time</p>
|
|
<div class="alert alert-danger lead" role="alert"> {{ error }} </div>
|
|
{% endif %}
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
{% endblock %} |