mirror of
https://github.com/netbox-community/netbox.git
synced 2026-03-29 22:02:11 +02:00
Added uniquieness constraint to Secret
This commit is contained in:
@@ -195,6 +195,7 @@ class Secret(models.Model):
|
||||
|
||||
class Meta:
|
||||
ordering = ['device', 'role', 'name']
|
||||
unique_together = ['device', 'role', 'name']
|
||||
|
||||
def __init__(self, *args, **kwargs):
|
||||
self.plaintext = kwargs.pop('plaintext', None)
|
||||
|
||||
Reference in New Issue
Block a user