Browse Source

Add sensible ordering to items

Improve experience when adding a new item lease in admin.
Jocelyn Delalande 6 years ago
parent
commit
f78c477fb2
1 changed files with 1 additions and 0 deletions
  1. 1 0
      hardware_provisioning/models.py

+ 1 - 0
hardware_provisioning/models.py

@@ -112,6 +112,7 @@ class Item(models.Model):
 
 
     class Meta:
     class Meta:
         verbose_name = 'objet'
         verbose_name = 'objet'
+        ordering = ['designation', 'mac_address', 'serial']
 
 
     def give_back(self, storage=None):
     def give_back(self, storage=None):
         self.storage = storage
         self.storage = storage