#9942: Make datatype changes Person model

This commit is contained in:
PCoder 2021-11-28 10:21:03 +05:30
parent ed868f646d
commit e796a13584

View file

@ -525,6 +525,13 @@ class Search(models.Model):
class Person(models.Model): class Person(models.Model):
MR_MRS_CHOICES = (
('', ''),
('Ms', 'Ms'),
('Ms.', 'Ms.'),
('Mr', 'Mr'),
('Mr.', 'Mr.'),
)
id = models.AutoField(primary_key=True) id = models.AutoField(primary_key=True)
source_id = models.IntegerField(blank=True, null=True) source_id = models.IntegerField(blank=True, null=True)
title = models.TextField(blank=True, null=True) title = models.TextField(blank=True, null=True)
@ -532,19 +539,19 @@ class Person(models.Model):
last_name = models.TextField(blank=True, null=True) last_name = models.TextField(blank=True, null=True)
organisation = models.TextField(blank=True, null=True) organisation = models.TextField(blank=True, null=True)
position = models.TextField(blank=True, null=True) position = models.TextField(blank=True, null=True)
contact_email = models.TextField(blank=True, null=True) # email_1 contact_email = models.EmailField(blank=True, null=True) # email_1
personal_url = models.TextField(blank=True, null=True) # url ? personal_url = models.URLField(blank=True, null=True) # url ?
biography = models.TextField(blank=True, null=True) biography = models.TextField(blank=True, null=True)
field_indexer = models.TextField(db_column='_indexer', blank=True, null=True) # Field renamed because it started with '_'. field_indexer = models.TextField(db_column='_indexer', blank=True, null=True) # Field renamed because it started with '_'.
mr_mrs = models.TextField(blank=True, null=True) mr_mrs = models.TextField(blank=True, null=True, choices=MR_MRS_CHOICES)
full_name = models.TextField(blank=True, null=True) full_name = models.TextField(blank=True, null=True)
search_name = models.TextField(blank=True, null=True) search_name = models.TextField(blank=True, null=True)
email_2 = models.TextField(blank=True, null=True) email_2 = models.EmailField(blank=True, null=True)
skype = models.TextField(blank=True, null=True) skype = models.CharField(blank=True, null=True, max_length=50)
professional_phone = models.TextField(blank=True, null=True) professional_phone = models.CharField(blank=True, null=True, max_length=50)
mobile_number = models.TextField(blank=True, null=True) mobile_number = models.CharField(blank=True, null=True, max_length=50)
url = models.TextField(blank=True, null=True) url = models.URLField(blank=True, null=True)
field_of_expertise = models.TextField(blank=True, null=True) field_of_expertise = models.TextField(blank=True, null=True)
status = models.ForeignKey(PeopleStatus, models.DO_NOTHING, blank=True, null=True, to_field='id') status = models.ForeignKey(PeopleStatus, models.DO_NOTHING, blank=True, null=True, to_field='id')
entry_date = models.TextField(blank=True, null=True) entry_date = models.TextField(blank=True, null=True)