V3 deprecation warning
This commit is contained in:
parent
d3052e0489
commit
6ad5d85b78
2 changed files with 2 additions and 1 deletions
|
@ -32,6 +32,7 @@ class Model(models.Model):
|
||||||
config = models.TextField("OpenWRT Compile Config", blank=True, null=True)
|
config = models.TextField("OpenWRT Compile Config", blank=True, null=True)
|
||||||
firmware = models.DateTimeField("Firmware Modification Date", auto_now=True)
|
firmware = models.DateTimeField("Firmware Modification Date", auto_now=True)
|
||||||
wwan = models.BooleanField("Supports WWAN (External WiFi)", default=False)
|
wwan = models.BooleanField("Supports WWAN (External WiFi)", default=False)
|
||||||
|
deprecated = models.BooleanField("Outdated device type", default=False)
|
||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
return self.name
|
return self.name
|
||||||
|
|
|
@ -36,7 +36,7 @@
|
||||||
{% userDevices as devices %}
|
{% userDevices as devices %}
|
||||||
{% for device in devices %}
|
{% for device in devices %}
|
||||||
<tr data-orga="[{{ device.organization.id }}]">
|
<tr data-orga="[{{ device.organization.id }}]">
|
||||||
<td><div style="display: inline; color: grey; font-weight: bold;" title="No information available" id="{{ device.id }}-indicator">⬤</div> <div style="display: inline;" {% if user.is_superuser %}title="{{ device.organization.name }}"{% endif %} id="{{ device.id }}-id">{{ device.serial }}{% if device.ssid %}<br><small>SSID: {{ device.ssid }}</small>{% endif %}</div></td>
|
<td><div style="display: inline; color: grey; font-weight: bold;" title="No information available" id="{{ device.id }}-indicator">⬤</div>{% if device.model.deprecated %} <i style="color: red;" title="Device outdated – please contact us to replace it with a new one" class="fas fa-exclamation-triangle"></i>{% endif %} <div style="display: inline;" {% if user.is_superuser %}title="{{ device.organization.name }}"{% endif %} id="{{ device.id }}-id">{{ device.serial }}{% if device.ssid %}<br><small>SSID: {{ device.ssid }}</small>{% endif %}</div></td>
|
||||||
<td id="{{ device.id }}-name">{% if device.name %}{{ device.name }}{% endif %}</td>
|
<td id="{{ device.id }}-name">{% if device.name %}{{ device.name }}{% endif %}</td>
|
||||||
<td id="{{ device.id }}-network">{{ device.network }}</td>
|
<td id="{{ device.id }}-network">{{ device.network }}</td>
|
||||||
<td><div style="display:inline;" id="{{ device.id }}-ip">{% if device.curip %}{{ device.curip }} (at {{ device.lasttime }}){% endif %}</div></td>
|
<td><div style="display:inline;" id="{{ device.id }}-ip">{% if device.curip %}{{ device.curip }} (at {{ device.lasttime }}){% endif %}</div></td>
|
||||||
|
|
Loading…
Reference in a new issue