diff --git a/map/fields.py b/map/fields.py index ad7eab7..052475d 100644 --- a/map/fields.py +++ b/map/fields.py @@ -6,6 +6,6 @@ class CoordinateField(models.DecimalField): kwargs['max_digits'] = 11 kwargs['decimal_places'] = 8 kwargs['help_text'] = ('Format : xxx,xxxxxxxx
' - '(max 8 décimales, max 3 chiffres avant la virgule, séparateur : virgule)') + '(max 8 decimal places, max 3 digits before comma, separator : comma)') super().__init__(*args, **kwargs) diff --git a/map/migrations/0006_auto_20190303_1308.py b/map/migrations/0006_auto_20190303_1308.py new file mode 100644 index 0000000..a30be14 --- /dev/null +++ b/map/migrations/0006_auto_20190303_1308.py @@ -0,0 +1,23 @@ +# Generated by Django 2.1.7 on 2019-03-03 12:08 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('map', '0005_auto_20190302_1457'), + ] + + operations = [ + migrations.AlterField( + model_name='friendlocation', + name='end_date', + field=models.DateField(blank=True, help_text='Format : YYYY-MM-DD, example : 2018-05-31', null=True, verbose_name='until'), + ), + migrations.AlterField( + model_name='friendlocation', + name='start_date', + field=models.DateField(blank=True, help_text='Format : YYYY-MM-DD, example : 2018-05-31', null=True, verbose_name='from'), + ), + ] diff --git a/map/models.py b/map/models.py index 5aa574c..0d88eb4 100644 --- a/map/models.py +++ b/map/models.py @@ -24,8 +24,8 @@ class Friend(AbstractUser): class FriendLocation(BaseModel): latitude = CoordinateField() longitude = CoordinateField() - start_date = models.DateField('from', blank=True, null=True) - end_date = models.DateField('until', blank=True, null=True) + start_date = models.DateField('from', blank=True, null=True, help_text='Format : YYYY-MM-DD, example : 2018-05-31') + end_date = models.DateField('until', blank=True, null=True, help_text='Format : YYYY-MM-DD, example : 2018-05-31') friend = models.OneToOneField(Friend, on_delete=models.CASCADE, related_name='location') @property