2024-07-03 17:20:01 +00:00
|
|
|
{% extends "base.html" %}
|
|
|
|
{% comment %}
|
|
|
|
SPDX-License-Identifier: GPL-3.0-or-later
|
|
|
|
{% endcomment %}
|
|
|
|
{% load i18n crispy_forms_tags %}
|
|
|
|
|
|
|
|
{% block content %}
|
|
|
|
<div class="card bg-white mb-3">
|
2024-08-06 13:20:22 +00:00
|
|
|
<h3 class="card-header text-center">
|
2024-08-13 23:32:55 +00:00
|
|
|
HTML finished <br>
|
2024-08-06 13:20:22 +00:00
|
|
|
{{ title }}
|
|
|
|
</h3>
|
|
|
|
<div class="card-body">
|
2024-08-13 23:32:55 +00:00
|
|
|
<p>{% trans 'QR-code number' %} : {{ qrcode.qr_code_number }}</p>
|
2024-08-06 13:20:22 +00:00
|
|
|
<p>{% trans 'Name' %} : {{ qrcode.food_container.name }}</p>
|
2024-08-13 23:32:55 +00:00
|
|
|
<p>{% trans 'Owner' %} : {{ qrcode.food_container.owner }}</p>
|
|
|
|
<p>{% trans 'Expiry date' %} : {{ qrcode.food_container.expiry_date }}</p>
|
|
|
|
{% if qrcode.food_container.polymorphic_ctype.model == 'basicfood' and can_update_basic %}
|
|
|
|
<a class="btn btn-sm btn-warning" href="{% url "food:basic_update" pk=qrcode.food_container.pk %}" data-turbolinks="false">
|
|
|
|
{% trans 'Update' %}
|
|
|
|
</a>
|
|
|
|
{% elif can_update_transformed %}
|
|
|
|
<a class="btn btn-sm btn-warning" href="{% url "food:transformed_update" pk=qrcode.food_container.pk %}">
|
|
|
|
{% trans 'Update' %}
|
|
|
|
</a>
|
2024-08-06 13:20:22 +00:00
|
|
|
{% endif %}
|
2024-08-13 23:32:55 +00:00
|
|
|
{% if can_add_ingredient %}
|
|
|
|
<a class="btn btn-sm btn-success" href="{% url "food:add_ingredient" pk=qrcode.food_container.pk %}">
|
|
|
|
{% trans 'Add the ingredient' %}
|
|
|
|
</a>
|
|
|
|
{% endif %}
|
|
|
|
</div>
|
2024-07-03 17:20:01 +00:00
|
|
|
</div>
|
|
|
|
{% endblock %}
|