4 lines
1.2 KiB
HTML
4 lines
1.2 KiB
HTML
{% extends 'planner/base.html' %}{% load static %}
|
|
{% block title %}Add to Kitchen Inventory · Tasknest{% endblock %}
|
|
{% block content %}<link rel="stylesheet" href="{% static 'groceries/groceries.css' %}?v=2"><div class="grocery-page"><a href="{% url 'groceries:index' %}">← Grocery list</a><h1>Add purchased item to inventory</h1><section class="grocery-panel"><p><strong>{{ item.name }}</strong> · {{ item.quantity|floatformat:-3 }} {{ item.unit }}</p>{% if item.inventory_transferred_at %}<p>This item was already added to Kitchen Inventory.</p>{% else %}<p>Confirm the product and location. This creates stock only when you submit this form.</p><form method="post" class="grocery-add">{% csrf_token %}<label>Food product<select name="product_id" required><option value="">Choose a product</option>{% for product in products %}<option value="{{ product.api_id }}"{% if product.pk == item.product_id %} selected{% endif %}>{{ product.product_name }}{% if product.brand %} · {{ product.brand }}{% endif %}</option>{% endfor %}</select></label><label>Kitchen location<input name="location" value="Pantry" maxlength="100" required></label><button type="submit">Confirm and add stock</button></form>{% endif %}</section></div>{% endblock %}
|