Replace tabs with two spaces for consistency

This commit is contained in:
Chris Hill-Scott
2016-02-01 16:57:29 +00:00
parent 9cf6dfa6f2
commit 3f45dbf09d
19 changed files with 293 additions and 293 deletions

View File

@@ -6,13 +6,13 @@ GOV.UK Notify | Send email
{% block maincolumn_content %} {% block maincolumn_content %}
<h1 class="heading-xlarge">Send email</h1> <h1 class="heading-xlarge">Send email</h1>
<p>This page will be where we check the email messages we're about to send</p> <p>This page will be where we check the email messages we're about to send</p>
<p> <p>
<a class="button" href="dashboard" role="button">Send email messages</a> <a class="button" href="dashboard" role="button">Send email messages</a>
</p> </p>
{% endblock %} {% endblock %}

View File

@@ -5,60 +5,60 @@
{% from "components/page-footer.html" import page_footer %} {% from "components/page-footer.html" import page_footer %}
{% block page_title %} {% block page_title %}
GOV.UK Notify | Send text messages GOV.UK Notify | Send text messages
{% endblock %} {% endblock %}
{% block maincolumn_content %} {% block maincolumn_content %}
<h1 class="heading-xlarge">Send text messages</h1> <h1 class="heading-xlarge">Send text messages</h1>
{% if upload_result.rejects %} {% if upload_result.rejects %}
<h3 class="heading-small">The following numbers are invalid</h3> <h3 class="heading-small">The following numbers are invalid</h3>
{% for rejected in upload_result.rejects %} {% for rejected in upload_result.rejects %}
<p>Line {{rejected.line_number}}: {{rejected.phone }}</a> <p>Line {{rejected.line_number}}: {{rejected.phone }}</a>
{% endfor %} {% endfor %}
<p><a href="{{url_for('.send_sms', service_id=service_id)}}" class="button">Go back and resolve errors</a></p> <p><a href="{{url_for('.send_sms', service_id=service_id)}}" class="button">Go back and resolve errors</a></p>
{% else %} {% else %}
<h2 class="heading-medium">Check and confirm</h2> <h2 class="heading-medium">Check and confirm</h2>
<form method="POST" enctype="multipart/form-data"> <form method="POST" enctype="multipart/form-data">
{{ page_footer( {{ page_footer(
button_text = "Send {} text messages".format(upload_result.valid|count), button_text = "Send {} text messages".format(upload_result.valid|count),
back_link = url_for(".send_sms", service_id=service_id) back_link = url_for(".send_sms", service_id=service_id)
)}} )}}
{% if upload_result.valid | count > 6 %} {% if upload_result.valid | count > 6 %}
<h3 class="heading-small">First three message in file</h3> <h3 class="heading-small">First three message in file</h3>
{% for recipient in upload_result.valid[:3] %} {% for recipient in upload_result.valid[:3] %}
{{ sms_message(message_template|replace_placeholders( {{ sms_message(message_template|replace_placeholders(
recipient), recipient),
'{}'.format(recipient['phone']) '{}'.format(recipient['phone'])
)}} )}}
{% endfor %} {% endfor %}
<h3 class="heading-small">Last three messages in file</h3> <h3 class="heading-small">Last three messages in file</h3>
{% for recipient in upload_result.valid[-3:] %} {% for recipient in upload_result.valid[-3:] %}
{{ sms_message(message_template|replace_placeholders( {{ sms_message(message_template|replace_placeholders(
recipient), recipient),
'{}'.format(recipient['phone']) '{}'.format(recipient['phone'])
)}} )}}
{% endfor %} {% endfor %}
{% else %} {% else %}
<h3 class="heading-small">All messages in file</h3> <h3 class="heading-small">All messages in file</h3>
{% for recipient in upload_result.valid %} {% for recipient in upload_result.valid %}
{{ sms_message(message_template|replace_placeholders( {{ sms_message(message_template|replace_placeholders(
recipient), recipient),
'{}'.format(recipient['phone']) '{}'.format(recipient['phone'])
)}} )}}
{% endfor %} {% endfor %}
{% endif %} {% endif %}
{{ page_footer( {{ page_footer(
button_text = "Send {} text messages".format(upload_result.valid|count), button_text = "Send {} text messages".format(upload_result.valid|count),
back_link = url_for(".send_sms", service_id=service_id) back_link = url_for(".send_sms", service_id=service_id)
)}} )}}
</form> </form>
{% endif %} {% endif %}
{% endblock %} {% endblock %}

