Commit 57a8f840 by Waheed Ahmed Committed by Awais Qureshi

Added studio instance required fields.

ECOM-6093
parent 1913318c
......@@ -18,10 +18,10 @@ class BaseCourseForm(forms.ModelForm):
field_classes = 'field-input input-text'
if isinstance(field, forms.Textarea):
field_classes = 'field-textarea input-textarea'
if isinstance(field, (forms.BooleanField, forms.ChoiceField,)):
field_classes = 'field-input input-checkbox'
if isinstance(field, (forms.ModelChoiceField, forms.TypedChoiceField,)):
field_classes = 'field-input input-select'
if isinstance(field, forms.BooleanField):
field_classes = 'field-input input-checkbox'
if isinstance(field, forms.DateTimeField):
field_classes = '{} add-pikaday'.format(field_classes)
field.input_formats = ['YYYY-MM-DDTHH:mm:ss']
......@@ -49,13 +49,17 @@ class CustomCourseForm(CourseForm):
""" Course Form. """
organization = forms.ModelChoiceField(
queryset=Organization.objects.filter(organization_extension__organization_id__isnull=False),
label=_('Organization Name'),
required=True
)
title = forms.CharField(label=_('Course Title'), required=True)
number = forms.CharField(label=_('Course Number'), required=True)
# users will be loaded through AJAX call based on organization
team_admin = forms.ModelChoiceField(queryset=User.objects.none(), required=True)
team_admin = forms.ModelChoiceField(
queryset=User.objects.none(), required=True,
label=_('Organization Course Admin'),
)
class Meta(CourseForm.Meta):
model = Course
......@@ -111,11 +115,15 @@ class CourseRunForm(BaseCourseForm):
class CustomCourseRunForm(CourseRunForm):
""" Course Run Form. """
contacted_partner_manager = forms.BooleanField(
widget=forms.RadioSelect(choices=((1, _("Yes")), (0, _("No")))), initial=0, required=False
contacted_partner_manager = forms.ChoiceField(
label=_('Contacted PM'),
widget=forms.RadioSelect,
choices=((True, _("Yes")), (False, _("No"))),
required=True
)
start = forms.DateTimeField(label=_('Course start date'), required=True)
end = forms.DateTimeField(label=_('Course end date'), required=False)
end = forms.DateTimeField(label=_('Course end date'), required=True)
staff = forms.ModelMultipleChoiceField(
queryset=Person.objects.all(), widget=forms.SelectMultiple, required=False
)
......@@ -123,22 +131,20 @@ class CustomCourseRunForm(CourseRunForm):
widget=forms.RadioSelect(
choices=((1, _("Yes")), (0, _("No")))), initial=0, required=False
)
is_self_paced = forms.BooleanField(label=_('Yes, course will be Self-Paced'), required=False)
pacing_type = forms.ChoiceField(
label=_('Pace'),
widget=forms.RadioSelect,
choices=CourseRunPacing.choices,
required=True
)
class Meta(CourseRunForm.Meta):
fields = (
'length', 'transcript_languages', 'language', 'min_effort', 'max_effort',
'contacted_partner_manager', 'target_content', 'pacing_type',
'video_language', 'staff', 'start', 'end', 'is_self_paced',
'contacted_partner_manager', 'target_content', 'pacing_type', 'video_language',
'staff', 'start', 'end',
)
def clean(self):
super(CustomCourseRunForm, self).clean()
self.cleaned_data['pacing_type'] = CourseRunPacing.Self if self.cleaned_data['is_self_paced']\
else CourseRunPacing.Instructor
return self.cleaned_data
def save(self, commit=True, course=None, changed_by=None): # pylint: disable=arguments-differ
course_run = super(CustomCourseRunForm, self).save(commit=False)
......
......@@ -57,6 +57,7 @@ class CourseRunFactory(factory.DjangoModelFactory):
length = FuzzyInteger(1, 10)
notes = "Testing notes"
preview_url = FuzzyText(prefix='https://example.com/')
contacted_partner_manager = FuzzyChoice((True, False))
class Meta:
model = CourseRun
......
# pylint: disable=no-member
import json
from datetime import datetime
from datetime import datetime, timedelta
import ddt
import factory
......@@ -55,6 +55,7 @@ class CreateUpdateCourseViewTests(TestCase):
self.site = Site.objects.get(pk=settings.SITE_ID)
self.client.login(username=self.user.username, password=USER_PASSWORD)
self.start_date_time = datetime.now().strftime('%Y-%m-%d %H:%M:%S')
self.end_date_time = (datetime.now() + timedelta(days=60)).strftime('%Y-%m-%d %H:%M:%S')
# creating default organizations roles
factories.OrganizationUserRoleFactory(
......@@ -271,6 +272,18 @@ class CreateUpdateCourseViewTests(TestCase):
response = self.client.post(reverse('publisher:publisher_courses_new'), course_dict, files=data['image'])
self.assertEqual(response.status_code, 400)
@ddt.data('contacted_partner_manager', 'pacing_type')
def test_create_without_selecting_radio_buttons(self, button_field):
"""
Verify that without selecting pacing type and contacted_partner_manager
course cannot be created.
"""
data = {'number': 'course_1', 'image': ''}
course_dict = self._post_data(data, self.course, self.course_run, self.seat)
course_dict.pop(button_field)
response = self.client.post(reverse('publisher:publisher_courses_new'), course_dict)
self.assertEqual(response.status_code, 400)
def _post_data(self, data, course, course_run, seat):
course_dict = model_to_dict(course)
course_dict.update(**data)
......@@ -282,6 +295,7 @@ class CreateUpdateCourseViewTests(TestCase):
course_dict.pop('end')
course_dict.pop('priority')
course_dict['start'] = self.start_date_time
course_dict['end'] = self.end_date_time
course_dict['organization'] = self.organization_extension.organization.id
if seat:
course_dict.update(**model_to_dict(seat))
......@@ -319,7 +333,10 @@ class CreateUpdateCourseViewTests(TestCase):
self.assertEqual(course.course_user_roles.filter(role=PublisherUserRole.CourseTeam).count(), 1)
course_run = course.publisher_course_runs.all()[0]
self.assertEqual(self.course_run.language, course_run.language)
self.assertEqual(self.course_run.contacted_partner_manager, course_run.contacted_partner_manager)
self.assertEqual(self.course_run.pacing_type, course_run.pacing_type)
self.assertEqual(course_run.start.strftime("%Y-%m-%d %H:%M:%S"), self.start_date_time)
self.assertEqual(course_run.end.strftime("%Y-%m-%d %H:%M:%S"), self.end_date_time)
seat = course_run.seats.all()[0]
self.assertEqual(seat.type, expected_type)
self.assertEqual(seat.price, expected_price)
......@@ -357,6 +374,7 @@ class CreateUpdateCourseRunViewTests(TestCase):
]
)
self.course_run_dict['start'] = datetime.now().strftime('%Y-%m-%d %H:%M:%S')
self.course_run_dict['end'] = (datetime.now() + timedelta(days=60)).strftime('%Y-%m-%d %H:%M:%S')
self.site = Site.objects.get(pk=settings.SITE_ID)
self.client.login(username=self.user.username, password=USER_PASSWORD)
......
......@@ -9,7 +9,7 @@ urlpatterns = [
url(r'^$', views.Dashboard.as_view(), name='publisher_dashboard'),
url(r'^api/', include('course_discovery.apps.publisher.api.urls', namespace='api')),
url(r'^courses/$', views.CourseListView.as_view(), name='publisher_courses'),
url(r'^courses/new$', views.CreateCourseView.as_view(), name='publisher_courses_new'),
url(r'^courses/new/$', views.CreateCourseView.as_view(), name='publisher_courses_new'),
url(r'^courses/(?P<pk>\d+)/view/$', views.ReadOnlyView.as_view(), name='publisher_courses_readonly'),
url(r'^courses/(?P<pk>\d+)/edit/$', views.UpdateCourseView.as_view(), name='publisher_courses_edit'),
url(
......
......@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-12-29 14:13+0500\n"
"POT-Creation-Date: 2016-12-30 14:38+0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
......@@ -438,17 +438,27 @@ msgstr ""
msgid "Studio instance created"
msgstr ""
#: apps/publisher/forms.py templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
#: apps/publisher/forms.py
msgid "Organization Name"
msgstr ""
#: apps/publisher/forms.py templates/publisher/add_courserun_form.html
msgid "Course Title"
msgstr ""
#: apps/publisher/forms.py templates/publisher/add_course_form.html
#: templates/publisher/dashboard/_studio_requests.html
#: apps/publisher/forms.py templates/publisher/dashboard/_studio_requests.html
msgid "Course Number"
msgstr ""
#: apps/publisher/forms.py
msgid "Organization Course Admin"
msgstr ""
#: apps/publisher/forms.py
msgid "Contacted PM"
msgstr ""
#: apps/publisher/forms.py
msgid "Yes"
msgstr ""
......@@ -465,7 +475,7 @@ msgid "Course end date"
msgstr ""
#: apps/publisher/forms.py
msgid "Yes, course will be Self-Paced"
msgid "Pace"
msgstr ""
#: apps/publisher/forms.py
......@@ -774,19 +784,26 @@ msgid "Course Form"
msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/view_course_form.html
msgid "Base information"
#: templates/publisher/add_courserun_form.html
msgid "Studio instance information"
msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/view_course_form.html
msgid "INSTITUTION INFORMATION"
msgid ""
"The information in this section is required to create a course studio "
"instance. You must fill all required information but are welcome to come "
"back and enter the rest of the information when you are ready to announce "
"the course, or you can do it all at once if you are ready to do so."
msgstr ""
#: templates/publisher/add_course_form.html
msgid "CONTACTED PARTNER MANAGER"
msgstr ""
#: templates/publisher/add_course_form.html
msgid ""
"Please choose the school that will be providing the course. Once chosen then"
" you can select an administrator for the studio shell."
"Contacted a PM about the creation of a new course is important so that edx "
"can help you on marketing efforts."
msgstr ""
#: templates/publisher/add_course_form.html
......@@ -796,6 +813,11 @@ msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid "COURSE TITLE"
msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid "Best Practices"
msgstr ""
......@@ -827,34 +849,33 @@ msgid ""
msgstr ""
#: templates/publisher/add_course_form.html
msgid "English Grammar and Essay Writing Sequence Courses:"
#: templates/publisher/add_courserun_form.html
msgid "English Grammar and Essay Writing"
msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid "Introduction to Statistics"
msgid "Sequence Courses:"
msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid "Statistics: Inference"
msgid "Introduction to Statistics"
msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid "Statistics: Probability"
msgid "Statistics: Inference"
msgstr ""
#: templates/publisher/add_course_form.html
msgid "Priority content"
#: templates/publisher/add_courserun_form.html
msgid "Statistics: Probability"
msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/course_run_detail/_drupal.html
#: templates/publisher/course_run_detail/_salesforce.html
#: templates/publisher/course_run_detail/_studio.html
#: templates/publisher/dashboard/_studio_requests.html
msgid "Start Date"
#: templates/publisher/add_courserun_form.html
msgid "COURSE START DATE"
msgstr ""
#: templates/publisher/add_course_form.html
......@@ -870,46 +891,50 @@ msgid ""
msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/course_run_detail/_all.html
#: templates/publisher/course_run_detail/_studio.html
msgid "Pacing Type"
#: templates/publisher/add_courserun_form.html
msgid "COURSE END DATE"
msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid ""
"Will your course be open to students at the same time as it is announced?"
"The date when this self-paced course run will end, replaced by an updated "
"version of the course"
msgstr ""
#: templates/publisher/add_course_form.html
msgid ""
"Courses split into several modules can be denoted by adding .1, .2, etc. at "
"the end of the course number before the “x”"
#: templates/publisher/add_courserun_form.html
msgid "PACING TYPE"
msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid ""
"No special html characters, accents, spaces, dashes, or underscores 10 "
"character limit"
"Will your course be open to students at the same time as it is announced?"
msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid "About page information"
msgid "COURSE NUMBER"
msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/course_run_detail/_drupal.html
#: templates/publisher/course_run_detail/_salesforce.html
#: templates/publisher/course_run_detail/_studio.html
msgid "End Date"
msgid ""
"Courses split into several modules can be denoted by adding .1, .2, etc. at "
"the end of the course number before the “x”"
msgstr ""
#: templates/publisher/add_course_form.html
msgid "No special html characters, accents, spaces, dashes, or underscores"
msgstr ""
#: templates/publisher/add_course_form.html
msgid "10 character limit"
msgstr ""
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid ""
"The date when this self-paced course run will end, replaced by an updated "
"version of the course"
msgid "About page information"
msgstr ""
#: templates/publisher/add_course_form.html
......@@ -1149,10 +1174,6 @@ msgid ""
msgstr ""
#: templates/publisher/add_courserun_form.html
msgid "Studio instance information"
msgstr ""
#: templates/publisher/add_courserun_form.html
msgid ""
"\n"
" The information in this section is required to create a course studio instance. You must fill all required information but are welcome to come back and enter the rest of the information when you are ready to announce the course, or you can do it all at once if you are ready to do so.\n"
......@@ -1160,18 +1181,6 @@ msgid ""
msgstr ""
#: templates/publisher/add_courserun_form.html
msgid "COURSE TITLE"
msgstr ""
#: templates/publisher/add_courserun_form.html
msgid "English Grammar and Essay Writing"
msgstr ""
#: templates/publisher/add_courserun_form.html
msgid "Sequence Courses:"
msgstr ""
#: templates/publisher/add_courserun_form.html
msgid "Institution Course Admin"
msgstr ""
......@@ -1180,10 +1189,6 @@ msgid "Change"
msgstr ""
#: templates/publisher/add_courserun_form.html
msgid "COURSE START DATE"
msgstr ""
#: templates/publisher/add_courserun_form.html
msgid ""
"\n"
" Start on a weekday (preferably Tuesday, Wednesday, or Thursday) and avoid major U.S. holidays\n"
......@@ -1200,10 +1205,6 @@ msgid ""
msgstr ""
#: templates/publisher/add_courserun_form.html
msgid "COURSE NUMBER"
msgstr ""
#: templates/publisher/add_courserun_form.html
msgid ""
"\n"
" Courses split into several modules can be denoted by adding .1, .2, etc. at the end of the\n"
......@@ -1222,10 +1223,6 @@ msgid "etc."
msgstr ""
#: templates/publisher/add_courserun_form.html
msgid "COURSE END DATE"
msgstr ""
#: templates/publisher/add_courserun_form.html
msgid "CERTIFICATE TYPE AND PRICE"
msgstr ""
......@@ -1351,6 +1348,11 @@ msgid "Course Length (weeks)"
msgstr ""
#: templates/publisher/course_run_detail/_all.html
#: templates/publisher/course_run_detail/_studio.html
msgid "Pacing Type"
msgstr ""
#: templates/publisher/course_run_detail/_all.html
#: templates/publisher/course_run_detail/_drupal.html
msgid "Estimated Effort"
msgstr ""
......@@ -1474,6 +1476,19 @@ msgid "XSeries"
msgstr ""
#: templates/publisher/course_run_detail/_drupal.html
#: templates/publisher/course_run_detail/_salesforce.html
#: templates/publisher/course_run_detail/_studio.html
#: templates/publisher/dashboard/_studio_requests.html
msgid "Start Date"
msgstr ""
#: templates/publisher/course_run_detail/_drupal.html
#: templates/publisher/course_run_detail/_salesforce.html
#: templates/publisher/course_run_detail/_studio.html
msgid "End Date"
msgstr ""
#: templates/publisher/course_run_detail/_drupal.html
msgid "Self Paced"
msgstr ""
......@@ -1860,5 +1875,13 @@ msgid "Seat Form"
msgstr ""
#: templates/publisher/view_course_form.html
msgid "Base information"
msgstr ""
#: templates/publisher/view_course_form.html
msgid "INSTITUTION INFORMATION"
msgstr ""
#: templates/publisher/view_course_form.html
msgid "Course information"
msgstr ""
......@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-12-29 14:13+0500\n"
"POT-Creation-Date: 2016-12-30 14:38+0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
......
......@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-12-29 14:13+0500\n"
"POT-Creation-Date: 2016-12-30 14:38+0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
......@@ -546,17 +546,27 @@ msgstr ""
msgid "Studio instance created"
msgstr "Stüdïö ïnstänçé çréätéd Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σ#"
#: apps/publisher/forms.py templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
#: apps/publisher/forms.py
msgid "Organization Name"
msgstr "Örgänïzätïön Nämé Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмє#"
#: apps/publisher/forms.py templates/publisher/add_courserun_form.html
msgid "Course Title"
msgstr "Çöürsé Tïtlé Ⱡ'σяєм ιρѕυм ∂σłσя ѕ#"
#: apps/publisher/forms.py templates/publisher/add_course_form.html
#: templates/publisher/dashboard/_studio_requests.html
#: apps/publisher/forms.py templates/publisher/dashboard/_studio_requests.html
msgid "Course Number"
msgstr "Çöürsé Nümßér Ⱡ'σяєм ιρѕυм ∂σłσя ѕι#"
#: apps/publisher/forms.py
msgid "Organization Course Admin"
msgstr "Örgänïzätïön Çöürsé Àdmïn Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕ#"
#: apps/publisher/forms.py
msgid "Contacted PM"
msgstr "Çöntäçtéd PM Ⱡ'σяєм ιρѕυм ∂σłσя ѕ#"
#: apps/publisher/forms.py
msgid "Yes"
msgstr "Ýés Ⱡ'σяєм#"
......@@ -573,8 +583,8 @@ msgid "Course end date"
msgstr "Çöürsé énd däté Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт α#"
#: apps/publisher/forms.py
msgid "Yes, course will be Self-Paced"
msgstr "Ýés, çöürsé wïll ßé Sélf-Päçéd Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє¢т#"
msgid "Pace"
msgstr "Päçé Ⱡ'σяєм ι#"
#: apps/publisher/forms.py
msgid "Only honor/audit seats can be without price."
......@@ -912,22 +922,36 @@ msgid "Course Form"
msgstr "Çöürsé Förm Ⱡ'σяєм ιρѕυм ∂σłσя #"
#: templates/publisher/add_course_form.html
#: templates/publisher/view_course_form.html
msgid "Base information"
msgstr "Bäsé ïnförmätïön Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αм#"
#: templates/publisher/add_courserun_form.html
msgid "Studio instance information"
msgstr "Stüdïö ïnstänçé ïnförmätïön Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє#"
#: templates/publisher/add_course_form.html
#: templates/publisher/view_course_form.html
msgid "INSTITUTION INFORMATION"
msgstr "ÌNSTÌTÛTÌÖN ÌNFÖRMÀTÌÖN Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σ#"
msgid ""
"The information in this section is required to create a course studio "
"instance. You must fill all required information but are welcome to come "
"back and enter the rest of the information when you are ready to announce "
"the course, or you can do it all at once if you are ready to do so."
msgstr ""
"Thé ïnförmätïön ïn thïs séçtïön ïs réqüïréd tö çréäté ä çöürsé stüdïö "
"ïnstänçé. Ýöü müst fïll äll réqüïréd ïnförmätïön ßüt äré wélçömé tö çömé "
"ßäçk änd éntér thé rést öf thé ïnförmätïön whén ýöü äré réädý tö ännöünçé "
"thé çöürsé, ör ýöü çän dö ït äll ät önçé ïf ýöü äré réädý tö dö sö. Ⱡ'σяєм "
"ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє¢тєтυя α∂ιριѕι¢ιηg єłιт, ѕє∂ ∂σ єιυѕмσ∂ тємρσя "
"ιη¢ι∂ι∂υηт υт łαвσяє єт ∂σłσяє мαgηα αłιqυα. υт єηιм α∂ мιηιм νєηιαм, qυιѕ "
"ησѕтяυ∂ єχєя¢ιтαтιση υłłαм¢σ łαвσяιѕ ηιѕι υт αłιqυ#"
#: templates/publisher/add_course_form.html
msgid "CONTACTED PARTNER MANAGER"
msgstr "ÇÖNTÀÇTÉD PÀRTNÉR MÀNÀGÉR Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕ#"
#: templates/publisher/add_course_form.html
msgid ""
"Please choose the school that will be providing the course. Once chosen then"
" you can select an administrator for the studio shell."
"Contacted a PM about the creation of a new course is important so that edx "
"can help you on marketing efforts."
msgstr ""
"Pléäsé çhöösé thé sçhööl thät wïll ßé prövïdïng thé çöürsé. Önçé çhösén thén"
" ýöü çän séléçt än ädmïnïsträtör för thé stüdïö shéll. Ⱡ'#"
"Çöntäçtéd ä PM äßöüt thé çréätïön öf ä néw çöürsé ïs ïmpörtänt sö thät édx "
"çän hélp ýöü ön märkétïng éfförts. Ⱡ'σяєм ιρѕυм ∂σłσя ѕ#"
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
......@@ -936,6 +960,11 @@ msgstr "réqüïréd Ⱡ'σяєм ιρѕυм ∂#"
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid "COURSE TITLE"
msgstr "ÇÖÛRSÉ TÌTLÉ Ⱡ'σяєм ιρѕυм ∂σłσя ѕ#"
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid "Best Practices"
msgstr "Bést Präçtïçés Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт#"
......@@ -975,10 +1004,15 @@ msgstr ""
"Tïtlé: Süßtïtlé\" Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє¢#"
#: templates/publisher/add_course_form.html
msgid "English Grammar and Essay Writing Sequence Courses:"
#: templates/publisher/add_courserun_form.html
msgid "English Grammar and Essay Writing"
msgstr ""
"Énglïsh Grämmär änd Éssäý Wrïtïng Séqüénçé Çöürsés: Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт "
"αмєт, ¢σηѕє¢тєтυя α#"
"Énglïsh Grämmär änd Éssäý Wrïtïng Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє¢тє#"
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid "Sequence Courses:"
msgstr "Séqüénçé Çöürsés: Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмє#"
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
......@@ -996,16 +1030,9 @@ msgid "Statistics: Probability"
msgstr "Stätïstïçs: Prößäßïlïtý Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σ#"
#: templates/publisher/add_course_form.html
msgid "Priority content"
msgstr "Prïörïtý çöntént Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αм#"
#: templates/publisher/add_course_form.html
#: templates/publisher/course_run_detail/_drupal.html
#: templates/publisher/course_run_detail/_salesforce.html
#: templates/publisher/course_run_detail/_studio.html
#: templates/publisher/dashboard/_studio_requests.html
msgid "Start Date"
msgstr "Stärt Däté Ⱡ'σяєм ιρѕυм ∂σłσ#"
#: templates/publisher/add_courserun_form.html
msgid "COURSE START DATE"
msgstr "ÇÖÛRSÉ STÀRT DÀTÉ Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмє#"
#: templates/publisher/add_course_form.html
msgid ""
......@@ -1030,10 +1057,23 @@ msgstr ""
"ηση ρяσι∂єηт, ѕυηт ιη ¢υłρα qυι σƒƒι¢ια ∂єѕєяυηт мσłłιт αηιм ι∂ єѕт łαвσяυ#"
#: templates/publisher/add_course_form.html
#: templates/publisher/course_run_detail/_all.html
#: templates/publisher/course_run_detail/_studio.html
msgid "Pacing Type"
msgstr "Päçïng Týpé Ⱡ'σяєм ιρѕυм ∂σłσя #"
#: templates/publisher/add_courserun_form.html
msgid "COURSE END DATE"
msgstr "ÇÖÛRSÉ ÉND DÀTÉ Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт α#"
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid ""
"The date when this self-paced course run will end, replaced by an updated "
"version of the course"
msgstr ""
"Thé däté whén thïs sélf-päçéd çöürsé rün wïll énd, répläçéd ßý än üpdätéd "
"vérsïön öf thé çöürsé Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢#"
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid "PACING TYPE"
msgstr "PÀÇÌNG TÝPÉ Ⱡ'σяєм ιρѕυм ∂σłσя #"
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
......@@ -1044,6 +1084,11 @@ msgstr ""
"Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє¢тєтυя#"
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid "COURSE NUMBER"
msgstr "ÇÖÛRSÉ NÛMBÉR Ⱡ'σяєм ιρѕυм ∂σłσя ѕι#"
#: templates/publisher/add_course_form.html
msgid ""
"Courses split into several modules can be denoted by adding .1, .2, etc. at "
"the end of the course number before the “x”"
......@@ -1052,33 +1097,19 @@ msgstr ""
"thé énd öf thé çöürsé nümßér ßéföré thé “x” Ⱡ'σяєм ιρѕυм#"
#: templates/publisher/add_course_form.html
msgid ""
"No special html characters, accents, spaces, dashes, or underscores 10 "
"character limit"
msgid "No special html characters, accents, spaces, dashes, or underscores"
msgstr ""
"Nö spéçïäl html çhäräçtérs, äççénts, späçés, däshés, ör ündérsçörés 10 "
"çhäräçtér lïmït Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє¢#"
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid "About page information"
msgstr "Àßöüt pägé ïnförmätïön Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢#"
"Nö spéçïäl html çhäräçtérs, äççénts, späçés, däshés, ör ündérsçörés Ⱡ'σяєм "
"ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє¢тєтυя #"
#: templates/publisher/add_course_form.html
#: templates/publisher/course_run_detail/_drupal.html
#: templates/publisher/course_run_detail/_salesforce.html
#: templates/publisher/course_run_detail/_studio.html
msgid "End Date"
msgstr "Énd Däté Ⱡ'σяєм ιρѕυм ∂#"
msgid "10 character limit"
msgstr "10 çhäräçtér lïmït Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт#"
#: templates/publisher/add_course_form.html
#: templates/publisher/add_courserun_form.html
msgid ""
"The date when this self-paced course run will end, replaced by an updated "
"version of the course"
msgstr ""
"Thé däté whén thïs sélf-päçéd çöürsé rün wïll énd, répläçéd ßý än üpdätéd "
"vérsïön öf thé çöürsé Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢#"
msgid "About page information"
msgstr "Àßöüt pägé ïnförmätïön Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢#"
#: templates/publisher/add_course_form.html
#: templates/publisher/course_run_detail/_seats.html
......@@ -1395,10 +1426,6 @@ msgstr ""
" Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє¢тєтυя α∂ιριѕι¢ιηg єłιт, ѕє∂ ∂σ єιυѕмσ∂ тємρσя ιη¢ι∂ι∂υηт υт łαвσяє єт ∂σłσяє мαgηα αłιqυα. υт єηιм α∂ мιηιм νєηιαм, qυιѕ ησѕтяυ∂ єχєя¢ιтαтιση υłłαм¢σ łαвσяιѕ ηιѕι υт αłιqυιρ єχ єα ¢σммσ∂σ ¢σηѕєqυαт. ∂υιѕ αυтє ιяυяє ∂σłσя ιη яєρяєнєη∂єяιт ιη νσłυρтαтє νєłιт єѕѕє ¢ιłłυм ∂σłσяє єυ ƒυgιαт ηυłłα ρα#"
#: templates/publisher/add_courserun_form.html
msgid "Studio instance information"
msgstr "Stüdïö ïnstänçé ïnförmätïön Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє#"
#: templates/publisher/add_courserun_form.html
msgid ""
"\n"
" The information in this section is required to create a course studio instance. You must fill all required information but are welcome to come back and enter the rest of the information when you are ready to announce the course, or you can do it all at once if you are ready to do so.\n"
......@@ -1409,19 +1436,6 @@ msgstr ""
" Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє¢тєтυя α∂ιριѕι#"
#: templates/publisher/add_courserun_form.html
msgid "COURSE TITLE"
msgstr "ÇÖÛRSÉ TÌTLÉ Ⱡ'σяєм ιρѕυм ∂σłσя ѕ#"
#: templates/publisher/add_courserun_form.html
msgid "English Grammar and Essay Writing"
msgstr ""
"Énglïsh Grämmär änd Éssäý Wrïtïng Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє¢тє#"
#: templates/publisher/add_courserun_form.html
msgid "Sequence Courses:"
msgstr "Séqüénçé Çöürsés: Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмє#"
#: templates/publisher/add_courserun_form.html
msgid "Institution Course Admin"
msgstr "Ìnstïtütïön Çöürsé Àdmïn Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢ση#"
......@@ -1430,10 +1444,6 @@ msgid "Change"
msgstr "Çhängé Ⱡ'σяєм ιρѕυ#"
#: templates/publisher/add_courserun_form.html
msgid "COURSE START DATE"
msgstr "ÇÖÛRSÉ STÀRT DÀTÉ Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмє#"
#: templates/publisher/add_courserun_form.html
msgid ""
"\n"
" Start on a weekday (preferably Tuesday, Wednesday, or Thursday) and avoid major U.S. holidays\n"
......@@ -1458,10 +1468,6 @@ msgstr ""
" Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє¢тєтυя α∂ιριѕι¢ιηg єłιт, ѕє∂ ∂σ єιυѕмσ∂ тємρσя ιη¢ι∂ι∂υηт υт łαвσяє єт ∂σłσяє мαgηα αłιqυα. υт єηιм α∂ мιηιм νєηιαм, qυιѕ ησѕтяυ∂ єχєя¢ιтαтιση υłłαм¢σ łαвσяιѕ ηιѕι υт αłιqυιρ єχ єα ¢σммσ∂σ ¢σηѕєqυαт. ∂υιѕ αυтє ι#"
#: templates/publisher/add_courserun_form.html
msgid "COURSE NUMBER"
msgstr "ÇÖÛRSÉ NÛMBÉR Ⱡ'σяєм ιρѕυм ∂σłσя ѕι#"
#: templates/publisher/add_courserun_form.html
msgid ""
"\n"
" Courses split into several modules can be denoted by adding .1, .2, etc. at the end of the\n"
......@@ -1486,10 +1492,6 @@ msgid "etc."
msgstr "étç. Ⱡ'σяєм ι#"
#: templates/publisher/add_courserun_form.html
msgid "COURSE END DATE"
msgstr "ÇÖÛRSÉ ÉND DÀTÉ Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт α#"
#: templates/publisher/add_courserun_form.html
msgid "CERTIFICATE TYPE AND PRICE"
msgstr "ÇÉRTÌFÌÇÀTÉ TÝPÉ ÀND PRÌÇÉ Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕ#"
......@@ -1619,6 +1621,11 @@ msgid "Course Length (weeks)"
msgstr "Çöürsé Léngth (wééks) Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, #"
#: templates/publisher/course_run_detail/_all.html
#: templates/publisher/course_run_detail/_studio.html
msgid "Pacing Type"
msgstr "Päçïng Týpé Ⱡ'σяєм ιρѕυм ∂σłσя #"
#: templates/publisher/course_run_detail/_all.html
#: templates/publisher/course_run_detail/_drupal.html
msgid "Estimated Effort"
msgstr "Éstïmätéd Éffört Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αм#"
......@@ -1747,6 +1754,19 @@ msgid "XSeries"
msgstr "XSérïés Ⱡ'σяєм ιρѕυм #"
#: templates/publisher/course_run_detail/_drupal.html
#: templates/publisher/course_run_detail/_salesforce.html
#: templates/publisher/course_run_detail/_studio.html
#: templates/publisher/dashboard/_studio_requests.html
msgid "Start Date"
msgstr "Stärt Däté Ⱡ'σяєм ιρѕυм ∂σłσ#"
#: templates/publisher/course_run_detail/_drupal.html
#: templates/publisher/course_run_detail/_salesforce.html
#: templates/publisher/course_run_detail/_studio.html
msgid "End Date"
msgstr "Énd Däté Ⱡ'σяєм ιρѕυм ∂#"
#: templates/publisher/course_run_detail/_drupal.html
msgid "Self Paced"
msgstr "Sélf Päçéd Ⱡ'σяєм ιρѕυм ∂σłσ#"
......@@ -2171,5 +2191,13 @@ msgid "Seat Form"
msgstr "Séät Förm Ⱡ'σяєм ιρѕυм ∂σł#"
#: templates/publisher/view_course_form.html
msgid "Base information"
msgstr "Bäsé ïnförmätïön Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αм#"
#: templates/publisher/view_course_form.html
msgid "INSTITUTION INFORMATION"
msgstr "ÌNSTÌTÛTÌÖN ÌNFÖRMÀTÌÖN Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт, ¢σ#"
#: templates/publisher/view_course_form.html
msgid "Course information"
msgstr "Çöürsé ïnförmätïön Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт#"
......@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-12-29 14:13+0500\n"
"POT-Creation-Date: 2016-12-30 14:38+0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
......
......@@ -4,10 +4,10 @@ function addDatePicker() {
if (el.getAttribute('datepicker-initialized') !== 'true') {
new Pikaday({
field: el,
format: 'YYYY-MM-DD',
format: 'YYYY-MM-DD hh:mm:ss',
defaultDate: $(el).val(),
setDefaultDate: true,
showTime: false,
showTime: true,
use24hour: false,
autoClose: true
});
......
......@@ -398,6 +398,12 @@ $light-gray: rgba(204, 204, 204, 1);
@include margin(0px, 0px, 0px, 0px);
box-shadow: none;
}
.input-checkbox{
&.has-error{
border-radius: 100%;
box-shadow: 0px 1px 0px 2px red;
}
}
}
input,
......@@ -448,6 +454,11 @@ select {
.field-label {
font-weight: bold;
}
.help-text {
p {
margin-bottom: 0;
}
}
.course-tabs{
@include float(left);
@include margin-right(10px);
......
......@@ -23,39 +23,31 @@
<form class="form" method="post" action="" enctype="multipart/form-data">
{% csrf_token %}
<div class="layout-full publisher-layout layout">
<h2 class="layout-title">{% trans "Base information" %}</h2>
<h2 class="layout-title">{% trans "Studio instance information" %}</h2>
<div class="card course-form">
<p>
{% trans "The information in this section is required to create a course studio instance. You must fill all required information but are welcome to come back and enter the rest of the information when you are ready to announce the course, or you can do it all at once if you are ready to do so." %}
</p>
<div class="course-information">
<fieldset class="form-group grid-container grid-manual">
<div class="field-title">{% trans "INSTITUTION INFORMATION" %}</div>
<div class="field-title">{% trans "CONTACTED PARTNER MANAGER" %}</div>
<div class="row">
<div class="col col-6 help-text">
{% trans "Please choose the school that will be providing the course. Once chosen then you can select an administrator for the studio shell." %}
{% trans "Contacted a PM about the creation of a new course is important so that edx can help you on marketing efforts." %}
</div>
<div class="col col-6">
{% if course_form.organization.field.queryset.all.count > 1 %}
<label class="field-label">{{ course_form.organization.label_tag }} <span
class="required">* {% trans "required" %}</span> </label>
{{ course_form.organization }}
{% else %}
{% with course_form.organization.field.queryset|first as organization %}
<label id="organization-name" class="field-label"
data-org_id="{{ organization.id }}">{{ course_form.organization.label_tag }} {{ organization.name }}
</label>
<input id="id_organization" name="organization" type="hidden" value="{{ organization.id }}">
{% endwith %}
{% endif %}
<label class="field-label">
{{ course_form.team_admin.label_tag }} <span class="required">* {% trans "required" %}</span>
</label> {{ course_form.team_admin }}
{{ run_form.contacted_partner_manager.label_tag }}
<span class="required">* {% trans "required" %}</span>
</label>
<div class="checkbox-inline">{{ run_form.contacted_partner_manager}}</div>
</div>
</div>
<div class="field-title">{% trans "Course Title" %}</div>
<div class="field-title">{% trans "COURSE TITLE" %}</div>
<div class="row">
<div class="col col-6 help-text">
<div class="row">
......@@ -70,41 +62,45 @@
</div>
<div id="tab-practices" class="content active">
<p>{% trans "Concise 70 characters maximum; < 50 chars. recommended." %}</p>
<p>{% trans "Descriptive - clearly indicates what the course is about." %}</p>
<p>{% trans "SEO-optimized and targeted to a global audience." %}</p>
<p>{% trans 'If the course falls in a sequence, our titling convention is: "Course Title: Subtitle"' %}</p>
</div>
<div id="tab-example" class="content">
{% trans "English Grammar and Essay Writing Sequence Courses:" %}
<ul>
<li>{% trans "Introduction to Statistics" %}</li>
<li>{% trans "Statistics: Inference" %}</li>
<li>{% trans "Statistics: Probability" %}</li>
</ul>
<p>“{% trans "English Grammar and Essay Writing" %}”</p>
<p>{% trans "Sequence Courses:" %}</p>
<p>“{% trans "Introduction to Statistics" %}”</p>
<p>“{% trans "Statistics: Inference" %}”</p>
<p>“{% trans "Statistics: Probability" %}”</p>
</div>
</div>
<div class="col col-6">
{% if course_form.organization.field.queryset.all.count > 1 %}
<label class="field-label">{{ course_form.organization.label_tag }} <span
class="required">* {% trans "required" %}</span> </label>
{{ course_form.organization }}
{% else %}
{% with course_form.organization.field.queryset|first as organization %}
<label id="organization-name" class="field-label"
data-org_id="{{ organization.id }}">{{ course_form.organization.label_tag }} {{ organization.name }}
</label>
<input id="id_organization" name="organization" type="hidden" value="{{ organization.id }}">
{% endwith %}
{% endif %}
<label class="field-label">
{{ course_form.team_admin.label_tag }} <span class="required">* {% trans "required" %}</span>
</label> {{ course_form.team_admin }}
<label class="field-label ">{{ course_form.title.label }}
<span class="required">* {% trans "required" %}</span>
</label>
{{ course_form.title }}
<label class="field-label ">{{ run_form.contacted_partner_manager.label_tag }}</label>
<div class="checkbox-inline">{{ run_form.contacted_partner_manager}}</div>
<label class="field-label">{% trans "Priority content" %}</label>
<div class="checkbox-inline">{{ run_form.target_content}}</div>
</div>
</div>
<div class="field-title">{% trans "Start Date" %}</div>
<div class="field-title">{% trans "COURSE START DATE" %}</div>
<div class="row">
<div class="col col-6 help-text">
{% trans "Start on a weekday (preferably Tuesday, Wednesday, or Thursday) and avoid major U.S. holidays for best access to edX staff." %}
......@@ -118,22 +114,41 @@
</div>
</div>
<div class="field-title">{% trans "Pacing Type" %}</div>
<div class="field-title">{% trans "COURSE END DATE" %}</div>
<div class="row">
<div class="col col-6 help-text">
{% trans "The date when this self-paced course run will end, replaced by an updated version of the course" %}
</div>
<div class="col col-6">
<label class="field-label ">
{{ run_form.end.label_tag }}
<span class="required">* {% trans "required" %}</span>
</label>
{{ run_form.end }}
</div>
</div>
<div class="field-title">{% trans "PACING TYPE" %}</div>
<div class="row">
<div class="col col-6 help-text">
{% trans "Will your course be open to students at the same time as it is announced?" %}
</div>
<div class="col col-6">
<label class="field-label ">{{ run_form.pacing_type.label_tag }}</label>
{{ run_form.pacing_type }}
<label class="field-label">
{{ run_form.pacing_type.label_tag }}
<span class="required">* {% trans "required" %}</span>
</label>
<div class="checkbox-inline">{{ run_form.pacing_type }}</div>
</div>
</div>
<div class="field-title">{% trans "Course Number" %}</div>
<div class="field-title">{% trans "COURSE NUMBER" %}</div>
<div class="row">
<div class="col col-6 help-text">
{% trans 'Courses split into several modules can be denoted by adding .1, .2, etc. at the end of the course number before the “x”' %}
{% trans 'No special html characters, accents, spaces, dashes, or underscores 10 character limit' %}
<p>{% trans 'Courses split into several modules can be denoted by adding .1, .2, etc. at the end of the course number before the “x”' %}</p>
<p>{% trans 'No special html characters, accents, spaces, dashes, or underscores' %}</p>
<p>{% trans '10 character limit' %}</p>
</div>
<div class="col col-6">
<label class="field-label ">{{ course_form.number.label_tag }}
......@@ -155,17 +170,6 @@
<div class="course-information">
<fieldset class="form-group grid-container grid-manual">
<div class="field-title">{% trans "End Date" %}</div>
<div class="row">
<div class="col col-6 help-text">
{% trans "The date when this self-paced course run will end, replaced by an updated version of the course" %}
</div>
<div class="col col-6">
<label class="field-label ">{{ run_form.end.label_tag }}</label>
{{ run_form.end }}
</div>
</div>
<div class="field-title">{% trans "Seat Type" %}</div>
<div class="row">
<div class="col col-6 help-text">
......
......@@ -124,11 +124,19 @@
</label>
{{ run_form.start }}
</div>
<div class="col col-6">
<div>
</div>
<div class="field-title">{% trans "PACING TYPE" %}</div>
<div class="row">
<div class="col col-6 help-text">
{% trans "Will your course be open to students at the same time as it is announced?" %}
</div>
{{ run_form.is_self_paced }} {{ run_form.is_self_paced.label_tag }}
<div class="col col-6">
<label class="field-label">
{{ run_form.pacing_type.label_tag }}
<span class="required">* {% trans "required" %}</span>
</label>
<div class="checkbox-inline">{{ run_form.pacing_type }}</div>
</div>
</div>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment