You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
70 lines
2.0 KiB
HTML
70 lines
2.0 KiB
HTML
{% extends 'base.html' %}
|
|
|
|
|
|
{% block title %}{{ menu.name }}{% endblock %}
|
|
|
|
{% block header %}<h1>{{ menu.name }}</h1>{% endblock %}
|
|
|
|
{% block content %}
|
|
|
|
<div class="detail-container">
|
|
<p>
|
|
<a class="btn" href="{% url 'mensaviewer:like' menu.id %}?next={{ request.path }}">Like</a>
|
|
<a class="btn" href="{% url 'mensaviewer:dislike' menu.id %}?next={{ request.path }}">Dislike</a>
|
|
<a class="btn" href="{% url 'mensaviewer:comment_add' menu.id %}">Comment</a>
|
|
</p>
|
|
<h3>Prices</h3>
|
|
<table>
|
|
<tr>
|
|
<th>Students</th>
|
|
<th>Employees</th>
|
|
<th>Guests</th>
|
|
</tr>
|
|
<tr>
|
|
<td>{{ menu.get_price.Student }}</td>
|
|
<td>{{ menu.get_price.Employee }}</td>
|
|
<td>{{ menu.get_price.Guest }}</td>
|
|
</tr>
|
|
</table>
|
|
<h4>Art</h4>
|
|
<p>{{ menu.art }}</p>
|
|
<hr>
|
|
<h4>Allergens</h4>
|
|
<p>{{ menu.get_allergens }}</p>
|
|
<hr>
|
|
<h4>Types</h4>
|
|
<p>{{ menu.get_types }}</p>
|
|
<hr>
|
|
<h4>Rating</h4>
|
|
<p>{{ menu.likes }}</p>
|
|
<hr>
|
|
<h4>Location and Date</h4>
|
|
<p><a href="{% url 'mensaviewer:location_detail' menu.location.pk %}">{{ menu.location.city }} {{ menu.location.name }}</a> | {{ menu.day }}</p>
|
|
<hr>
|
|
<div class="related-items">
|
|
<h3>Comments</h3>
|
|
<table class="comment-list">
|
|
<tr>
|
|
<th>Text</th>
|
|
<th>Author</th>
|
|
<th>Timestamp</th>
|
|
<th>Menu</th>
|
|
<th></th>
|
|
<th></th>
|
|
</tr>
|
|
{% for comment in menu.comments %}
|
|
<tr>
|
|
<td><a href="{% url 'mensaviewer:comment_detail' comment.pk %}">{{ comment.text }}</a></td>
|
|
<td>{{ comment.author }}</td>
|
|
<td class="fit-width">{{ comment.timestamp }}</td>
|
|
<td><a href="{% url 'mensaviewer:menu_detail' comment.menu.pk %}">{{ comment.menu }}</a></td>
|
|
<td class="fit-width"><a href="{% url 'mensaviewer:comment_update' comment.pk %}">Edit</a></td>
|
|
<td class="fit-width"><a href="{% url 'mensaviewer:comment_delete' comment.pk %}">Delete</a></td>
|
|
</tr>
|
|
{% endfor %}
|
|
</table>
|
|
</div>
|
|
</div>
|
|
|
|
{% endblock %}
|