View File

@@ -8,28 +8,28 @@ GOV.UK Notify | Edit template
{% block maincolumn_content %} {% block maincolumn_content %}
<h1 class="heading-xlarge">{{ h1 }}</h1> <h1 class="heading-xlarge">{{ h1 }}</h1>
<form method="post"> <form method="post">
{{ textbox(form.name) }} {{ textbox(form.name) }}
<fieldset class="form-group"> <fieldset class="form-group">
<legend class="form-label"> <legend class="form-label">
Template type Template type
</legend> </legend>
<label class="block-label" for="template_type"> <label class="block-label" for="template_type">
<input type="radio" name="template_type" id="template_type" checked="checked" value="sms" /> <input type="radio" name="template_type" id="template_type" checked="checked" value="sms" />
Text message Text message
</label> </label>
</fieldset> </fieldset>
{{ textbox(form.template_content, highlight_tags=True) }} {{ textbox(form.template_content, highlight_tags=True) }}
{{ page_footer( {{ page_footer(
'Save', 'Save',
delete_link=url_for('.delete_service_template', service_id=service_id, template_id=template_id) if template_id or None, delete_link=url_for('.delete_service_template', service_id=service_id, template_id=template_id) if template_id or None,
delete_link_text='delete this template', delete_link_text='delete this template',
back_link=url_for('.manage_service_templates', service_id=service_id), back_link=url_for('.manage_service_templates', service_id=service_id),
back_link_text='Back to templates' back_link_text='Back to templates'
) }} ) }}
</form> </form>
{% endblock %} {% endblock %}

View File

@@ -15,7 +15,7 @@ GOV.UK Notify
<p>If you have forgotten your password, we can send you an email to create a new password.</p> <p>If you have forgotten your password, we can send you an email to create a new password.</p>
<form autocomplete="off" method="post"> <form autocomplete="off" method="post">
{{ textbox(form.email_address) }} {{ textbox(form.email_address) }}
{{ page_footer("Send email") }} {{ page_footer("Send email") }}
</form> </form>

View File

@@ -10,32 +10,32 @@ GOV.UK Notify | Notifications activity
{% block maincolumn_content %} {% block maincolumn_content %}
<h1 class="heading-large"> <h1 class="heading-large">
{{ uploaded_file_name }} {{ uploaded_file_name }}
</h1> </h1>
<p> <p>
{{ banner(flash_message, with_tick=True) }} {{ banner(flash_message, with_tick=True) }}
</p> </p>
<ul class="grid-row job-totals"> <ul class="grid-row job-totals">
<li class="column-one-third"> <li class="column-one-third">
{{ big_number( {{ big_number(
counts.total, counts.total,
'text message' if 1 == counts.total else 'text messages' 'text message' if 1 == counts.total else 'text messages'
)}} )}}
</li> </li>
<li class="column-one-third"> <li class="column-one-third">
{{ big_number( {{ big_number(
counts.failed, counts.failed,
'failed delivery' if 1 == counts.failed else 'failed deliveries' 'failed delivery' if 1 == counts.failed else 'failed deliveries'
)}} )}}
</li> </li>
<li class="column-one-third"> <li class="column-one-third">
{{ big_number( {{ big_number(
cost, 'total cost' cost, 'total cost'
)}} )}}
</li> </li>
</ul> </ul>
<p> <p>
Sent with template <a href="{{ url_for('.edit_service_template', service_id=service_id, template_id=template_used) }}">{{ template_used }}</a> on {{ uploaded_file_time | format_datetime}} Sent with template <a href="{{ url_for('.edit_service_template', service_id=service_id, template_id=template_used) }}">{{ template_used }}</a> on {{ uploaded_file_time | format_datetime}}
@@ -61,8 +61,8 @@ GOV.UK Notify | Notifications activity
align='right', align='right',
status='error' if item.status == 'Failed' else 'default' status='error' if item.status == 'Failed' else 'default'
) %} ) %}
{{ item.status }}&emsp;{{ item.time }} {{ item.status }}&emsp;{{ item.time }}
{% endcall %} {% endcall %}
{% endcall %} {% endcall %}
{% endblock %} {% endblock %}

