Fix galaxy page editor creation; onloads.

This commit is contained in:
Dannon Baker
2017-10-31 14:50:43 -04:00
parent 2562e73715
commit 8eee8dadf5
4 changed files with 15 additions and 11 deletions
+2 -2
View File
@@ -553,7 +553,7 @@ WYMeditor.editor.prototype.dialog = function(
}
};
$(function() {
export default function editor_onload() {
// Generic error handling
$(document).ajaxError(function(e, x) {
// console.log( e, x );
@@ -746,4 +746,4 @@ $(function() {
// editor.dialog(CONTROLS.DIALOG_EMBED_PAGE);
//}
});
});
}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+11 -7
View File
@@ -11,6 +11,12 @@
<%def name="javascripts()">
${parent.javascripts()}
${h.js(
"libs/jquery/jquery.form",
"libs/jquery/jstorage",
"libs/jquery/jquery.wymeditor",
"libs/jquery/jquery.autocomplete",
)}
<script type="text/javascript">
// Define variables needed by galaxy.pages script.
var page_id = "${trans.security.encode_id(page.id)}",
@@ -21,14 +27,12 @@
editor_base_path = "${h.url_for('/static/wymeditor')}/",
iframe_base_path = "${h.url_for('/static/wymeditor/iframe/galaxy')}/",
save_url = "${h.url_for(controller='page', action='save' )}";
require(['galaxy.pages'], function(Pages){
Pages.default();
});
</script>
${h.js(
"libs/jquery/jquery.form",
"libs/jquery/jstorage",
"libs/jquery/jquery.wymeditor",
"libs/jquery/jquery.autocomplete",
"galaxy.pages"
)}
</%def>
<%def name="stylesheets()">