new migrations in apps.epic & apps.lyric apps; new Token fields of latter articulate upon Room model helper fns of former; new FTs, ITs & UTs capture new behavior accordingly; new template partial content in templates/apps/gameboard
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
<div class="gate-slots">
|
||||
{% for slot in slots %}
|
||||
<div
|
||||
class="gate-slot{% if slot.status == 'EMPTY' %} empty{% endif %}"
|
||||
class="gate-slot{% if slot.status == 'EMPTY' %} empty{% elif slot.status == 'FILLED' %} filled{% endif %}"
|
||||
data-slot="{{ slot.slot_number }}"
|
||||
>
|
||||
<span class="slot-number">{{ slot.slot_number }}</span>
|
||||
@@ -17,9 +17,12 @@
|
||||
{% else %}
|
||||
<span class="slot-gamer">empty</span>
|
||||
{% endif %}
|
||||
{% if slot.slot_number == 1 and request.user == room.owner %}
|
||||
<button class="drop-token-btn">Drop Token</button>
|
||||
{% endif %}
|
||||
{% if slot.slot_number == 1 and request.user == room.owner and slot.status == 'EMPTY' %}
|
||||
<form method="POST" action="{% url "epic:drop_token" room.id slot.slot_number %}">
|
||||
{% csrf_token %}
|
||||
<button type="submit" class="btn drop-token-btn btn-primary btn-xl">Drop Token</button>
|
||||
</form>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user