mirror of
https://github.com/cwinfo/powerdns-admin.git
synced 2025-07-04 05:07:45 +00:00
Added Jinja filter for handle formatting of zone type labels to enforce modern social standards.
Removed text label of dashboard domain list action menu to reduce size. Continuing work on re-design and clean-up of dashboard view.
This commit is contained in:
@ -132,6 +132,16 @@ def display_master_name(data):
|
||||
return ", ".join(matches)
|
||||
|
||||
|
||||
def format_zone_type(data):
|
||||
"""Formats the given zone type for modern social standards."""
|
||||
data = str(data).lower()
|
||||
if data == 'master':
|
||||
data = 'primary'
|
||||
elif data == 'slave':
|
||||
data = 'secondary'
|
||||
return data.title()
|
||||
|
||||
|
||||
def display_time(amount, units='s', remove_seconds=True):
|
||||
"""
|
||||
Convert timestamp to normal time format
|
||||
|
Reference in New Issue
Block a user