View File

@@ -7,28 +7,28 @@ GOV.UK Notify | Notifications activity
{% block maincolumn_content %} {% block maincolumn_content %}
<h1 class="heading-xlarge">Notifications activity</h1> <h1 class="heading-xlarge">Notifications activity</h1>
{% call(item) list_table( {% call(item) list_table(
jobs, jobs,
caption="Recent activity", caption="Recent activity",
caption_visible=False, caption_visible=False,
empty_message='You havent sent any notifications yet', empty_message='You havent sent any notifications yet',
field_headings=['Job', 'File', 'Time', 'Status'] field_headings=['Job', 'File', 'Time', 'Status']
) %} ) %}
{% call field() %} {% call field() %}
<a href="{{ url_for('.view_job', service_id=service_id, job_id=item.id) }}">{{ item.id }}</a> <a href="{{ url_for('.view_job', service_id=service_id, job_id=item.id) }}">{{ item.id }}</a>
{% endcall %} {% endcall %}
{% call field() %} {% call field() %}
<a href="{{ url_for('.view_job', service_id=service_id, job_id=item.id) }}">{{ item.original_file_name }}</a> <a href="{{ url_for('.view_job', service_id=service_id, job_id=item.id) }}">{{ item.original_file_name }}</a>
{% endcall %} {% endcall %}
{% call field() %} {% call field() %}
{{ item.created_at | format_datetime}} {{ item.created_at | format_datetime}}
{% endcall %} {% endcall %}
{% call field() %} {% call field() %}
{{ item.status }} {{ item.status }}
{% endcall %} {% endcall %}
{% endcall %} {% endcall %}
{% endblock %} {% endblock %}

View File

@@ -7,13 +7,13 @@ GOV.UK Notify | Manage users
{% block maincolumn_content %} {% block maincolumn_content %}
<h1 class="heading-xlarge">Manage users</h1> <h1 class="heading-xlarge">Manage users</h1>
<p>Here's where you can add or remove users of a service.</p> <p>Here's where you can add or remove users of a service.</p>
{{ page_footer( {{ page_footer(
back_link = url_for('.service_dashboard', service_id=service_id), back_link = url_for('.service_dashboard', service_id=service_id),
back_link_text = 'Back to dashboard' back_link_text = 'Back to dashboard'
) }} ) }}
{% endblock %} {% endblock %}

View File

@@ -9,24 +9,24 @@ GOV.UK Notify
{% block maincolumn_content %} {% block maincolumn_content %}
<div class="grid-row"> <div class="grid-row">
<div class="column-two-thirds"> <div class="column-two-thirds">
{% if user %} {% if user %}
<h1 class="heading-xlarge"> <h1 class="heading-xlarge">
Create a new password Create a new password
</h1> </h1>
<p> <p>
You can now create a new password for your account. You can now create a new password for your account.
</p> </p>
<form method="post" autocomplete="off"> <form method="post" autocomplete="off">
{{ textbox(form.new_password, hint="Your password must have at least 10 characters") }} {{ textbox(form.new_password, hint="Your password must have at least 10 characters") }}
{{ page_footer("Continue") }} {{ page_footer("Continue") }}
</form> </form>
{% else %} {% else %}
<p> <p>
Message about email address does not exist. Some one needs to figure out the words here. Message about email address does not exist. Some one needs to figure out the words here.
</p> </p>
{% endif %} {% endif %}
</div> </div>
</div> </div>
{% endblock %} {% endblock %}

View File

@@ -10,24 +10,24 @@ GOV.UK Notify | Notifications activity
{% block maincolumn_content %} {% block maincolumn_content %}
<h1 class="heading-large"> <h1 class="heading-large">
Text message Text message
</h1> </h1>
<div class="grid-row"> <div class="grid-row">
<div class="column-two-thirds"> <div class="column-two-thirds">
{{ sms_message(message.message, message.phone) }} {{ sms_message(message.message, message.phone) }}
</div> </div>
<div class="column-one-third"> <div class="column-one-third">
{{ banner( {{ banner(
"{} {}".format(message.status, delivered_at) "{} {}".format(message.status, delivered_at)
) }} ) }}
</div> </div>
</div> </div>
{{ page_footer( {{ page_footer(
back_link = url_for('.view_job', service_id=service_id, job_id=job_id), back_link = url_for('.view_job', service_id=service_id, job_id=job_id),
back_link_text = 'View other messages in this job' back_link_text = 'View other messages in this job'
) }} ) }}
{% endblock %} {% endblock %}

