mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-12-17 22:28:38 +08:00
Add error handling for MarvinJS
This commit is contained in:
parent
feda5622d8
commit
d719c26b6c
2 changed files with 10 additions and 1 deletions
|
|
@ -168,6 +168,10 @@ var MarvinJsEditorApi = (function() {
|
||||||
$(marvinJsModal).modal('hide');
|
$(marvinJsModal).modal('hide');
|
||||||
FilePreviewModal.init();
|
FilePreviewModal.init();
|
||||||
config.button.dataset.inProgress = false;
|
config.button.dataset.inProgress = false;
|
||||||
|
}).error((response) => {
|
||||||
|
if (response.status === 403) {
|
||||||
|
HelperModule.flashAlertMsg(I18n.t('general.no_permissions'), 'danger');
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -196,6 +200,11 @@ var MarvinJsEditorApi = (function() {
|
||||||
}
|
}
|
||||||
$(marvinJsModal).modal('hide');
|
$(marvinJsModal).modal('hide');
|
||||||
config.button.dataset.inProgress = false;
|
config.button.dataset.inProgress = false;
|
||||||
|
},
|
||||||
|
error: function(response) {
|
||||||
|
if (response.status === 403) {
|
||||||
|
HelperModule.flashAlertMsg(I18n.t('general.no_permissions'), 'danger');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -47,7 +47,7 @@
|
||||||
|
|
||||||
.atwho-no-results {
|
.atwho-no-results {
|
||||||
color: $color-silver-chalice;
|
color: $color-silver-chalice;
|
||||||
padding: 1.5em 7em;
|
padding: 1.5em 4em;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
|
||||||
.description {
|
.description {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue