mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 11:44:58 +08:00
Merge pull request #6159 from connorsmallman/Bug/6142/LayoutEditorJS
Wait for document ready before calling LayoutEditor constructor
This commit is contained in:
@@ -39,12 +39,12 @@
|
||||
return "@Url.Action("Get", "Template", new { area = "Orchard.Layouts" })" + "/" + templateName;
|
||||
}
|
||||
});
|
||||
(function () {
|
||||
jQuery(function () {
|
||||
var editorConfig = JSON.parse(LayoutEditor.decode("@Html.Raw(Url.Encode(Model.ConfigurationData))"));
|
||||
var editorCanvasData = JSON.parse(LayoutEditor.decode("@Html.Raw(Url.Encode(Model.Data))"));
|
||||
|
||||
window.layoutEditor = new LayoutEditor.Editor(editorConfig, editorCanvasData);
|
||||
})(jQuery);
|
||||
});
|
||||
</script>
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user