Commit 535e6e4f by Anton Stupak

Merge pull request #4983 from lduarte1991/lduarte-harvardx-pr20

Annotation Tools: Turn off Private/Public option and add missing css group to MyNotes
parents 51b680af 32040164
......@@ -1123,11 +1123,10 @@ CatchAnnotation.prototype = {
// checks to make sure that Grouping is redone when switching tags in text annotations
if (this.options.media === 'text') {
if (this.current_tab ==='public') {
this.annotator.plugins.Grouping.useGrouping = 0;
} else {
this.annotator.plugins.Grouping.useGrouping = 1;
}
if (typeof this.annotator.plugins.Grouping !== 'undefined') {
// this is to check if user is is MyNotes instead of the annotation component
this.annotator.plugins.Grouping.useGrouping = this.current_tab === 'public' ? 0 : 1;
}
this.annotator.publish("changedTabsInCatch");
}
// Change userid and refresh
......@@ -1156,7 +1155,11 @@ CatchAnnotation.prototype = {
var searchtype = searchtype || "";
var searchInput = searchInput || "";
this.clean = true;
this._clearAnnotator();
// the following cannot run in notes for there are no highlights
if ($("#notesHolder").length === 0) {
this._clearAnnotator();
}
var annotator = this.annotator;
var loadFromSearch = annotator.plugins.Store.options.loadFromSearch;
......
......@@ -96,7 +96,7 @@
'delete': ["${user.email}"],
'admin': ["${user.email}"]
},
showViewPermissionsCheckbox: true,
showViewPermissionsCheckbox: false,
showEditPermissionsCheckbox: false,
userAuthorize: function(action, annotation, user) {
var token, tokens, _i, _len;
......
......@@ -3,6 +3,7 @@
<%namespace name='static' file='static_content.html'/>
${static.css(group='style-vendor-tinymce-content', raw=True)}
${static.css(group='style-vendor-tinymce-skin', raw=True)}
${static.css(group='style-xmodule-annotations', raw=True)}
<script type="text/javascript" src="${static.url('js/vendor/tinymce/js/tinymce/tinymce.full.min.js', raw=True)}"></script>
<script type="text/javascript" src="${static.url('js/vendor/tinymce/js/tinymce/jquery.tinymce.min.js', raw=True)}" ></script>
<%inherit file="main.html" />
......
......@@ -85,7 +85,7 @@ ${static.css(group='style-xmodule-annotations', raw=True)}
'delete': ["${user.email}"],
'admin': ["${user.email}"]
},
showViewPermissionsCheckbox: true,
showViewPermissionsCheckbox: false,
showEditPermissionsCheckbox: false,
userAuthorize: function(action, annotation, user) {
var token, tokens, _i, _len;
......
......@@ -88,7 +88,7 @@ ${static.css(group='style-xmodule-annotations', raw=True)}
'delete': ["${user.email}"],
'admin': ["${user.email}"]
},
showViewPermissionsCheckbox: true,
showViewPermissionsCheckbox: false,
showEditPermissionsCheckbox: false,
userAuthorize: function(action, annotation, user) {
var token, tokens, _i, _len;
......
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