mirror of
https://github.com/apache/superset.git
synced 2026-06-06 16:19:18 +00:00
Prevent the cannot-overwrite error message from being removed before it can be seen (#626)
This commit is contained in:
committed by
Maxime Beauchemin
parent
aa2b8b42d0
commit
ee2d3330aa
@@ -64,7 +64,9 @@ function query(force, pushState) {
|
||||
}
|
||||
$('.query-and-save button').attr('disabled', 'disabled');
|
||||
$('.btn-group.results span,a').attr('disabled', 'disabled');
|
||||
$('div.alert').remove();
|
||||
if (force) { // Don't hide the alert message when the page is just loaded
|
||||
$('div.alert').remove();
|
||||
}
|
||||
$('#is_cached').hide();
|
||||
prepForm();
|
||||
slice.render(force);
|
||||
|
||||
@@ -842,7 +842,7 @@ class Caravel(BaseView):
|
||||
def overwrite_slice(self, slc):
|
||||
can_update = check_ownership(slc, raise_if_false=False)
|
||||
if not can_update:
|
||||
flash("You cannot overwrite [{}]".format(slc))
|
||||
flash("You cannot overwrite [{}]".format(slc), "danger")
|
||||
else:
|
||||
session = db.session()
|
||||
session.merge(slc)
|
||||
|
||||
Reference in New Issue
Block a user