View File

@@ -7,12 +7,12 @@ GOV.UK Notify |
{% block maincolumn_content %} {% block maincolumn_content %}
<div class="grid-row"> <div class="grid-row">
<div class="column-two-thirds"> <div class="column-two-thirds">
<h1 class="heading-xlarge">GOV.UK Notify</h1> <h1 class="heading-xlarge">GOV.UK Notify</h1>
<p>You have been sent an email containing a link to reset your password.</p> <p>You have been sent an email containing a link to reset your password.</p>
</div> </div>
</div> </div>
{% endblock %} {% endblock %}

View File

@@ -7,29 +7,29 @@ GOV.UK Notify | Create a user account
{% block maincolumn_content %} {% block maincolumn_content %}
<div class="grid-row"> <div class="grid-row">
<div class="column-two-thirds"> <div class="column-two-thirds">
<h1 class="heading-xlarge">Create an account</h1> <h1 class="heading-xlarge">Create an account</h1>
<p>If you've used GOV.UK Notify before, <a href="">sign in to your account</a>.</p> <p>If you've used GOV.UK Notify before, <a href="">sign in to your account</a>.</p>
<p> <p>
<label class="form-label" for="name-f1">Full name</label> <label class="form-label" for="name-f1">Full name</label>
<input class="form-control-2-3" id="name-f1" type="text"> <input class="form-control-2-3" id="name-f1" type="text">
</p> </p>
<p> <p>
<label class="form-label" for="mobile">Mobile phone number</label> <label class="form-label" for="mobile">Mobile phone number</label>
<input class="form-control-1-4" id="mobile" type="text"> <input class="form-control-1-4" id="mobile" type="text">
</p> </p>
<p> <p>
<label class="form-label" for="password">Create a password</label> <label class="form-label" for="password">Create a password</label>
<input class="form-control-1-4" id="password" type="password"><br> <input class="form-control-1-4" id="password" type="password"><br>
<span class="font-xsmall">Your password must have at least 10 characters</span></label> <span class="font-xsmall">Your password must have at least 10 characters</span></label>
</p> </p>
<p> <p>
<a class="button" href="verify-mobile" role="button">Continue</a> <a class="button" href="verify-mobile" role="button">Continue</a>
</p> </p>
</div> </div>
</div> </div>
{% endblock %} {% endblock %}

View File

@@ -9,19 +9,19 @@ GOV.UK Notify | Create an account
{% block maincolumn_content %} {% block maincolumn_content %}
<div class="grid-row"> <div class="grid-row">
<div class="column-two-thirds"> <div class="column-two-thirds">
<h1 class="heading-xlarge">Create an account</h1> <h1 class="heading-xlarge">Create an account</h1>
<p>If you've used GOV.UK Notify before, <a href="{{ url_for('.sign_in') }}">sign in to your account</a>.</p> <p>If you've used GOV.UK Notify before, <a href="{{ url_for('.sign_in') }}">sign in to your account</a>.</p>
<form autocomplete="off" action="" method="post"> <form autocomplete="off" action="" method="post">
{{ textbox(form.name) }} {{ textbox(form.name) }}
{{ textbox(form.email_address, hint="Your email address must end in .gov.uk") }} {{ textbox(form.email_address, hint="Your email address must end in .gov.uk") }}
{{ textbox(form.mobile_number) }} {{ textbox(form.mobile_number) }}
{{ textbox(form.password, hint="Your password must have at least 10 characters") }} {{ textbox(form.password, hint="Your password must have at least 10 characters") }}
{{ page_footer("Continue") }} {{ page_footer("Continue") }}
</form> </form>
</div> </div>
</div> </div>
{% endblock %} {% endblock %}

View File

