Skip to content
Merged

Dev #124

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 18 additions & 12 deletions templates/index/wallet.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,24 @@
<div class="full-container">
<div class="container">
{% include 'components/tabbar.html' %}
<div class="row table-header">
<div class="col-md-4">Name</div>
<div class="col-md-4">Amount</div>
<div class="col-md-4">Redeem</div>
</div>
{% for wallet in wallets %}
<div class="row table-content">
<div class="col-md-4">{{ wallet.name }}</div>
<div class="col-md-4">{{ wallet.amount }}</div>
<div class="col-md-4"><a href="{% url 'customer:motherload' %}">redeem</a></div>
</div>
{% endfor %}
<table class="table table-bordered">
<thead>
<tr>
<th class="text-center">Name</th>
<th class="text-center">Amount</th>
<th class="text-center">Redeem</th>
</tr>
</thead>
<tbody>
{% for wallet in wallets %}
<tr>
<td>{{ wallet.name }}</td>
<td>{{ wallet.amount }}</td>
<td><a href="{% url 'customer:motherload' %}">redeem</a></td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
</div>

Expand Down
46 changes: 26 additions & 20 deletions templates/store/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,26 +17,32 @@ <h1>You are : {{ user.username }}</h1>
</button>
</a>
</div>
<div class="row table-header">
<div class="col-xs-12 col-md-2">Name</div>
<div class="col-xs-12 col-md-2">Price</div>
<div class="col-xs-12 col-md-2">Detail</div>
<div class="col-xs-12 col-md-2">Date</div>
<div class="col-xs-12 col-md-2">Edit</div>
<div class="col-xs-12 col-md-2">Delete</div>
</div>
{% for ticket in tickets %}
<div class="row table-content">
<div class="col-xs-12 col-md-2">{{ ticket.name }}</div>
<div class="col-xs-12 col-md-2">{{ ticket.price }} {{ ticket.currency }}</div>
<div class="col-xs-12 col-md-2">{{ ticket.detail }}</div>
<div class="col-xs-12 col-md-2">{{ ticket.expire_date }}</div>
<div class="col-xs-12 col-md-2"><a href="{% url 'store:ticket-edit' ticket.id %}">edit</a></div>
<div class="col-xs-12 col-md-2">
<a onclick="deleteTicket('{% url 'store:ticket-delete' ticket.id %}')">delete</a>
</div>
</div>
{% endfor %}
<table class="table table-bordered">
<thead>
<tr>
<th>Name</th>
<th>Price</th>
<th>Detail</th>
<th>Date</th>
<th>Edit</th>
<th>Delete</th>
</tr>
</thead>
<tbody>
{% for ticket in tickets %}
<tr>
<td>{{ ticket.name }}</td>
<td>{{ ticket.price }} {{ ticket.currency }}</td>
<td>{{ ticket.detail }}</td>
<td>{{ ticket.expire_date }}</td>
<td><a href="{% url 'store:ticket-edit' ticket.id %}">edit</a></td>
<td>
<a onclick="deleteTicket('{% url 'store:ticket-delete' ticket.id %}')">delete</a>
</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
<script>
function deleteTicket(ticketUrl) {
Expand Down