Commit Graph

32 Commits

Author SHA1 Message Date
Calen Pennington
cfae1cdf62 Pep8 autofixes 2013-02-06 11:13:50 -05:00
Bridger Maxwell
adbe71b5df Got simplewiki just cleaned up enough to work again, so I could view a page for reference. 2012-08-19 19:57:19 -04:00
Victor Shnayder
c4afddfd38 Fix staff access check in simplewiki 2012-08-15 12:56:01 -04:00
Victor Shnayder
9425bbba60 Address other comment on #413
- don't call has_access directly from template, pass a staff_access variable instead
2012-08-15 10:28:08 -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
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
Bridger Maxwell
14a35b9605 Upgrading to django 1.4. 2012-08-08 11:57:15 -04:00
Calen Pennington
1d1a9173a4 Cleaning up pep8 violations 2012-07-23 14:44:40 -04:00
Bridger Maxwell
9fd99016a9 Removed duplicate index on simplewiki_namespace. Re-added migration that was exposing South 0.7.4 bug. 2012-07-19 11:12:10 -04:00
Bridger Maxwell
58348a98da Revert "Kill simplewiki migration (there was already a unique index, adding another causes errors)"
This reverts commit 7273868eb2.
2012-07-19 11:00:39 -04:00
David Ormsbee
7273868eb2 Kill simplewiki migration (there was already a unique index, adding another causes errors) 2012-07-18 17:15:51 -04:00
Bridger Maxwell
938f0d1995 Changed check_course from a decorator to a regular function that throws exceptions. Much easier to understand now. 2012-07-17 11:12:42 -04:00
Bridger Maxwell
f9de962365 Merge remote-tracking branch 'origin/master' into course_start 2012-07-13 13:40:01 -04:00
Bridger Maxwell
ecc50314f7 Added a decorator that prevents access to course pages until the course has started. 2012-07-13 10:31:36 -04:00
Bridger Maxwell
d5a5fcec4d Fixed the errors that were breaking tests from unused simplewiki files and a half-migrated certificates module. 2012-07-12 16:43:48 -04:00
Bridger Maxwell
08f5fe7fc9 Fixed wiki urls for new course ids. 2012-07-09 15:53:50 -04:00
Bridger Maxwell
291ec2cfc6 Allowing dots in wiki namespaces. 2012-07-06 17:49:26 -04:00
Bridger Maxwell
4d349fbd9d Fixed wiki error page again. 2012-07-06 17:42:01 -04:00
Bridger Maxwell
c0bba714a7 Added a migration to unique article slugs. 2012-07-06 16:17:15 -04:00
Bridger Maxwell
5489819fc7 Started writing slug uniquifying data migration. Doesn't work yet. 2012-07-06 16:10:12 -04:00
Bridger Maxwell
6d7b477982 Fixed wiki revision feed. 2012-07-06 12:55:05 -04:00
Bridger Maxwell
ac0a776818 First pass at getting both independent and in-course wiki viewing. 2012-07-05 21:20:35 -04:00
Bridger Maxwell
953cab047a Added check that namespace for a new course is created. 2012-07-05 08:55:35 -07:00
Bridger Maxwell
6f250fc0d3 Added unique and index on namespace model. 2012-07-05 08:55:03 -07:00
Bridger Maxwell
072de594ff Fixed wiki error pages a bit. 2012-07-05 08:14:41 -07:00
Bridger Maxwell
c6d973bda9 Fixed the markdown extensions to work with wiki namespaces. 2012-07-03 12:40:39 -07:00
Bridger Maxwell
064274a756 Most of the wiki pages are now loading without errors. 2012-07-03 09:50:58 -07:00
Bridger Maxwell
baa2c06803 Got history and view revision working on wiki. 2012-06-29 20:53:36 -04:00
Bridger Maxwell
b69deb698d Got the view page of the wiki rendering. Most of it is a styling mess. 2012-06-29 12:05:55 -04:00
Bridger Maxwell
8002644436 Added migrations for simplewiki. It is a tricky one to apply. Don't attempt at home. 2012-06-28 15:58:11 -04:00
Bridger Maxwell
2a9a15ad66 Beginning to port wiki to multicourse. (Unstable) 2012-06-28 15:11:00 -04:00
Calen Pennington
5ba03130aa Moving LMS code into subdirectory 2012-06-06 14:09:01 -04:00