Skip to content

Commit

Permalink
Added Emergency Contact
Browse files Browse the repository at this point in the history
  • Loading branch information
vigneshhari committed Sep 4, 2020
1 parent f93894f commit bafd142
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
24 changes: 24 additions & 0 deletions care/facility/migrations/0175_auto_20200904_1000.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Generated by Django 2.2.11 on 2020-09-04 04:30

import django.core.validators
from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('facility', '0174_auto_20200903_1836'),
]

operations = [
migrations.AddField(
model_name='historicalpatientregistration',
name='emergency_phone_number',
field=models.CharField(default='', max_length=14, validators=[django.core.validators.RegexValidator(code='invalid_mobile', message='Please Enter 10/11 digit mobile number or landline as 0<std code><phone number>', regex='^((\\+91|91|0)[\\- ]{0,1})?[456789]\\d{9}$')]),
),
migrations.AddField(
model_name='patientregistration',
name='emergency_phone_number',
field=models.CharField(default='', max_length=14, validators=[django.core.validators.RegexValidator(code='invalid_mobile', message='Please Enter 10/11 digit mobile number or landline as 0<std code><phone number>', regex='^((\\+91|91|0)[\\- ]{0,1})?[456789]\\d{9}$')]),
),
]
2 changes: 2 additions & 0 deletions care/facility/models/patient.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,8 @@ class ActionEnum(enum.Enum):
# phone_number_old = EncryptedCharField(max_length=14, validators=[phone_number_regex], default="")
phone_number = models.CharField(max_length=14, validators=[phone_number_regex], default="")

emergency_phone_number = models.CharField(max_length=14, validators=[phone_number_regex], default="")

# address_old = EncryptedTextField(default="")
address = models.TextField(default="")

Expand Down

0 comments on commit bafd142

Please sign in to comment.