@@ -6,12 +6,12 @@ GOV.UK Notify | Send email
{% block maincolumn_content %} {% block maincolumn_content %}
<h1 class="heading-xlarge">Send email</h1> <h1 class="heading-xlarge">Send email</h1>
<p>This page will be where we construct email messages</p> <p>This page will be where we construct email messages</p>
<p> <p>
<a class="button" href="check-email" role="button">Continue</a> <a class="button" href="check-email" role="button">Continue</a>
</p> </p>
{% endblock %} {% endblock %}

View File

@@ -3,44 +3,44 @@
{% from "components/big-number.html" import big_number %} {% from "components/big-number.html" import big_number %}
{% block page_title %} {% block page_title %}
GOV.UK Notify | Dashboard GOV.UK Notify | Dashboard
{% endblock %} {% endblock %}
{% block maincolumn_content %} {% block maincolumn_content %}
<ul class="grid-row job-totals"> <ul class="grid-row job-totals">
<li class="column-half"> <li class="column-half">
{{ big_number( {{ big_number(
free_text_messages_remaining, free_text_messages_remaining,
'free text messages remaining' 'free text messages remaining'
)}} )}}
</li> </li>
<li class="column-half"> <li class="column-half">
{{ big_number( {{ big_number(
'£' + spent_this_month, '£' + spent_this_month,
'spent this month' 'spent this month'
)}} )}}
</li> </li>
</ul> </ul>
{% call(item) list_table( {% call(item) list_table(
[], [],
caption="Recent text messages", caption="Recent text messages",
empty_message='You havent sent any text messages yet', empty_message='You havent sent any text messages yet',
field_headings=['Job', 'File', 'Time', 'Status'] field_headings=['Job', 'File', 'Time', 'Status']
) %} ) %}
{% call field() %} {% call field() %}
<a href="{{ url_for('.view_job', service_id=service_id, job_id=456) }}">{{ item.file }}</a> <a href="{{ url_for('.view_job', service_id=service_id, job_id=456) }}">{{ item.file }}</a>
{% endcall %} {% endcall %}
{% call field() %} {% call field() %}
<a href="{{ url_for('.view_job', service_id=service_id, job_id=456) }}">{{ item.job }}</a> <a href="{{ url_for('.view_job', service_id=service_id, job_id=456) }}">{{ item.job }}</a>
{% endcall %} {% endcall %}
{% call field() %} {% call field() %}
{{ item.time }} {{ item.time }}
{% endcall %} {% endcall %}
{% call field() %} {% call field() %}
{{ item.status }} {{ item.status }}
{% endcall %} {% endcall %}
{% endcall %} {% endcall %}
{% endblock %} {% endblock %}

View File

@@ -7,26 +7,26 @@ GOV.UK Notify | Get started
{% block maincolumn_content %} {% block maincolumn_content %}
<div class="grid-row"> <div class="grid-row">
<div class="column-two-thirds"> <div class="column-two-thirds">
<h1 class="heading-xlarge">GOV.UK Notify</h1> <h1 class="heading-xlarge">GOV.UK Notify</h1>
<p> <p>
Use GOV.UK Notify to send notifications by text message, email and letter. Use GOV.UK Notify to send notifications by text message, email and letter.
</p> </p>
<p> <p>
We're making it easy to keep your users informed. We're making it easy to keep your users informed.
</p> </p>
<p> <p>
If you work for a UK government department or agency you can set up a test account now. If you work for a UK government department or agency you can set up a test account now.
</p> </p>
<p> <p>
<a class="button" href="{{ url_for('.register' )}}" role="button">Set up an account</a> <a class="button" href="{{ url_for('.register' )}}" role="button">Set up an account</a>
</p> </p>
<p> <p>
If you've used GOV.UK Notify before, <a href="{{ url_for('.sign_in' )}}">sign in to your account</a>. If you've used GOV.UK Notify before, <a href="{{ url_for('.sign_in' )}}">sign in to your account</a>.
</p> </p>
</div> </div>
</div> </div>
{% endblock %} {% endblock %}

View File

