mirror of
https://github.com/welton89/RRBEC.git
synced 2026-04-05 13:35:42 +00:00
feat: update status comanda for PAYING
This commit is contained in:
@@ -20,7 +20,13 @@ Comandas
|
||||
|
||||
<a href="{% url 'viewcomanda' %}?parametro={{ comanda.id }}" style="text-decoration: none;">
|
||||
<article >
|
||||
<header> {{comanda.name}} | {{comanda.mesa}}</header><br>
|
||||
<header
|
||||
{% if comanda.status == 'OPEN' %}
|
||||
style="background-color: #036800;"
|
||||
{% elif comanda.status == 'PAYING' %}
|
||||
style="background-color: rgb(165, 86, 33);"
|
||||
{% endif %}
|
||||
> {{comanda.name}} | {{comanda.mesa}}</header><br>
|
||||
<p>Aberta ás: {{comanda.dt_open|date:"H:i"}}</p>
|
||||
|
||||
|
||||
|
||||
@@ -21,8 +21,24 @@ Detalhes {{comanda.name}}
|
||||
<body>
|
||||
<div class="grid-container" >
|
||||
<div>
|
||||
<button class="primary" id="openModal">Adicionar Produto</button>
|
||||
<button id="pagarComanda">Pagar Comanda</button>
|
||||
<button class="primary" id="openModal"
|
||||
{% if comanda.status != 'OPEN'%}
|
||||
disabled
|
||||
{% endif %}
|
||||
>Adicionar Produto</button>
|
||||
|
||||
<button id="pagarComanda" hx-get="{% url 'closeComanda' comanda.id %} " hx-trigger="click"
|
||||
{% if comanda.status != 'OPEN' %}
|
||||
style="display: none;"
|
||||
{% endif %}
|
||||
>Fechar Comanda</button>
|
||||
|
||||
<button id="pagarComanda"
|
||||
{% if comanda.status != 'PAYING' %}
|
||||
style="display: none;"
|
||||
{% endif %}
|
||||
>Receber</button>
|
||||
|
||||
<button class="button" id="imprimirFichas" onclick="imprimirFichas()">Imprimir Fichas</button>
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user