diff --git a/smash/web/models/constants.py b/smash/web/models/constants.py index fb01625467218e48e9111f775824a84e93372843..6d5fbeef623b083661c57842689254ac95f12fde 100644 --- a/smash/web/models/constants.py +++ b/smash/web/models/constants.py @@ -53,3 +53,11 @@ MAIL_TEMPLATE_CONTEXT_CHOICES = ( (MAIL_TEMPLATE_CONTEXT_VISIT, 'Visit'), ) LOCALE_CHOICES = [(value, value) for value in sorted(locale.windows_locale.values())] + +MONDAY_AS_DAY_OF_WEEK = 1 +TUESDAY_AS_DAY_OF_WEEK = 2 +WEDNESDAY_AS_DAY_OF_WEEK = 3 +THURSDAY_AS_DAY_OF_WEEK = 4 +FRIDAY_AS_DAY_OF_WEEK = 5 +SATURDAY_AS_DAY_OF_WEEK = 6 +SUNDAY_AS_DAY_OF_WEEK = 7 diff --git a/smash/web/views/doctor.py b/smash/web/views/doctor.py index 09031a36050d59d970c8c57942a188726f88021e..43a7465552e55183bf4104bc53c667b3f4e5876b 100644 --- a/smash/web/views/doctor.py +++ b/smash/web/views/doctor.py @@ -4,15 +4,8 @@ from django.shortcuts import redirect, get_object_or_404 from . import wrap_response from ..forms import WorkerAddForm, WorkerEditForm, WorkerDetailForm from ..models import Worker, Availability - -MONDAY_AS_DAY_OF_WEEK = 1 -TUESDAY_AS_DAY_OF_WEEK = 2 -WEDNESDAY_AS_DAY_OF_WEEK = 3 -THURSDAY_AS_DAY_OF_WEEK = 4 -FRIDAY_AS_DAY_OF_WEEK = 5 -SATURDAY_AS_DAY_OF_WEEK = 6 -SUNDAY_AS_DAY_OF_WEEK = 7 - +from ..models.constants import MONDAY_AS_DAY_OF_WEEK, TUESDAY_AS_DAY_OF_WEEK, WEDNESDAY_AS_DAY_OF_WEEK, \ + THURSDAY_AS_DAY_OF_WEEK, FRIDAY_AS_DAY_OF_WEEK, SATURDAY_AS_DAY_OF_WEEK, SUNDAY_AS_DAY_OF_WEEK def doctors(request): doctors_list = Worker.objects.order_by('-last_name')