@@ -9,17 +9,17 @@ Sign in
{% block maincolumn_content %} {% block maincolumn_content %}
<div class="grid-row"> <div class="grid-row">
<div class="column-two-thirds"> <div class="column-two-thirds">
<h1 class="heading-xlarge">Sign in</h1> <h1 class="heading-xlarge">Sign in</h1>
<p>If you do not have an account, you can <a href="register">register for one now</a>.</p> <p>If you do not have an account, you can <a href="register">register for one now</a>.</p>
<form autocomplete="off" method="post"> <form autocomplete="off" method="post">
{{ textbox(form.email_address) }} {{ textbox(form.email_address) }}
{{ textbox(form.password) }} {{ textbox(form.password) }}
{{ page_footer("Continue", back_link=url_for('.forgot_password'), back_link_text="Forgotten password?") }} {{ page_footer("Continue", back_link=url_for('.forgot_password'), back_link_text="Forgotten password?") }}
</form> </form>
</div> </div>
</div> </div>
{% endblock %} {% endblock %}

View File

@@ -9,20 +9,20 @@ GOV.UK Notify | Text verification
{% block maincolumn_content %} {% block maincolumn_content %}
<div class="grid-row"> <div class="grid-row">
<div class="column-two-thirds"> <div class="column-two-thirds">
<h1 class="heading-xlarge">Text verification</h1> <h1 class="heading-xlarge">Text verification</h1>
<p>We've sent you a text message with a verification code.</p> <p>We've sent you a text message with a verification code.</p>
<form autocomplete="off" method="post"> <form autocomplete="off" method="post">
{{ textbox(form.sms_code) }} {{ textbox(form.sms_code) }}
{{ page_footer( {{ page_footer(
"Continue", "Continue",
back_link=url_for('.verification_code_not_received'), back_link=url_for('.verification_code_not_received'),
back_link_text='I havent received a text' back_link_text='I havent received a text'
) }} ) }}
</form> </form>
</div> </div>
</div> </div>
{% endblock %} {% endblock %}

View File

@@ -7,21 +7,21 @@ GOV.UK Notify | Confirm mobile number
{% block maincolumn_content %} {% block maincolumn_content %}
<div class="grid-row"> <div class="grid-row">
<div class="column-two-thirds"> <div class="column-two-thirds">
<h1 class="heading-xlarge">Confirm your mobile number</h1> <h1 class="heading-xlarge">Confirm your mobile number</h1>
<p>We've sent you a confirmation code by text message.</p> <p>We've sent you a confirmation code by text message.</p>
<p> <p>
<label class="form-label" for="email">Enter confirmation code<br> <label class="form-label" for="email">Enter confirmation code<br>
<input class="form-control-1-4" id="email" type="text"><br> <input class="form-control-1-4" id="email" type="text"><br>
<span class="font-xsmall"><a href="{{ url_for('.text-not-received-2') }}">I haven't received a text</a></span> <span class="font-xsmall"><a href="{{ url_for('.text-not-received-2') }}">I haven't received a text</a></span>
</p> </p>
<p> <p>
<a class="button" href="dashboard" role="button">Continue</a> <a class="button" href="dashboard" role="button">Continue</a>
</p> </p>
</div> </div>
</div> </div>
{% endblock %} {% endblock %}

View File

@@ -9,23 +9,23 @@ GOV.UK Notify | Confirm email address and mobile number
{% block maincolumn_content %} {% block maincolumn_content %}
<div class="grid-row"> <div class="grid-row">
<div class="column-two-thirds"> <div class="column-two-thirds">
<h1 class="heading-xlarge">Activate your account</h1> <h1 class="heading-xlarge">Activate your account</h1>
<p>We've sent you confirmation codes by email and text message. You need to enter both codes here.</p> <p>We've sent you confirmation codes by email and text message. You need to enter both codes here.</p>
<form autocomplete="off" method="post"> <form autocomplete="off" method="post">
{{ textbox(form.email_code) }} {{ textbox(form.email_code) }}
<p> <p>
<a href="{{ url_for('.check_and_resend_email_code')}}">I haven't received an email</a> <a href="{{ url_for('.check_and_resend_email_code')}}">I haven't received an email</a>
</p> </p>
{{ textbox(form.sms_code) }} {{ textbox(form.sms_code) }}
<p> <p>
<a href="{{ url_for('.check_and_resend_text_code') }}">I haven't received a text</a></span> <a href="{{ url_for('.check_and_resend_text_code') }}">I haven't received a text</a></span>
</p> </p>
{{ page_footer("Continue") }} {{ page_footer("Continue") }}
</form> </form>
</div> </div>
</div> </div>
{% endblock %} {% endblock %}