Commit 3b4d913f by Awais Qureshi Committed by GitHub

Merge pull request #383 from edx/awais786/ECOM-6003-course-cleanup

Awais786/ecom 6003 course cleanup
parents e53a3db7 ed241967
......@@ -37,6 +37,8 @@ class BaseCourseForm(forms.ModelForm):
class CourseForm(BaseCourseForm):
""" Course Form. """
short_description = forms.CharField(widget=forms.Textarea, max_length=255, required=False)
class Meta:
model = Course
fields = '__all__'
......@@ -57,7 +59,7 @@ class CustomCourseForm(CourseForm):
'title', 'number', 'short_description', 'full_description',
'expected_learnings', 'level_type', 'primary_subject', 'secondary_subject',
'tertiary_subject', 'prerequisites', 'level_type', 'image', 'team_admin',
'level_type', 'institution',
'level_type', 'institution', 'is_seo_review', 'keywords',
)
......@@ -87,10 +89,9 @@ class CustomCourseRunForm(CourseRunForm):
class Meta(CourseRunForm.Meta):
fields = (
'keywords', 'start', 'end', 'length',
'transcript_languages', 'language', 'min_effort', 'max_effort', 'keywords',
'contacted_partner_manager', 'target_content', 'pacing_type', 'is_seo_review',
'video_language', 'staff',
'length', 'transcript_languages', 'language', 'min_effort', 'max_effort',
'contacted_partner_manager', 'target_content', 'pacing_type',
'video_language', 'staff', 'start', 'end',
)
......
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import migrations, models
import taggit.managers
class Migration(migrations.Migration):
dependencies = [
('taggit', '0002_auto_20150616_2121'),
('publisher', '0011_userattributes'),
]
operations = [
# This is custom alteration to make migration reversible
migrations.AlterField(
model_name='courserun',
name='keywords',
field=models.TextField(verbose_name='keywords', default=None, blank=True),
preserve_default=False,
),
migrations.AlterField(
model_name='historicalcourserun',
name='keywords',
field=models.TextField(verbose_name='keywords', default=None, blank=True),
preserve_default=False,
),
# end custom migration
migrations.RemoveField(
model_name='courserun',
name='is_seo_review',
),
migrations.RemoveField(
model_name='courserun',
name='keywords',
),
migrations.RemoveField(
model_name='historicalcourserun',
name='is_seo_review',
),
migrations.RemoveField(
model_name='historicalcourserun',
name='keywords',
),
migrations.AddField(
model_name='course',
name='is_seo_review',
field=models.BooleanField(default=False),
),
migrations.AddField(
model_name='course',
name='keywords',
field=taggit.managers.TaggableManager(help_text='A comma-separated list of tags.', verbose_name='keywords', through='taggit.TaggedItem', blank=True, to='taggit.Tag'),
),
migrations.AddField(
model_name='historicalcourse',
name='is_seo_review',
field=models.BooleanField(default=False),
),
]
......@@ -11,6 +11,7 @@ from guardian.shortcuts import assign_perm, get_groups_with_perms
from simple_history.models import HistoricalRecords
from sortedm2m.fields import SortedManyToManyField
from stdimage.models import StdImageField
from taggit.managers import TaggableManager
from course_discovery.apps.core.models import User, Currency
from course_discovery.apps.course_metadata.choices import CourseRunPacing
......@@ -129,6 +130,9 @@ class Course(TimeStampedModel, ChangedByMixin):
}
)
is_seo_review = models.BooleanField(default=False)
keywords = TaggableManager(blank=True, verbose_name='keywords')
history = HistoricalRecords()
def __str__(self):
......@@ -156,6 +160,14 @@ class Course(TimeStampedModel, ChangedByMixin):
available_groups = get_groups_with_perms(self)
return available_groups[0] if available_groups else None
@property
def keywords_data(self):
keywords = self.keywords.all()
if keywords:
return ', '.join(k.name for k in keywords)
return None
class CourseRun(TimeStampedModel, ChangedByMixin):
""" Publisher CourseRun model. It contains fields related to the course run intake form."""
......@@ -212,11 +224,7 @@ class CourseRun(TimeStampedModel, ChangedByMixin):
is_micromasters = models.BooleanField(default=False)
micromasters_name = models.CharField(max_length=255, null=True, blank=True)
contacted_partner_manager = models.BooleanField(default=False)
is_seo_review = models.BooleanField(default=False)
keywords = models.TextField(
default=None, blank=True, help_text=_("Please add top 10 comma separated keywords for your course content")
)
notes = models.TextField(
default=None, null=True, blank=True, help_text=_(
"Please add any additional notes or special instructions for the course About Page."
......
......@@ -54,7 +54,6 @@ class CourseRunFactory(factory.DjangoModelFactory):
language = factory.Iterator(LanguageTag.objects.all())
pacing_type = FuzzyChoice([name for name, __ in CourseRunPacing.choices])
length = FuzzyInteger(1, 10)
keywords = "Test1, Test2, Test3"
notes = "Testing notes"
class Meta:
......
......@@ -92,6 +92,16 @@ class CourseTests(TestCase):
self.assertFalse(user1.has_perm(Course.VIEW_PERMISSION, self.course2))
self.assertFalse(user2.has_perm(Course.VIEW_PERMISSION, self.course))
def test_keywords_data(self):
""" Verify that the property returns the keywords as comma separated string. """
self.assertFalse(self.course.keywords_data)
self.course.keywords.add('abc')
self.assertEqual(self.course.keywords_data, 'abc')
self.course.keywords.add('def')
self.assertIn('abc', self.course.keywords_data)
self.assertIn('def', self.course.keywords_data)
class SeatTests(TestCase):
""" Tests for the publisher `Seat` model. """
......
......@@ -237,6 +237,7 @@ class CreateUpdateCourseViewTests(TestCase):
def _post_data(self, data, course, course_run, seat):
course_dict = model_to_dict(course)
course_dict.update(**data)
course_dict['keywords'] = 'abc def xyz'
if course_run:
course_dict.update(**model_to_dict(course_run))
course_dict.pop('video_language')
......@@ -287,6 +288,9 @@ class CreateUpdateCourseViewTests(TestCase):
response = self.client.get(reverse('publisher:publisher_courses_readonly', kwargs={'pk': course.id}))
self.assertEqual(response.status_code, 200)
# django-taggit stores data without any order. For test .
self.assertEqual(sorted([c.name for c in course.keywords.all()]), ['abc', 'def', 'xyz'])
class CreateUpdateCourseRunViewTests(TestCase):
""" Tests for the publisher `CreateCourseRunView` and `UpdateCourseRunView`. """
......
......@@ -146,3 +146,10 @@ class CourseRunWrapperTests(TestCase):
self.course_run.start = current_date
self.course_run.save()
self.assertEqual(self.wrapped_course_run.mdc_submission_due_date, expected_date)
def test_keywords(self):
""" Verify that the wrapper return the course keywords. """
self.assertEqual(
self.wrapped_course_run.keywords,
self.course.keywords_data
)
......@@ -101,6 +101,8 @@ class CreateCourseView(mixins.LoginRequiredMixin, CreateView):
course = course_form.save(commit=False)
course.changed_by = self.request.user
course.save()
# commit false does not save m2m object. Keyword field is m2m.
course_form.save_m2m()
run_course.course = course
run_course.changed_by = self.request.user
......
......@@ -182,3 +182,7 @@ class CourseRunWrapper(BaseWrapper):
@property
def verification_deadline(self):
return self.wrapped_obj.course.verification_deadline
@property
def keywords(self):
return self.wrapped_obj.course.keywords_data
......@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-10-21 07:12+0000\n"
"POT-Creation-Date: 2016-10-23 15:52+0000\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"
......@@ -199,7 +199,7 @@ msgid "Partners"
msgstr ""
#: course_discovery/apps/course_metadata/choices.py:6
#: course_discovery/apps/publisher/models.py:44
#: course_discovery/apps/publisher/models.py:45
msgid "Published"
msgstr ""
......@@ -293,13 +293,13 @@ msgid ""
msgstr ""
#: course_discovery/apps/course_metadata/models.py:352
#: course_discovery/apps/publisher/models.py:193
#: course_discovery/apps/publisher/models.py:204
msgid ""
"Estimated minimum number of hours per week needed to complete a course run."
msgstr ""
#: course_discovery/apps/course_metadata/models.py:355
#: course_discovery/apps/publisher/models.py:196
#: course_discovery/apps/publisher/models.py:207
msgid ""
"Estimated maximum number of hours per week needed to complete a course run."
msgstr ""
......@@ -325,17 +325,17 @@ msgid "Upcoming"
msgstr ""
#: course_discovery/apps/course_metadata/models.py:513
#: course_discovery/apps/publisher/models.py:280
#: course_discovery/apps/publisher/models.py:287
msgid "Honor"
msgstr ""
#: course_discovery/apps/course_metadata/models.py:514
#: course_discovery/apps/publisher/models.py:281
#: course_discovery/apps/publisher/models.py:288
msgid "Audit"
msgstr ""
#: course_discovery/apps/course_metadata/models.py:515
#: course_discovery/apps/publisher/models.py:282
#: course_discovery/apps/publisher/models.py:289
msgid "Verified"
msgstr ""
......@@ -344,7 +344,7 @@ msgid "Professional"
msgstr ""
#: course_discovery/apps/course_metadata/models.py:517
#: course_discovery/apps/publisher/models.py:285
#: course_discovery/apps/publisher/models.py:292
msgid "Credit"
msgstr ""
......@@ -412,148 +412,144 @@ msgstr ""
msgid "JSON string containing an elasticsearch function score config."
msgstr ""
#: course_discovery/apps/publisher/forms.py:77
#: course_discovery/apps/publisher/forms.py:85
#: course_discovery/apps/publisher/forms.py:79
#: course_discovery/apps/publisher/forms.py:87
msgid "Yes"
msgstr ""
#: course_discovery/apps/publisher/forms.py:77
#: course_discovery/apps/publisher/forms.py:85
#: course_discovery/apps/publisher/forms.py:79
#: course_discovery/apps/publisher/forms.py:87
msgid "No"
msgstr ""
#: course_discovery/apps/publisher/forms.py:131
#: course_discovery/apps/publisher/forms.py:132
msgid "Only honor/audit seats can be without price."
msgstr ""
#: course_discovery/apps/publisher/models.py:40
#: course_discovery/apps/publisher/models.py:41
msgid "Draft"
msgstr ""
#: course_discovery/apps/publisher/models.py:41
#: course_discovery/apps/publisher/models.py:42
msgid "Needs Review"
msgstr ""
#: course_discovery/apps/publisher/models.py:42
#: course_discovery/apps/publisher/models.py:43
msgid "Needs Final Approval"
msgstr ""
#: course_discovery/apps/publisher/models.py:43
#: course_discovery/apps/publisher/models.py:44
msgid "Finalized"
msgstr ""
#: course_discovery/apps/publisher/models.py:84
#: course_discovery/apps/publisher/models.py:85
msgid "Course title"
msgstr ""
#: course_discovery/apps/publisher/models.py:85
#: course_discovery/apps/publisher/models.py:86
msgid "Course number"
msgstr ""
#: course_discovery/apps/publisher/models.py:87
#: course_discovery/templates/publisher/add_course_form.html:199
#: course_discovery/apps/publisher/models.py:88
#: course_discovery/templates/publisher/add_course_form.html:195
msgid "Brief Description"
msgstr ""
#: course_discovery/apps/publisher/models.py:89
#: course_discovery/apps/publisher/models.py:90
msgid "Full Description"
msgstr ""
#: course_discovery/apps/publisher/models.py:91
#: course_discovery/apps/publisher/models.py:92
#: course_discovery/templates/publisher/course_run_detail/_all.html:41
msgid "Partner Name"
msgstr ""
#: course_discovery/apps/publisher/models.py:94
#: course_discovery/apps/publisher/models.py:95
msgid "Level Type"
msgstr ""
#: course_discovery/apps/publisher/models.py:96
#: course_discovery/apps/publisher/models.py:97
msgid "Expected Learnings"
msgstr ""
#: course_discovery/apps/publisher/models.py:98
#: course_discovery/apps/publisher/models.py:99
#: course_discovery/templates/publisher/course_run_detail/_all.html:213
msgid "Prerequisites"
msgstr ""
#: course_discovery/apps/publisher/models.py:103
#: course_discovery/apps/publisher/models.py:104
msgid "Verification deadline"
msgstr ""
#: course_discovery/apps/publisher/models.py:104
#: course_discovery/apps/publisher/models.py:105
msgid "Last date/time on which verification for this product can be submitted."
msgstr ""
#: course_discovery/apps/publisher/models.py:169
#: course_discovery/apps/publisher/models.py:180
msgid "Level 1"
msgstr ""
#: course_discovery/apps/publisher/models.py:170
#: course_discovery/apps/publisher/models.py:181
msgid "Level 2"
msgstr ""
#: course_discovery/apps/publisher/models.py:171
#: course_discovery/apps/publisher/models.py:182
msgid "Level 3"
msgstr ""
#: course_discovery/apps/publisher/models.py:172
#: course_discovery/apps/publisher/models.py:183
msgid "Level 4"
msgstr ""
#: course_discovery/apps/publisher/models.py:173
#: course_discovery/apps/publisher/models.py:184
msgid "Level 5"
msgstr ""
#: course_discovery/apps/publisher/models.py:199
#: course_discovery/apps/publisher/models.py:210
msgid "Content Language"
msgstr ""
#: course_discovery/apps/publisher/models.py:205
#: course_discovery/templates/publisher/add_course_form.html:402
#: course_discovery/apps/publisher/models.py:216
#: course_discovery/templates/publisher/add_course_form.html:398
msgid "Length of course, in number of weeks"
msgstr ""
#: course_discovery/apps/publisher/models.py:218
msgid "Please add top 10 comma separated keywords for your course content"
msgstr ""
#: course_discovery/apps/publisher/models.py:222
#: course_discovery/apps/publisher/models.py:229
msgid ""
"Please add any additional notes or special instructions for the course About "
"Page."
msgstr ""
#: course_discovery/apps/publisher/models.py:230
#: course_discovery/apps/publisher/models.py:237
msgid "Comma separated list of edX usernames or emails of admins."
msgstr ""
#: course_discovery/apps/publisher/models.py:234
#: course_discovery/apps/publisher/models.py:241
msgid "Comma separated list of edX usernames or emails of additional staff."
msgstr ""
#: course_discovery/apps/publisher/models.py:283
#: course_discovery/apps/publisher/models.py:290
msgid "Professional (with ID verification)"
msgstr ""
#: course_discovery/apps/publisher/models.py:284
#: course_discovery/apps/publisher/models.py:291
msgid "Professional (no ID verifiation)"
msgstr ""
#: course_discovery/apps/publisher/views.py:120
#: course_discovery/apps/publisher/views.py:122
msgid "Course created successfully."
msgstr ""
#: course_discovery/apps/publisher/views.py:126
#: course_discovery/apps/publisher/views.py:128
msgid "Please fill all required field."
msgstr ""
#: course_discovery/apps/publisher/views.py:245
#: course_discovery/apps/publisher/views.py:247
#, python-brace-format
msgid "Content moved to `{state}` successfully."
msgstr ""
#: course_discovery/apps/publisher/views.py:249
#: course_discovery/apps/publisher/views.py:251
msgid "There was an error in changing state."
msgstr ""
......@@ -698,366 +694,366 @@ msgstr ""
msgid "Course Form"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:32
#: course_discovery/templates/publisher/add_course_form.html:28
#: course_discovery/templates/publisher/view_course_form.html:23
msgid "Base information"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:38
#: course_discovery/templates/publisher/add_course_form.html:34
#: course_discovery/templates/publisher/view_course_form.html:29
msgid "INSTITUTION INFORMATION"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:41
#: course_discovery/templates/publisher/add_course_form.html:37
msgid ""
"Please choose the school that will be providing the course. Once chosen then "
"you can select an administrator for the studio shell."
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:45
#: course_discovery/templates/publisher/add_course_form.html:51
#: course_discovery/templates/publisher/add_course_form.html:92
#: course_discovery/templates/publisher/add_course_form.html:115
#: course_discovery/templates/publisher/add_course_form.html:140
#: course_discovery/templates/publisher/add_course_form.html:178
#: course_discovery/templates/publisher/add_course_form.html:41
#: course_discovery/templates/publisher/add_course_form.html:47
#: course_discovery/templates/publisher/add_course_form.html:88
#: course_discovery/templates/publisher/add_course_form.html:111
#: course_discovery/templates/publisher/add_course_form.html:136
#: course_discovery/templates/publisher/add_course_form.html:174
msgid "required"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:58
#: course_discovery/templates/publisher/add_course_form.html:54
msgid "Course Title"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:64
#: course_discovery/templates/publisher/add_course_form.html:60
msgid "Best Practices"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:67
#: course_discovery/templates/publisher/add_course_form.html:63
msgid "Example"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:72
#: course_discovery/templates/publisher/add_course_form.html:68
msgid "Concise 70 characters maximum; < 50 chars. recommended."
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:74
#: course_discovery/templates/publisher/add_course_form.html:70
msgid "Descriptive - clearly indicates what the course is about."
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:76
#: course_discovery/templates/publisher/add_course_form.html:72
msgid "SEO-optimized and targeted to a global audience."
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:78
#: course_discovery/templates/publisher/add_course_form.html:74
msgid ""
"If the course falls in a sequence, our titling convention is: \"Course "
"Title: Subtitle\""
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:81
#: course_discovery/templates/publisher/add_course_form.html:77
msgid "English Grammar and Essay Writing Sequence Courses:"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:83
#: course_discovery/templates/publisher/add_course_form.html:79
msgid "Introduction to Statistics"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:84
#: course_discovery/templates/publisher/add_course_form.html:80
msgid "Statistics: Inference"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:85
#: course_discovery/templates/publisher/add_course_form.html:81
msgid "Statistics: Probability"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:100
#: course_discovery/templates/publisher/add_course_form.html:96
msgid "Priority content"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:107
#: course_discovery/templates/publisher/add_course_form.html:103
#: course_discovery/templates/publisher/course_run_detail/_drupal.html:57
#: course_discovery/templates/publisher/course_run_detail/_salesforce.html:162
#: course_discovery/templates/publisher/course_run_detail/_studio.html:29
msgid "Start Date"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:110
#: course_discovery/templates/publisher/add_course_form.html:106
msgid ""
"Start on a weekday (preferably Tuesday, Wednesday, or Thursday) and avoid "
"major U.S. holidays for best access to edX staff."
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:111
#: course_discovery/templates/publisher/add_course_form.html:107
msgid ""
"Approximate dates are acceptable; If you are unable to give an exact date, "
"please identify a month in which the course will be offered."
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:121
#: course_discovery/templates/publisher/add_course_form.html:117
#: course_discovery/templates/publisher/course_run_detail/_all.html:138
#: course_discovery/templates/publisher/course_run_detail/_studio.html:57
msgid "Pacing Type"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:124
#: course_discovery/templates/publisher/add_course_form.html:120
msgid ""
"Will your course be open to students at the same time as it is announced?"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:132
#: course_discovery/templates/publisher/add_course_form.html:128
msgid "Course Number"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:135
#: course_discovery/templates/publisher/add_course_form.html:131
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 ""
#: course_discovery/templates/publisher/add_course_form.html:136
#: course_discovery/templates/publisher/add_course_form.html:132
msgid ""
"No special html characters, accents, spaces, dashes, or underscores 10 "
"character limit"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:153
#: course_discovery/templates/publisher/add_course_form.html:149
msgid "About page information"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:158
#: course_discovery/templates/publisher/add_course_form.html:154
#: course_discovery/templates/publisher/course_run_detail/_drupal.html:63
#: course_discovery/templates/publisher/course_run_detail/_salesforce.html:169
#: course_discovery/templates/publisher/course_run_detail/_studio.html:36
msgid "End Date"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:161
#: course_discovery/templates/publisher/add_course_form.html:172
#: course_discovery/templates/publisher/add_course_form.html:157
#: course_discovery/templates/publisher/add_course_form.html:168
msgid ""
"The date when this self-paced course run will end, replaced by an updated "
"version of the course"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:169
#: course_discovery/templates/publisher/add_course_form.html:165
#: course_discovery/templates/publisher/course_run_detail/_seats.html:7
msgid "Seat Type"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:203
#: course_discovery/templates/publisher/add_course_form.html:199
msgid ""
"Reads as a tag line - a short, engaging description for students browsing "
"course listings"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:205
#: course_discovery/templates/publisher/add_course_form.html:201
msgid "Conveys why someone should take the course"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:206
#: course_discovery/templates/publisher/add_course_form.html:221
#: course_discovery/templates/publisher/add_course_form.html:202
#: course_discovery/templates/publisher/add_course_form.html:217
msgid "SEO optimized and targeted to a global audience"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:215
#: course_discovery/templates/publisher/add_course_form.html:211
msgid "FULL DESCRIPTION"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:218
#: course_discovery/templates/publisher/add_course_form.html:214
msgid "Summarized description of course content"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:220
#: course_discovery/templates/publisher/add_course_form.html:216
msgid "Describe why a learner should take this course"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:222
#: course_discovery/templates/publisher/add_course_form.html:218
msgid ""
"Text should be easily scannable, using bullet points to highlight instead of "
"long, dense text paragraphs"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:225
#: course_discovery/templates/publisher/add_course_form.html:221
msgid ""
"Note: the first 4-5 lines will be visible to the learner immediately upon "
"clicking the page;"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:226
#: course_discovery/templates/publisher/add_course_form.html:222
msgid ""
"additional text will be hidden yet available via \"See More\" clickable text "
"under the first 4-5 lines"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:237
#: course_discovery/templates/publisher/add_course_form.html:233
msgid "EXPECTED LEARNINGS"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:241
#: course_discovery/templates/publisher/add_course_form.html:237
msgid "Answer to the question: \"What will you learn from this course?\""
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:242
#: course_discovery/templates/publisher/add_course_form.html:238
msgid "bulleted items, approximately 4-10 words per bullet"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:251
#: course_discovery/templates/publisher/add_course_form.html:247
msgid "COURSE STAFF"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:255
#: course_discovery/templates/publisher/add_course_form.html:251
msgid ""
"If there is more than one instructor, please indicate the order in which the "
"instructors should be listed"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:257
#: course_discovery/templates/publisher/add_course_form.html:253
msgid "Limited to the primary instructors a learner will encounter in videos"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:265
#: course_discovery/templates/publisher/add_course_form.html:261
msgid "KEYWORDS"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:268
#: course_discovery/templates/publisher/add_course_form.html:264
msgid "Some instructions here???"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:279
#: course_discovery/templates/publisher/add_course_form.html:275
msgid "SUBJECT FIELD"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:282
#: course_discovery/templates/publisher/add_course_form.html:278
msgid ""
"Only one primary subject will appear on the About Page; please select one "
"primary subject and a maximum of two additional subject areas for search."
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:308
#: course_discovery/templates/publisher/add_course_form.html:304
msgid "COURSE IMAGE"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:311
#: course_discovery/templates/publisher/add_course_form.html:307
msgid ""
"Select an eye-catching, colorful image that captures the content and essence "
"of your course"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:313
#: course_discovery/templates/publisher/add_course_form.html:309
msgid "Do not include text or headlines"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:314
#: course_discovery/templates/publisher/add_course_form.html:310
msgid "Choose an image that you have permission to use."
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:315
#: course_discovery/templates/publisher/add_course_form.html:311
msgid "This can be a stock photo (try Flickr creative commons, "
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:316
#: course_discovery/templates/publisher/add_course_form.html:312
msgid ""
"Stock Vault, Stock XCHNG, iStock Photo) or an image custom designed for your "
"course"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:318
#: course_discovery/templates/publisher/add_course_form.html:314
msgid "Sequenced courses should each have a unique image"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:319
#: course_discovery/templates/publisher/add_course_form.html:315
msgid "Size: 2120 x 1192 pixels"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:328
#: course_discovery/templates/publisher/add_course_form.html:324
msgid "PREREQUISITES"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:332
#: course_discovery/templates/publisher/add_course_form.html:328
msgid ""
"List concepts and level (basic, advanced, undergraduate, graduate) students "
"should be familiar with"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:334
#: course_discovery/templates/publisher/add_course_form.html:330
msgid "If there are no prerequisites, please list \"None.\""
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:335
#: course_discovery/templates/publisher/add_course_form.html:331
msgid "200 character limit, including spaces"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:344
#: course_discovery/templates/publisher/add_course_form.html:340
msgid "ESTIMATED EFFORT"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:348
#: course_discovery/templates/publisher/add_course_form.html:344
msgid ""
"Number of hours per week the learner should expect to spend on the course to "
"be successful"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:350
#: course_discovery/templates/publisher/add_course_form.html:346
msgid "Should be realistic, and can be a range"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:356
#: course_discovery/templates/publisher/add_course_form.html:352
msgid "Min Effort"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:360
#: course_discovery/templates/publisher/add_course_form.html:356
msgid "Max Effort"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:369
#: course_discovery/templates/publisher/add_course_form.html:365
msgid "LANGUAGE(S)"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:374
#: course_discovery/templates/publisher/add_course_form.html:370
msgid "Course content (navigation and course content excluding videos)"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:377
#: course_discovery/templates/publisher/add_course_form.html:373
msgid "Videos (language spoken in course videos)"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:380
#: course_discovery/templates/publisher/add_course_form.html:376
msgid "Video transcript (video caption language)"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:398
#: course_discovery/templates/publisher/add_course_form.html:394
msgid "LENGTH"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:403
#: course_discovery/templates/publisher/add_course_form.html:399
msgid "If the time between start/end dates is not exact, ex: 8.5 weeks, "
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:404
#: course_discovery/templates/publisher/add_course_form.html:400
msgid "indicate whether the course should be listed as 8 weeks or 9 weeks."
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:414
#: course_discovery/templates/publisher/add_course_form.html:410
msgid "LEVEL TYPE"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:418
#: course_discovery/templates/publisher/add_course_form.html:414
msgid ""
"Introductory - No prerequisites; an individual with some to all of a "
"secondary school degree could complete"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:421
#: course_discovery/templates/publisher/add_course_form.html:417
msgid ""
"Intermediate - Basic prerequisites; a secondary school degree likely "
"required to be successful as well as some university"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:424
#: course_discovery/templates/publisher/add_course_form.html:420
msgid ""
"Advanced - Significant number of prerequisites required; course geared to "
"3rd or 4th year university student or a masters degree student"
msgstr ""
#: course_discovery/templates/publisher/add_course_form.html:442
#: course_discovery/templates/publisher/add_course_form.html:438
msgid "Save Draft"
msgstr ""
......
......@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-10-21 07:12+0000\n"
"POT-Creation-Date: 2016-10-23 15:52+0000\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-10-21 07:12+0000\n"
"POT-Creation-Date: 2016-10-23 15:52+0000\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"
......@@ -619,12 +619,6 @@ msgstr ""
"¢σηѕє¢тєтυ#"
#: course_discovery/apps/publisher/models.py
msgid "Please add top 10 comma separated keywords for your course content"
msgstr ""
"Pléäsé ädd töp 10 çömmä sépärätéd kéýwörds för ýöür çöürsé çöntént Ⱡ'σяєм "
"ιρѕυм ∂σłσя ѕιт αмєт, ¢σηѕє¢тєтυя #"
#: course_discovery/apps/publisher/models.py
msgid ""
"Please add any additional notes or special instructions for the course About"
" Page."
......
......@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-10-21 07:12+0000\n"
"POT-Creation-Date: 2016-10-23 15:52+0000\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"
......
......@@ -10,33 +10,27 @@ $(function () {
change_fields;
show_verified_fields= function () {
$('.field-price').show();
$('.field-upgrade_deadline').show();
$('#id_price').prop("readonly", false);
};
hide_verified_fields = function () {
$('.field-price').hide();
$('.field-upgrade_deadline').hide();
$('#id_price').prop("readonly", true).val('0.00');
};
show_professional_fields = function () {
$('.field-price').show();
$('#id_price').prop("readonly", false);
};
hide_professional_fields = function () {
$('.field-price').hide();
$('#id_price').prop("readonly", true).val('0.00');
};
show_credit_fields = function () {
show_verified_fields();
$('.field-credit_provider').show();
$('.field-credit_hours').show();
};
hide_credit_fields = function () {
hide_verified_fields();
$('.field-credit_provider').hide();
$('.field-credit_hours').hide();
};
hide_all_fields = function () {
......@@ -70,7 +64,7 @@ $(function () {
change_fields();
$('.field-type .input-select').change(function () {
$('#id_type').change(function () {
change_fields(this);
});
});
......@@ -4,12 +4,12 @@ function addDatePicker() {
if (el.getAttribute('datepicker-initialized') !== 'true') {
new Pikaday({
field: el,
format: 'YYYY-MM-DD hh:mm:ss',
format: 'YYYY-MM-DD',
defaultDate: $(el).val(),
setDefaultDate: true,
showTime: true,
showTime: false,
use24hour: false,
autoClose: false
autoClose: true
});
el.setAttribute('datepicker-initialized', 'true');
}
......
......@@ -4,10 +4,6 @@
{% block title %}
{% trans "Course Form" %}
{% endblock title %}
{% block extra_js %}
<script src="{% static 'js/publisher/publisher.js' %}"></script>
{% endblock %}
{% block content %}
<div>
......@@ -268,11 +264,11 @@
{% trans "Some instructions here???" %}
</div>
<div class="col col-6">
<label class="field-label ">{{ run_form.keywords.label_tag }}</label>
{{ run_form.keywords}}
<label class="field-label ">{{ course_form.keywords.label_tag }}</label>
{{ course_form.keywords}}
<label class="field-label ">{{ run_form.is_seo_review.label_tag }}</label>
{{ run_form.is_seo_review}}
<label class="field-label ">{{ course_form.is_seo_review.label_tag }}</label>
{{ course_form.is_seo_review}}
</div>
</div>
......@@ -451,3 +447,8 @@
</div>
{% endblock content %}
{% block extra_js %}
<script src="{% static 'js/publisher/publisher.js' %}"></script>
<script src="{% static 'js/seat-type-change.js' %}"></script>
{% endblock %}
......@@ -137,7 +137,7 @@
{% trans "Keywords" %}
{% include "publisher/course_run_detail/clipboard.html" %}
</div>
<div class="copy">{{ object.wrapped_obj.keywords }}</div>
<div class="copy">{{ object.keywords }}</div>
</div>
<div class="info-item">
<div class="heading">
......
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