Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion hackspace_storage/main/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ def validate_expiry_date(self, field: DateField):
booking.reminder_sent = True
db.session.commit()
else:
reminder_date=reminder_date.strftime("%d-%b-%Y")
reminder_date=reminder_date.strftime("%d %b %Y")

send_email(
g.user,
Expand Down
5 changes: 5 additions & 0 deletions hackspace_storage/static/css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
"Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
--header-font: "ocr-a-extended", sans-serif;
--grid-maxWidth: 100rem;
--grid-storageWidth: 140rem;
--grid-gutter: 2rem;
--col-gap: 0.8rem;
--row-gap: 1.0rem;
Expand Down Expand Up @@ -114,6 +115,10 @@ dd {
padding: 0 calc(var(--grid-gutter) / 2);
}

.container.storage {
max-width: var(--grid-storageWidth);
}

.navbar {
display: flex;
flex-wrap: wrap;
Expand Down
4 changes: 2 additions & 2 deletions hackspace_storage/templates/email/slot_booked.txt.j2
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
Hello {{user.name}},

{% if reminder_date %}
This is an email to confirm you have booked slot {{slot.area.name}} {{slot.name}}. This slot will expire on {{booking.expiry.strftime("%d-%b-%Y")}} and we will send an expiry reminder on {{reminder_date}}. You will be able to extend the booking in-person on this date.
This is an email to confirm you have booked slot {{slot.area.name}} {{slot.name}}. This slot will expire on {{booking.expiry.strftime("%d %b %Y")}} and we will send an expiry reminder on {{reminder_date}}. You will be able to extend the booking in-person on this date.
{% else %}
This is an email to confirm you have booked slot {{slot.area.name}} {{slot.name}}. This slot will expire on {{booking.expiry.strftime("%d-%b-%Y")}}. You can extend this booking in-person if required.
This is an email to confirm you have booked slot {{slot.area.name}} {{slot.name}}. This slot will expire on {{booking.expiry.strftime("%d %b %Y")}}. You can extend this booking in-person if required.
{% endif %}

If you want to cancel this booking you can do so at the Hackspace, or remotely using this link: {{ url_for('main.free_booking_email', booking_id=booking.id, token=booking.secret, _external=True) }}.
6 changes: 3 additions & 3 deletions hackspace_storage/templates/main/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
{% block title %}Home{% endblock %}

{% block contents %}
<div class="container">
<div class="container storage">

{% if g.user %}
<h1>Hi, {{ g.user.name }}.</h1>
Expand All @@ -22,7 +22,7 @@ <h3 class="float-right">{{ booking.slot.name }}</h3>
</div>
<div class="card-body">
<p>{{ booking.description }}</p>
<p> Expires: {{ booking.expiry.strftime("%d-%b-%Y") }}</p>
<p> Expires: {{ booking.expiry.strftime("%d %b %Y") }}</p>
</div>
<div class="card-footer-user">
<a class="cancel-button" href="{{ url_for('main.free_booking', booking_id=booking.id) }}">Cancel</a>
Expand Down Expand Up @@ -62,7 +62,7 @@ <h3 class="float-right">{{ this_booking.user.name }}</h3>
<p>{{ this_booking.description }}</p>
</div>
<div class="card-footer">
<p> Expires: {{ this_booking.expiry.strftime("%d-%b-%Y") }}</p>
<p> Expires: {{ this_booking.expiry.strftime("%d %b %Y") }}</p>
</div>
{% else %}
<div class="card-body">
Expand Down