Skip to content

Commit 0a7e2fe

Browse files
committed
chore(eap-registration): Update fields on eap registration
1 parent 6944ec2 commit 0a7e2fe

3 files changed

Lines changed: 38 additions & 4 deletions

File tree

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# Generated by Django 4.2.26 on 2025-12-19 07:52
2+
3+
from django.db import migrations, models
4+
5+
6+
class Migration(migrations.Migration):
7+
dependencies = [
8+
("eap", "0012_remove_fulleap_seap_timeframe_and_more"),
9+
]
10+
11+
operations = [
12+
migrations.AlterField(
13+
model_name="eapregistration",
14+
name="national_society_contact_email",
15+
field=models.CharField(
16+
default="test@gmail.com",
17+
max_length=255,
18+
verbose_name="national society contact email",
19+
),
20+
preserve_default=False,
21+
),
22+
migrations.AlterField(
23+
model_name="eapregistration",
24+
name="national_society_contact_name",
25+
field=models.CharField(
26+
default="test",
27+
max_length=255,
28+
verbose_name="national society contact name",
29+
),
30+
preserve_default=False,
31+
),
32+
]

eap/models.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -638,13 +638,15 @@ class EAPRegistration(EAPBaseModel):
638638
# Contacts
639639
# National Society
640640
national_society_contact_name = models.CharField(
641-
verbose_name=_("national society contact name"), max_length=255, null=True, blank=True
641+
verbose_name=_("national society contact name"),
642+
max_length=255,
642643
)
643644
national_society_contact_title = models.CharField(
644645
verbose_name=_("national society contact title"), max_length=255, null=True, blank=True
645646
)
646647
national_society_contact_email = models.CharField(
647-
verbose_name=_("national society contact email"), max_length=255, null=True, blank=True
648+
verbose_name=_("national society contact email"),
649+
max_length=255,
648650
)
649651
national_society_contact_phone_number = models.CharField(
650652
verbose_name=_("national society contact phone number"), max_length=100, null=True, blank=True

eap/test_views.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -202,8 +202,8 @@ def test_update_eap_registration(self):
202202

203203
# Authenticate as root user
204204
self.authenticate(self.root_user)
205-
response = self.client.put(url, data, format="json")
206-
self.assertEqual(response.status_code, 200)
205+
response = self.client.patch(url, data, format="json")
206+
self.assertEqual(response.status_code, 200, response.data)
207207

208208
# Check modified_by
209209
self.assertIsNotNone(response.data["modified_by_details"])

0 commit comments

Comments
 (0)