Chris Dodge
46870f4391
be sure to always pass in a course namespace - which can be just the location of the module itself since it has the same org/course pair - when rewriting links. Also, allow for an option parameter in get_module() to disable the wrapping of the module's HTML with the xmodule_display.html. This is needed for ancillary course content such as 'about', 'course info', which are now stored as xmodules, but should not be wrapped in xmodule_display.html as it breaks some styling
2012-11-29 15:09:28 -05:00
Chris Dodge
b788b9d659
add to existing test cases to exercise the 'course extras as modules' work in the CMS import. Also add to the existing 'full' test data collection to include policy, tabs, etc.
2012-11-01 15:08:26 -04:00
Chris Dodge
34c442a1dc
removed unneeded trace log. Also don't need StudentModuleCache in 'about' section rendering
2012-10-30 16:04:51 -04:00
Chris Dodge
f0b4371c90
addressed Cale's feedback
2012-10-30 16:01:28 -04:00
Chris Dodge
ee1098c032
remove unused line
2012-10-30 15:37:40 -04:00
Chris Dodge
743f2b56dd
make course about view methods render the about content as a module, so we get all the url rewriting goodness. Also, since we're now handling the url re-writing via the module get_html pipelines, we can remove the link rewriting inside the xmodules itself - which is good because there's a wierd bug in lxml.html rewriting
2012-10-30 15:12:13 -04:00
Chris Dodge
f4822c23de
lots of tweeks to better support importing of existing courseware
2012-10-30 11:52:31 -04:00
Chris Dodge
ba15735214
implement static tabs. rejigger .tar.gz import to do the re-namespacing as a post-processing step as we need to retain the original url_name during the import. Also, migrate the presentation tier to use module_render.py::get_module() to better unify HTML'ifying stuff
2012-10-25 14:27:26 -04:00
Chris Dodge
fec6c42adc
implement importing of course info sections as modules in the course
2012-10-24 20:55:04 -04:00
Arjun Singh
08464725c3
Try and find a run-specific syllabus before loading a course-specific syllabus
2012-09-15 05:02:28 -07:00
Victor Shnayder
66343884dc
pull ocw links from about/ocw_links.html
...
format should be
<ul>
<li>link</li>
<li>other link</li>
</ul>
2012-09-13 10:22:02 -04:00
Victor Shnayder
f44898677a
Allow course info and course about pages to vary per-run
...
* looks in about/{course.url_name}/ first, then in about/
* same for info/
2012-09-06 11:17:55 -04:00
kimth
115eebdb76
Use reverse for course_info url replacement
2012-08-24 16:47:50 -04:00
kimth
31216ccd9f
Do URL replacement in course info page
2012-08-24 16:16:26 -04:00
Calen Pennington
82bab71ccf
First pass at branding the header logo on subdomains
2012-08-22 14:05:19 -04:00
Victor Shnayder
2c19d01441
Merge pull request #479 from MITx/feature/arjun/syllabus
...
Adding a syllabus page (accessible via course navigation)
2012-08-21 14:33:07 -07:00
Arjun Singh
b86fbdbd10
Adding comments about removing the syllabus tab ASAP.
2012-08-21 13:23:00 -07:00
Victor Shnayder
b97a2af2a2
Show policy, grading policy, and top-level errors
...
* Save errors for courses that failed to load in modulestore
* global staff can see course errors on their dashboard
* put policy loading errors into the error trackers
* add has_access(user, 'global', 'staff'), which is equiv to user.is_staff for now
2012-08-21 15:00:21 -04:00
Arjun Singh
1cfed46d06
Adding a syllabus page (accessible via course navigation)
2012-08-21 05:47:26 -07:00
Victor Shnayder
c6c95c63ac
Keep each course's descriptors separate
...
* apply policy per-course, even if multiple courses share course and org fields
* keep descriptors separate in xml store, so that if two such courses
change the same module in different ways, it works. Such edits will need to
merged on CMS import...
* add get_instance(course_id, location) method to replace get_item(location).
Update all the call sites
* tests, including a 2nd toy course with same course and org.
2012-08-20 09:26:16 -04:00
David Ormsbee
1c2b6e8088
Remove stuff that I should have deleted during the rebase
2012-08-15 14:39:56 -04:00
David Ormsbee
7d90617c5e
Merge with master
2012-08-15 12:21:59 -04:00
David Ormsbee
7f8f702971
Fix silly error that was pulling the wrong info from COURSE_LISTINGS
2012-08-15 11:53:21 -04:00
David Ormsbee
d0f2641890
Account for the fact that sometimes we don't get HTTP_HOST (like for tests)
2012-08-15 11:53:21 -04:00
David Ormsbee
346d5b91a1
implement subdomain-based course displays
2012-08-15 11:53:20 -04:00
Victor Shnayder
2df3a6ef11
Big access control refactor
...
* All access control logic is now in access.py
* It exports a single method for general use: has_access(user, object, action)
- possible actions depend on object type (e.g. 'see_exists', 'enroll', 'staff')
* Removed DARK_LAUNCH feature flag--it is now the default behavior
* Replaced check_course with three separate more focused functions that use has_access
Minor things:
* note on using pdb in testing
* moved time parsing helper into timeparse.py
* x_modules now have a .start attribute (None if not in metadata)
2012-08-14 23:30:37 -04:00
Calen Pennington
a984fbb65f
Merge pull request #394 from MITx/feature/victor/hide-error-modules
...
Hide errors from non-staff users
2012-08-13 06:17:13 -07:00
Victor Shnayder
3455f8f64d
Hide errors from non-staff users
2012-08-12 18:03:12 -04:00
Victor Shnayder
d7f94a05b7
Add DARK_LAUNCH functionality
...
* pass user to check_course
* if dark launch feature enabled, users with staff access to course
can see courseware before start date. Students still can't.
* tests.
* Remaining: enrollment view has custom access control. Need to check it.
2012-08-12 16:23:31 -04:00
Victor Shnayder
622eebc473
Don't error on missing static files
...
* Just log a warning and return a dummy url
* May want smarter checking later
(e.g. would be nice to tell staff what files are missing.)
2012-08-12 16:21:38 -04:00
Victor Shnayder
c9fd7b22a0
Add instructor dashboard
...
* dashboard links to gradebook and dummy grade summary page
2012-08-10 11:42:53 -04:00
Victor Shnayder
2005492f7f
Remove noisy debug message
...
* also adds a comment to lms/urls.py
2012-08-10 11:41:05 -04:00
David Ormsbee
f4138cae70
re-enable ENABLE_LMS_MIGRATION in dev, fix the course check filter to use ACCESS_REQUIRE_STAFF_FOR_COURSE
2012-08-07 15:01:12 -04:00
Victor Shnayder
932a9be747
Make tests pass again
...
* test enrolls in course before testing pages
* support github edit links with new file structure
* Some pep8 cleanups
2012-08-07 11:06:47 -04:00
ichuang
3484f5382c
isinstance instead of type
2012-08-06 14:10:00 -04:00
ichuang
7607444286
fix bug: course staff group based on dir_name, not course number
2012-08-05 23:26:31 -04:00
ichuang
7fe75030cc
fix staff edit link in module content display (goes to github)
2012-08-04 17:52:14 -04:00
ichuang
b8ae026c29
fail gracefully if course.xml missing metadata in course_staff_group_name
2012-08-04 11:16:47 -04:00
ichuang
d50af5765e
make university profile pages also use get_courses_by_university
2012-08-04 11:03:54 -04:00
ichuang
3f83904c12
if AUTH_REQUIRE_STAFF_FOR_COURSE then course list = those accessible
2012-08-04 10:19:54 -04:00
ichuang
30922fb449
add ACCESS_REQUIRE_STAFF_FOR_COURSE feature for enrollment check
2012-08-03 21:39:23 -04:00
Victor Shnayder
b46172da9b
Rename module.name and descriptor.name to url_name
...
* update templates and code references
* also a display_name property that defaults to cleaned url_name
2012-08-03 11:36:54 -04:00
Victor Shnayder
32253510d1
Import error cleanup
...
* call error tracker when needed
* remove duplicate logging--just add info and re-raise
* xml modulestore uses error tracker to capture load errors
* add unstyled list of import errors to courseware homepage!
2012-08-01 11:48:19 -04:00
Calen Pennington
98910a2d49
Address review comments
2012-07-24 14:46:46 -04:00
Calen Pennington
66f79251dc
Add feature flag for disabling course start dates
2012-07-24 13:22:50 -04:00
Calen Pennington
d8f8d8c656
Merge branch 'release/1.0'
...
Conflicts:
common/djangoapps/student/views.py
lms/djangoapps/courseware/courses.py
2012-07-24 08:52:50 -04:00
Calen Pennington
b8b133d30c
Replace /static urls in all course snippets
2012-07-23 16:31:52 -04:00
Calen Pennington
4984f9d804
Use django-pipeline to read course static files.
...
Requires the replacement of {COURSE_STATIC_URL} with just /static/
in about/overview.html files.
2012-07-23 16:22:45 -04:00
Calen Pennington
1d1a9173a4
Cleaning up pep8 violations
2012-07-23 14:44:40 -04:00
David Ormsbee
80c04e1414
Use JPGs instead of PNG for course images
2012-07-23 14:16:54 -04:00