diff --git a/models.py b/models.py index dacd021..a3d72ae 100644 --- a/models.py +++ b/models.py @@ -375,6 +375,13 @@ class IP(models.Model): verbose_name = "IP" verbose_name_plural = "IPs" + @property + def last_used_formatted(self): + if self.last_used: + return self.last_used + else: + return "N/A" + @property def associated(self): ips = IP.objects.filter(ip=self.ip) diff --git a/templates/minecraft_manager/ip.html b/templates/minecraft_manager/ip.html index ec1023e..c8e51ac 100644 --- a/templates/minecraft_manager/ip.html +++ b/templates/minecraft_manager/ip.html @@ -14,7 +14,7 @@ {% for i in ips %}