Work on the register UI
This commit is contained in:
1 parent
7a15006455
commit
135fe821e1
16 files changed
+290
-167
No files matched your search
+42
-20
@@ -1,29 +1,51 @@
|
||||
{% extends "base.html" %}
|
||||
{%block header%}
|
||||
{% block header %}
|
||||
<h1>Biceps Bar System</h1>
|
||||
{%endblock%}
|
||||
<nav>
|
||||
<ul>
|
||||
<li><a href="{% url main.views.logout %}">Logout</a></li>
|
||||
</ul>
|
||||
</nav>
|
||||
{% endblock %}
|
||||
|
||||
{%block content%}
|
||||
<section id="nav">
|
||||
{% block content %}
|
||||
<section id="register">
|
||||
<form id="order" method="post">
|
||||
{% csrf_token %}
|
||||
<section id="customer">
|
||||
<h2>Velg kunde</h2>
|
||||
<input type="hidden" name="customer" value="" />
|
||||
<ul>
|
||||
<li><a href="{% url main.views.logout %}">Logout</a></li>
|
||||
{% for user in users %}
|
||||
<li class="customer">
|
||||
{% if user.get_profile.image %}
|
||||
<img class="profile" src="{{ user.get_profile.image.url }}" /><br />
|
||||
{% else %}
|
||||
<img class="profile" src="/static/gaute/images/unknown.png" /><br />
|
||||
{% endif %}
|
||||
<span class="name">{{ user }}</span> ({{ user.get_profile.balance }})</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</section>
|
||||
<section id="register">
|
||||
<div id="user">
|
||||
Selg til:
|
||||
{% for user in users %}
|
||||
<button id="{{ user }}">{{ user }}</button>
|
||||
{% endfor %}
|
||||
</div>
|
||||
<div id="products">
|
||||
Vi selger:<br />
|
||||
<section id="products">
|
||||
<h2>Velg antall</h2>
|
||||
<ul>
|
||||
{% for product in products %}
|
||||
<button id="{{ product.id }}">+ {{ product.name }}</button>
|
||||
<button id="{{ product.id }}">- {{ product.name }}</button>
|
||||
<li id="form-{{forloop.counter0}}" class="product"><input type="hidden" name="form-{{ forloop.counter0 }}-product" value="{{product.id }}" />
|
||||
<input type="text" id="form-{{ forloop.counter0 }}-amount" name="form-{{ forloop.counter0 }}-amount" value="0" size="2" />
|
||||
{% if product.image %}
|
||||
<img class="product" src="{{ product.image.url }}" /><br />
|
||||
{% else %}
|
||||
<img class="product" src="/static/gaute/images/product.png" /><br />
|
||||
{% endif %}
|
||||
{{ product.name }}
|
||||
</li>
|
||||
{% endfor %}
|
||||
</div>
|
||||
<div id="total">Totalt: <span class="total_text"></span></div>
|
||||
<button id="submit">Kjøp</button>
|
||||
</ul>
|
||||
</section>
|
||||
{%endblock%}
|
||||
<section id="total"><h3>Totalt</h3><span class="total_text"></span></section>
|
||||
<input type="reset" id="reset" value="Start på nytt" />
|
||||
<input type="submit" id="submit_order" name="submit_order" value="Kjøp" />
|
||||
</form>
|
||||
</section>
|
||||
{% endblock %}
|
||||
Reference in new issue
Block a user