From 6000437d46304eabcdcf5923e05de4befda805d7 Mon Sep 17 00:00:00 2001 From: b10n1k Date: Thu, 16 May 2013 02:42:58 +0300 Subject: [PATCH 1/2] add asteriss to the required fields --- anapneo/neo/models.py | 6 +++--- anapneo/static/css/app.less | 6 ++++++ anapneo/templates/neo_edit_or_create.html | 19 +++++++++---------- 3 files changed, 18 insertions(+), 13 deletions(-) diff --git a/anapneo/neo/models.py b/anapneo/neo/models.py index 5b69c61..f9350c1 100644 --- a/anapneo/neo/models.py +++ b/anapneo/neo/models.py @@ -33,11 +33,11 @@ class Neo(models.Model): magnitude = models.CharField(max_length=100, verbose_name="Magnitude") created = models.DateTimeField(max_length=100, default=datetime.now) updated = models.DateTimeField(max_length=100, verbose_name="Latest Observation") - note = models.TextField(max_length=300, verbose_name="Notes", blank=True) + note = models.TextField(max_length=300, verbose_name="Notes", blank=True)#not required num_obs = models.PositiveIntegerField(verbose_name="Number of Observations") arc = models.FloatField(verbose_name="Arc", validators=[MinValueValidator(0.0)]) - nominal_h = models.FloatField(verbose_name="Nominal H", blank=True, validators=[MinValueValidator(0.0)]) - image = models.ImageField(upload_to='.', verbose_name="Image", blank=True) + nominal_h = models.FloatField(verbose_name="Nominal H", blank=True, validators=[MinValueValidator(0.0)])#not required + image = models.ImageField(upload_to='.', verbose_name="Image", blank=True)#not required class Feedback(models.Model): diff --git a/anapneo/static/css/app.less b/anapneo/static/css/app.less index 5c1f3f1..4defc30 100644 --- a/anapneo/static/css/app.less +++ b/anapneo/static/css/app.less @@ -79,3 +79,9 @@ img.neo-image { height: 300px; border-style: none; } + +.required{ + color: red; + margin-right: 5px; + +} \ No newline at end of file diff --git a/anapneo/templates/neo_edit_or_create.html b/anapneo/templates/neo_edit_or_create.html index b8a391f..1d8a5c6 100644 --- a/anapneo/templates/neo_edit_or_create.html +++ b/anapneo/templates/neo_edit_or_create.html @@ -10,7 +10,7 @@

- +

- +

@@ -36,25 +35,25 @@

- +

- +

- +

- +

- +

@@ -62,7 +61,7 @@

-