mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 19:54:57 +08:00
Bugfixing.
The "showSaveMsg" function needs to be there regardless of the "promptOnNavigate" value.
This commit is contained in:
@@ -32,12 +32,14 @@
|
||||
}
|
||||
};
|
||||
|
||||
if (promptOnNavigate) {
|
||||
window.mediaLibraryDirty = false;
|
||||
var showSaveMsg = function() {
|
||||
element.find('.media-library-picker-message').show();
|
||||
window.mediaLibraryDirty = true;
|
||||
};
|
||||
var showSaveMsg = function () {
|
||||
element.find('.media-library-picker-message').show();
|
||||
window.mediaLibraryDirty = true;
|
||||
};
|
||||
|
||||
window.mediaLibraryDirty = false;
|
||||
|
||||
if (promptOnNavigate) {
|
||||
if (!window.mediaLibraryNavigateAway) {
|
||||
$(window).on("beforeunload", window.mediaLibraryNavigateAway = function() {
|
||||
if (window.mediaLibraryDirty) {
|
||||
|
Reference in New Issue
Block a user