|
@@ -160,6 +160,12 @@ class Antenna(models.Model):
|
|
verbose_name='Adresse MAC')
|
|
verbose_name='Adresse MAC')
|
|
notes = models.TextField(blank=True)
|
|
notes = models.TextField(blank=True)
|
|
position = geo_models.PointField(null=True, blank=True)
|
|
position = geo_models.PointField(null=True, blank=True)
|
|
|
|
+ orientation = models.IntegerField(verbose_name='Orientation (°)', null=True, blank=True)
|
|
|
|
+
|
|
|
|
+ def clean(self):
|
|
|
|
+ super().clean()
|
|
|
|
+ if self.orientation:
|
|
|
|
+ self.orientation = self.orientation % 360
|
|
|
|
|
|
class Meta:
|
|
class Meta:
|
|
verbose_name = 'antenne'
|
|
verbose_name = 'antenne'
|