Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -100,3 +100,4 @@ Manuel Freire <manuel.freire@fdi.ucm.es>
Daniel Cebrián Robles <danielcebrianr@gmail.com>
Carson Gee <cgee@mit.edu>
Gang Chen <goncha@gmail.com>
Cristian Salamea <cristian.salamea@iaen.edu.ec>
19 changes: 10 additions & 9 deletions common/djangoapps/student/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
import django.dispatch
from django.forms import ModelForm, forms
from django.core.exceptions import ObjectDoesNotExist
from django.utils.translation import ugettext as _

from course_modes.models import CourseMode
import lms.lib.comment_client as cc
Expand Down Expand Up @@ -196,15 +197,15 @@ class Meta:
# ('p_se', 'Doctorate in science or engineering'),
# ('p_oth', 'Doctorate in another field'),
LEVEL_OF_EDUCATION_CHOICES = (
('p', 'Doctorate'),
('m', "Master's or professional degree"),
('b', "Bachelor's degree"),
('a', "Associate's degree"),
('hs', "Secondary/high school"),
('jhs', "Junior secondary/junior high/middle school"),
('el', "Elementary/primary school"),
('none', "None"),
('other', "Other")
('p', _('Doctorate')),
('m', _("Master's or professional degree")),
('b', _("Bachelor's degree")),
('a', _("Associate's degree")),
('hs', _("Secondary/high school")),
('jhs', _("Junior secondary/junior high/middle school")),
('el', _("Elementary/primary school")),
('none', _("None")),
('other', _("Other"))
)
level_of_education = models.CharField(
blank=True, null=True, max_length=6, db_index=True,
Expand Down
124 changes: 63 additions & 61 deletions common/lib/xmodule/xmodule/course_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
import dateutil.parser
from lazy import lazy

from django.utils.translation import ugettext as _

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah shoot @singingwolfboy we missed this. You can't translate this file yet - we can't have django dependencies in xmodule.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried to run the CMS after doing the dummy translations and it broke. @ovnicraft try

rake i18n:extract; rake i18n:dummy; rake i18n:generate; rake cms

the rake cms call will give an error.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See my post here: https://groups.google.com/forum/#!topic/edx-code/nKHfn9e4Fc4 for the particular error.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sarina So course_module.py can be translated i change it this, but there is any way thought to solve this ?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right now we do not have a solid way of translating non-django components of edx-platform. When we do, we will document how it must be done.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok i will change it and push.


from xmodule.modulestore import Location
from xmodule.seq_module import SequenceDescriptor, SequenceModule
from xmodule.graders import grader_from_conf
Expand Down Expand Up @@ -227,132 +229,132 @@ class CourseFields(object):
has_children = True
checklists = List(scope=Scope.settings,
default=[
{"short_description": "Getting Started With Studio",
"items": [{"short_description": "Add Course Team Members",
"long_description": "Grant your collaborators permission to edit your course so you can work together.",
{"short_description": _("Getting Started With Studio"),
"items": [{"short_description": _("Add Course Team Members"),
"long_description": _("Grant your collaborators permission to edit your course so you can work together."),
"is_checked": False,
"action_url": "ManageUsers",
"action_text": "Edit Course Team",
"action_text": _("Edit Course Team"),
"action_external": False},
{"short_description": "Set Important Dates for Your Course",
"long_description": "Establish your course's student enrollment and launch dates on the Schedule and Details page.",
{"short_description": _("Set Important Dates for Your Course"),
"long_description": _("Establish your course's student enrollment and launch dates on the Schedule and Details page."),
"is_checked": False,
"action_url": "SettingsDetails",
"action_text": "Edit Course Details &amp; Schedule",
"action_text": _("Edit Course Details &amp; Schedule"),
"action_external": False},
{"short_description": "Draft Your Course's Grading Policy",
"long_description": "Set up your assignment types and grading policy even if you haven't created all your assignments.",
{"short_description": _("Draft Your Course's Grading Policy"),
"long_description": _("Set up your assignment types and grading policy even if you haven't created all your assignments."),
"is_checked": False,
"action_url": "SettingsGrading",
"action_text": "Edit Grading Settings",
"action_text": _("Edit Grading Settings"),
"action_external": False},
{"short_description": "Explore the Other Studio Checklists",
"long_description": "Discover other available course authoring tools, and find help when you need it.",
{"short_description": _("Explore the Other Studio Checklists"),
"long_description": _("Discover other available course authoring tools, and find help when you need it."),
"is_checked": False,
"action_url": "",
"action_text": "",
"action_external": False}]},
{"short_description": "Draft a Rough Course Outline",
"items": [{"short_description": "Create Your First Section and Subsection",
"long_description": "Use your course outline to build your first Section and Subsection.",
{"short_description": _("Draft a Rough Course Outline"),
"items": [{"short_description": _("Create Your First Section and Subsection"),
"long_description": _("Use your course outline to build your first Section and Subsection."),
"is_checked": False,
"action_url": "CourseOutline",
"action_text": "Edit Course Outline",
"action_text": _("Edit Course Outline"),
"action_external": False},
{"short_description": "Set Section Release Dates",
"long_description": "Specify the release dates for each Section in your course. Sections become visible to students on their release dates.",
{"short_description": _("Set Section Release Dates"),
"long_description": _("Specify the release dates for each Section in your course. Sections become visible to students on their release dates."),
"is_checked": False,
"action_url": "CourseOutline",
"action_text": "Edit Course Outline",
"action_text": _("Edit Course Outline"),
"action_external": False},
{"short_description": "Designate a Subsection as Graded",
"long_description": "Set a Subsection to be graded as a specific assignment type. Assignments within graded Subsections count toward a student's final grade.",
{"short_description": _("Designate a Subsection as Graded"),
"long_description": _("Set a Subsection to be graded as a specific assignment type. Assignments within graded Subsections count toward a student's final grade."),
"is_checked": False,
"action_url": "CourseOutline",
"action_text": "Edit Course Outline",
"action_text": _("Edit Course Outline"),
"action_external": False},
{"short_description": "Reordering Course Content",
"long_description": "Use drag and drop to reorder the content in your course.",
{"short_description": _("Reordering Course Content"),
"long_description": _("Use drag and drop to reorder the content in your course."),
"is_checked": False,
"action_url": "CourseOutline",
"action_text": "Edit Course Outline",
"action_text": _("Edit Course Outline"),
"action_external": False},
{"short_description": "Renaming Sections",
"long_description": "Rename Sections by clicking the Section name from the Course Outline.",
{"short_description": _("Renaming Sections"),
"long_description": _("Rename Sections by clicking the Section name from the Course Outline."),
"is_checked": False,
"action_url": "CourseOutline",
"action_text": "Edit Course Outline",
"action_text": _("Edit Course Outline"),
"action_external": False},
{"short_description": "Deleting Course Content",
"long_description": "Delete Sections, Subsections, or Units you don't need anymore. Be careful, as there is no Undo function.",
{"short_description": _("Deleting Course Content"),
"long_description": _("Delete Sections, Subsections, or Units you don't need anymore. Be careful, as there is no Undo function."),
"is_checked": False,
"action_url": "CourseOutline",
"action_text": "Edit Course Outline",
"action_text": _("Edit Course Outline"),
"action_external": False},
{"short_description": "Add an Instructor-Only Section to Your Outline",
"long_description": "Some course authors find using a section for unsorted, in-progress work useful. To do this, create a section and set the release date to the distant future.",
{"short_description": _("Add an Instructor-Only Section to Your Outline"),
"long_description": _("Some course authors find using a section for unsorted, in-progress work useful. To do this, create a section and set the release date to the distant future."),
"is_checked": False,
"action_url": "CourseOutline",
"action_text": "Edit Course Outline",
"action_text": _("Edit Course Outline"),
"action_external": False}]},
{"short_description": "Explore edX's Support Tools",
"items": [{"short_description": "Explore the Studio Help Forum",
"long_description": "Access the Studio Help forum from the menu that appears when you click your user name in the top right corner of Studio.",
{"short_description": _("Explore edX's Support Tools"),
"items": [{"short_description": _("Explore the Studio Help Forum"),
"long_description": _("Access the Studio Help forum from the menu that appears when you click your user name in the top right corner of Studio."),
"is_checked": False,
"action_url": "http://help.edge.edx.org/",
"action_text": "Visit Studio Help",
"action_text": _("Visit Studio Help"),
"action_external": True},
{"short_description": "Enroll in edX 101",
"long_description": "Register for edX 101, edX's primer for course creation.",
{"short_description": _("Enroll in edX 101"),
"long_description": _("Register for edX 101, edX's primer for course creation."),
"is_checked": False,
"action_url": "https://edge.edx.org/courses/edX/edX101/How_to_Create_an_edX_Course/about",
"action_text": "Register for edX 101",
"action_text": _("Register for edX 101"),
"action_external": True},
{"short_description": "Download the Studio Documentation",
"long_description": "Download the searchable Studio reference documentation in PDF form.",
{"short_description": _("Download the Studio Documentation"),
"long_description": _("Download the searchable Studio reference documentation in PDF form."),
"is_checked": False,
"action_url": "http://files.edx.org/Getting_Started_with_Studio.pdf",
"action_text": "Download Documentation",
"action_text": _("Download Documentation"),
"action_external": True}]},
{"short_description": "Draft Your Course About Page",
"items": [{"short_description": "Draft a Course Description",
"long_description": "Courses on edX have an About page that includes a course video, description, and more. Draft the text students will read before deciding to enroll in your course.",
{"short_description": _("Draft Your Course About Page"),
"items": [{"short_description": _("Draft a Course Description"),
"long_description": _("Courses on edX have an About page that includes a course video, description, and more. Draft the text students will read before deciding to enroll in your course."),
"is_checked": False,
"action_url": "SettingsDetails",
"action_text": "Edit Course Schedule &amp; Details",
"action_text": _("Edit Course Schedule &amp; Details"),
"action_external": False},
{"short_description": "Add Staff Bios",
"long_description": "Showing prospective students who their instructor will be is helpful. Include staff bios on the course About page.",
{"short_description": _("Add Staff Bios"),
"long_description": _("Showing prospective students who their instructor will be is helpful. Include staff bios on the course About page."),
"is_checked": False,
"action_url": "SettingsDetails",
"action_text": "Edit Course Schedule &amp; Details",
"action_text": _("Edit Course Schedule &amp; Details"),
"action_external": False},
{"short_description": "Add Course FAQs",
"long_description": "Include a short list of frequently asked questions about your course.",
{"short_description": _("Add Course FAQs"),
"long_description": _("Include a short list of frequently asked questions about your course."),
"is_checked": False,
"action_url": "SettingsDetails",
"action_text": "Edit Course Schedule &amp; Details",
"action_text": _("Edit Course Schedule &amp; Details"),
"action_external": False},
{"short_description": "Add Course Prerequisites",
"long_description": "Let students know what knowledge and/or skills they should have before they enroll in your course.",
{"short_description": _("Add Course Prerequisites"),
"long_description": _("Let students know what knowledge and/or skills they should have before they enroll in your course."),
"is_checked": False,
"action_url": "SettingsDetails",
"action_text": "Edit Course Schedule &amp; Details",
"action_text": _("Edit Course Schedule &amp; Details"),
"action_external": False}]}
])
info_sidebar_name = String(scope=Scope.settings, default='Course Handouts')
show_timezone = Boolean(
help="True if timezones should be shown on dates in the courseware. Deprecated in favor of due_date_display_format.",
help=_("True if timezones should be shown on dates in the courseware. Deprecated in favor of due_date_display_format."),
scope=Scope.settings, default=True
)
due_date_display_format = String(
help="Format supported by strftime for displaying due dates. Takes precedence over show_timezone.",
help=_("Format supported by strftime for displaying due dates. Takes precedence over show_timezone."),
scope=Scope.settings, default=None
)
enrollment_domain = String(help="External login method associated with user accounts allowed to register in course",
enrollment_domain = String(help=_("External login method associated with user accounts allowed to register in course"),
scope=Scope.settings)
course_image = String(
help="Filename of the course image",
help=_("Filename of the course image"),
scope=Scope.settings,
# Ensure that courses imported from XML keep their image
default="images_course_image.jpg"
Expand Down