Files
notifications-admin/app/main/views/history.py
Chris Hill-Scott 7c2ecfa094 Use service model for history
Rather than have the view layer interact directly with the API client.
This will let us add extra transformation in the model layer at some
point.
2019-10-21 16:29:06 +01:00

18 lines
490 B
Python

from flask import render_template
from app import current_service
from app.main import main
from app.utils import user_has_permissions
@main.route("/services/<service_id>/history")
@user_has_permissions('manage_service')
def history(service_id):
return render_template(
'views/temp-history.html',
services=current_service.history['service_history'],
api_keys=current_service.history['api_key_history'],
events=current_service.history['events']
)