Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Copied and modified date_help_text to date_help_text_non_future #243

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
Loading