mirror of
https://github.com/cwinfo/powerdns-admin.git
synced 2025-01-08 03:15:40 +00:00
Add more detailed info to the history when a msg and status exists
This commit is contained in:
parent
e891333971
commit
3df36adbf4
@ -883,6 +883,16 @@ class DetailedHistory():
|
|||||||
domain_type=DetailedHistory.get_key_val(detail_dict, "domain_type"),
|
domain_type=DetailedHistory.get_key_val(detail_dict, "domain_type"),
|
||||||
domain_master_ips=DetailedHistory.get_key_val(detail_dict, "domain_master_ips"))
|
domain_master_ips=DetailedHistory.get_key_val(detail_dict, "domain_master_ips"))
|
||||||
|
|
||||||
|
elif DetailedHistory.get_key_val(detail_dict, 'msg') and DetailedHistory.get_key_val(detail_dict, 'status'):
|
||||||
|
self.detailed_msg = render_template_string('''
|
||||||
|
<table class="table table-bordered table-striped">
|
||||||
|
<tr><td>Status: </td><td>{{ history_status }}</td></tr>
|
||||||
|
<tr><td>Message:</td><td>{{ history_msg }}</td></tr>
|
||||||
|
</table>
|
||||||
|
''',
|
||||||
|
history_status=DetailedHistory.get_key_val(detail_dict, 'status'),
|
||||||
|
history_msg=DetailedHistory.get_key_val(detail_dict, 'msg'))
|
||||||
|
|
||||||
# check for lower key as well for old databases
|
# check for lower key as well for old databases
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def get_key_val(_dict, key):
|
def get_key_val(_dict, key):
|
||||||
|
Loading…
Reference in New Issue
Block a user