Commit Graph

93 Commits

Author SHA1 Message Date
Calen Pennington
d7cbd1c814 Don't do extra json conversion/de-conversion for data/children going to the cms 2012-09-18 15:07:35 -04:00
Calen Pennington
bb06a926bb Make saving also save the children in the #sortable element (TODO: name the #sortable element better) 2012-09-18 13:19:30 -04:00
Calen Pennington
d17e2aada9 Remove trailing '/' from ajax_urls 2012-09-17 14:19:07 -04:00
Kyle Fiedler
7a248f0154 Added fixes to some style and one Cale fix to get things working properly 2012-09-11 14:05:07 -04:00
Calen Pennington
7702907662 Make module system handle not having a user, and pass a user in when previewing in the cms 2012-09-05 13:29:30 -04:00
Victor Shnayder
f81f94ec67 Allow location url_names to contain ':', mapping to / on file load
* New format: {tag}://{org}/{course}/{category}/{name}[@{revision}]
* Updated tests, code
* Added test chapter with : in url_name in toy course
* added test html page with : in url_name
* added a note to docs
2012-08-27 11:37:22 -04:00
Victor Shnayder
e4fb9ec63a Remove is_staff from ModuleSystem
- now handling access control via get_module
2012-08-14 23:30:37 -04:00
ichuang
4240830e68 cms also needs replace_static_urls call fixed 2012-08-10 15:25:41 -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
3b6f33f5a7 Fix github_sync tests
* CMS no longer syncs, it just imports when it gets a commit note
  from github
