mirror of
https://github.com/OpenBankProject/API-Manager.git
synced 2026-02-06 10:59:00 +00:00
Added a bit of statistics to consumers
This commit is contained in:
parent
2b2ff18ffd
commit
c253f8f730
@ -28,10 +28,15 @@
|
||||
{% include "consumers/includes/filter_apptype.html" %}
|
||||
</div>
|
||||
|
||||
<h2>Statistics</h2>
|
||||
<ul id="statistics">
|
||||
<li>Total number of consumers: {{ consumers_num }}</li>
|
||||
</ul>
|
||||
|
||||
<div class="table-responsive">
|
||||
<table class="table table-hover" id="consumer-list">
|
||||
<thead>
|
||||
<th>No</th>
|
||||
<th>Name</th>
|
||||
<th>Developer Email</th>
|
||||
<th>Created</th>
|
||||
@ -40,6 +45,7 @@
|
||||
<tbody>
|
||||
{% for consumer in consumers %}
|
||||
<tr class="consumer-row {% if consumer.enabled %}consumer-enabled{% else %}consumer-disabled{% endif %}" data-consumer-id="{{ consumer.id }}">
|
||||
<td>{{ forloop.counter }}</td>
|
||||
<td class="select">{{ consumer.name }}</td>
|
||||
<td class="select">{{ consumer.developerEmail }}</td>
|
||||
<td class="select">{{ consumer.created|naturaltime }}</td>
|
||||
|
||||
@ -62,6 +62,7 @@ class IndexView(LoginRequiredMixin, TemplateView):
|
||||
|
||||
context.update({
|
||||
'consumers': filtered,
|
||||
'consumers_num': len(filtered),
|
||||
'consumers_json': json.dumps(filtered, default=json_serial),
|
||||
})
|
||||
return context
|
||||
|
||||
Loading…
Reference in New Issue
Block a user