Skip to content
Snippets Groups Projects
Commit 21aeebf6 authored by Piotr Gawron's avatar Piotr Gawron
Browse files

Merge branch 'deployment-issues' into 'master'

Deployment issues

See merge request NCER-PD/scheduling-system!124
parents b7072c6e 33e7abe7
No related branches found
No related tags found
1 merge request!124Deployment issues
Pipeline #
......@@ -356,7 +356,7 @@ def serialize_subject(study_subject):
contact_attempts = ContactAttempt.objects.filter(subject=study_subject).order_by("-datetime_when")
if len(contact_attempts) > 0:
last_contact_attempt = contact_attempts[0]
last_contact_attempt_string = serialize_datetime(last_contact_attempt.datetime_when) + "<br/>" + str(
last_contact_attempt_string = serialize_datetime(last_contact_attempt.datetime_when) + "<br/>" + unicode(
last_contact_attempt.worker) + "<br/> Success: " + bool_to_yes_no(
last_contact_attempt.success) + "<br/>" + last_contact_attempt.comment
......
......@@ -85,7 +85,7 @@
columns: [
{"data": "subject"},
{"data": "title"},
{"data": "type"},
{"data": "appointment_types"},
{"data": "datetime_when"},
{"data": null}
],
......
......@@ -104,6 +104,14 @@ class TestSubjectApi(LoggedInWithWorkerTestCase):
response = self.client.get(reverse('web.api.subjects', kwargs={'type': SUBJECT_LIST_GENERIC}))
self.assertEqual(response.status_code, 200)
def test_subjects_general_with_special_characters(self):
contact_attempt = create_contact_attempt(subject=self.study_subject)
contact_attempt.worker.first_name = "à special character"
contact_attempt.worker.save()
response = self.client.get(reverse('web.api.subjects', kwargs={'type': SUBJECT_LIST_GENERIC}))
self.assertEqual(response.status_code, 200)
logger.debug(response.content)
def test_subjects_voucher_almost_expired(self):
response = self.client.get(reverse('web.api.subjects', kwargs={'type': SUBJECT_LIST_VOUCHER_EXPIRY}))
self.assertEqual(response.status_code, 200)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment