Skip to content

Commit

Permalink
Copied and modified date_help_text to date_help_text_non_future
Browse files Browse the repository at this point in the history
  • Loading branch information
paulmwatson committed Dec 11, 2024
1 parent 77e75a4 commit ba963fb
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pombola/core/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
from pombola.country import significant_positions_filter

date_help_text = "Format: '2011-12-31', '31 Jan 2011', 'Jan 2011' or '2011' or 'future'"
date_help_text_non_future = "Format: '2011-12-31' or '31 Jan 2011'"

def validate_person_slug(slug):
return validate_slug_not_redirecting('core', 'Person', slug)
Expand Down Expand Up @@ -513,8 +514,8 @@ class Person(ModelBase, HasImageMixin, ScorecardMixin, IdentifierMixin):
validators=[validate_person_slug],
)
gender = models.CharField(max_length=20, blank=True, help_text="this is typically, but not restricted to, 'male' or 'female'")
date_of_birth = ApproximateDateField(blank=True, help_text=date_help_text)
date_of_death = ApproximateDateField(blank=True, help_text=date_help_text)
date_of_birth = ApproximateDateField(blank=True, help_text=date_help_text_non_future)
date_of_death = ApproximateDateField(blank=True, help_text=date_help_text_non_future)
# religion
# tribe
summary = MarkupField(blank=True, default='')
Expand Down

0 comments on commit ba963fb

Please sign in to comment.