2012-08-02 14:26:24 -04:00
Calen Pennington
477b7062d4 Merge pull request #335 from MITx/feature/cale/cms-no-roundtrip
Only import from github when changes are made, rather than exporting. Th...
2012-08-02 10:39:01 -07:00
Calen Pennington
052ae88111 Only import from github when changes are made, rather than exporting. This prevents bugs in the cms from preventing changes via git 2012-08-02 09:19:25 -04:00
Victor Shnayder
2f4bf5f606 Minor fixes to cms
* make logging work properly in cms, dev
* fix a comment
2012-08-01 19:25:47 -04:00
Victor Shnayder
119ab639d0 make cms users look like staff by default
* so they get the staff view of problems
* does NOT actually set User.is_staff
2012-08-01 11:48:18 -04:00
Victor Shnayder
c0cdff7071 Rename MalformedDescriptor to ErrorDescriptor
* change references and tests
* add staff/non-staff display
* added is_staff to ModuleSystem
2012-08-01 11:42:39 -04:00
Victor Shnayder
10054e95ce add message to import command 2012-08-01 11:40:11 -04:00
Calen Pennington
2f95a8e1d0 Re-add __init__.py for contentstore that was accidentally deleted in 05add5818b 2012-07-31 09:29:14 -04:00
Calen Pennington
89b5f5b2be Minor review notes 2012-07-30 16:11:35 -04:00
Calen Pennington
7ae0836f77 Add some more tests of github_sync 2012-07-30 13:50:50 -04:00
Calen Pennington
05add5818b Return a custom error for duplicate elements, and ignore it when loading into mongo 2012-07-30 13:16:21 -04:00
Calen Pennington
6bd9cd6c28 Add management command for syncing with github 2012-07-30 12:59:28 -04:00
Calen Pennington
39e5a7762e Make github_sync use a namedtuple for repo settings 2012-07-30 12:59:28 -04:00
Victor Shnayder
3c3bbd114e minor formatting tweaks 2012-07-27 16:08:24 -04:00
Victor Shnayder
60cba3d95f Move import_from_xml to xmodule/modulestore 2012-07-27 16:08:23 -04:00
Victor Shnayder
e5117dba13 Mostly fix tests.
* change custom tags in test/data/full to new single-tag format
* fix broken file references
* fix argument to import_from_xml
* error_handler fix in mongo.py in next commit
2012-07-27 16:08:23 -04:00
Calen Pennington
29cf09763f Fixing up cms tests to only use data in common/test/data 2012-07-25 10:09:25 -04:00
Calen Pennington
0a79130b11 Make problem previews work by saving problem state in the current request session 2012-07-24 16:14:04 -04:00
Calen Pennington
408726e678 Standardize how JS XModules are instantiated 2012-07-24 16:14:04 -04:00
Calen Pennington
19a3c14ab9 Split out code to replace /static urls in get_html into a separate module so that it can be used in CMS previews 2012-07-24 16:14:01 -04:00
Calen Pennington
3cdceab16c Uniquify js fragments pulled from XModules, and load both XModuleDescriptor and XModule js into the cms 2012-07-24 16:13:59 -04:00
Calen Pennington
3fa636e060 Move module javascript into common/lib/xmodule. Still TODO: run jasmine tests in that directory 2012-07-24 16:13:59 -04:00
Calen Pennington
9458e53988 Adding stripped down 6002x course for testing, along with CMS test for edit pages for same 2012-07-24 16:13:51 -04:00
Calen Pennington
6bf0e093bc Add tests for the edit page for the toy course, and make sure that exporting to github sets up the git repo properly 2012-07-24 15:05:07 -04:00
Calen Pennington
39b59484a6 Re-add login requirement to save_item 2012-07-24 15:05:07 -04:00
Calen Pennington
6b28786784 Use the new name for item_id in contentstore.views.save_item 2012-07-24 15:05:07 -04:00
Calen Pennington
1aba46de55 Be consistent with the metadata key name for the data directory 2012-07-24 15:05:07 -04:00
Calen Pennington
15ac476781 Display preview html on the module edit page. Javascript for previews doesn't yet function 2012-07-24 15:05:07 -04:00
Calen Pennington
1d1a9173a4 Cleaning up pep8 violations 2012-07-23 14:44:40 -04:00
Calen Pennington
7a34a8c342 Fix failing tests 2012-07-23 13:49:11 -04:00
Victor Shnayder
f8ce11a6b5 Add fixes to notes in #182
* use 'location' instead of 'id' in views.
* still need to change names in the coffeescript--quick fix didn't work
2012-07-16 14:08:03 -04:00
Victor Shnayder
acd57fb7c5 Save author info in commit messages.
* add optional author_str param to export_to_github
* pass the django user info to that param
2012-07-16 13:34:04 -04:00
Victor Shnayder
942ea2c7ba fix typo 2012-07-16 13:34:04 -04:00
Victor Shnayder
3f356bfb1b Add basic framework for checking permissions
* add dummy has_access(user, location) method
* re-organize views by type of access checking needed.
2012-07-16 13:34:04 -04:00
Victor Shnayder
c176a7fe92 Add account creation and login to CMS
* connect up views from student app
* Add initial @login_required decorators on the protected views
* Add tests for some of the basic functionality
2012-07-16 13:34:04 -04:00
Victor Shnayder
339e9a68f4 Make end-to-end tests work again
* NOTE: successfully running the tests depends on an updated version of
  django-pipeline, which fixes a unicode bug (efaba4ac63)

Config changes:
* Use separate db for the cms
* Run collectstatic before running tests--needed to get everything in the right place for loading pages
* fix some paths related to this
* Turn off JS compressor for CMS
* add empty test_root/uploads dir

Code changes:
* Add cms tests to check that home page and signup pages load
* Add cms account creation test
* Make github sync tests clean out repo dirs before running.
2012-07-13 11:51:33 -04:00
Victor Shnayder
ff59c9bfa9 Initial connection of student module with cms.
* Enable account creation
* Some code cleanups
* Fix access to nonexistent fields in the account creation view
* Formatting fixes
2012-07-13 11:51:32 -04:00
ichuang
926fdd010e Merge pull request #173 from MITx/cpennington/pull-155-cleanup
This cleans up remaining issues w/ https://github.com/MITx/mitx/pull/155
2012-07-11 19:34:56 -07:00
Calen Pennington
0e05d092ca Remove temporary export url in favor of export round trip test 2012-07-11 22:18:40 -04:00
Calen Pennington
f8e9313dad Minimize the number of roundtrips to mongo during cms save by prefetching children 2012-07-11 16:22:24 -04:00
Calen Pennington
6dd141247d Fixing github_sync to work with multiple course data directories 2012-07-10 14:58:27 -04:00