diff --git a/app/templates/dashboard.html b/app/templates/dashboard.html
index b57e6fa..819130b 100644
--- a/app/templates/dashboard.html
+++ b/app/templates/dashboard.html
@@ -84,10 +84,10 @@
-
+
Changed By |
@@ -97,20 +97,18 @@
-
-
- ivan
- |
-
- log log log
- |
-
- 5:52pm 21/4/2016
- |
-
- Detail button
- |
-
+ {% for history in histories %}
+
+ {{ history.created_by }} |
+ {{ history.msg }} |
+ {{ history.created_on }} |
+
+
+ |
+
+ {% endfor %}
@@ -203,3 +201,48 @@
{% endblock %}
+{% block extrascripts %}
+
+{% endblock %}
+{% block modals %}
+
+
+{% endblock %}
diff --git a/app/views.py b/app/views.py
index a297059..49d43be 100644
--- a/app/views.py
+++ b/app/views.py
@@ -139,13 +139,14 @@ def dashboard():
domains = Domain.query.all()
users = User.query.all()
history_number = History.query.count()
+ history = History.query.limit(4)
server = Server(server_id='localhost')
statistics = server.get_statistic()
if statistics:
uptime = filter(lambda uptime: uptime['name'] == 'uptime', statistics)[0]['value']
else:
uptime = 0
- return render_template('dashboard.html', domains=domains, users=users, history_number=history_number, uptime=uptime)
+ return render_template('dashboard.html', domains=domains, users=users, history_number=history_number, uptime=uptime, histories=history)
@app.route('/domain/', methods=['GET', 'POST'])