mirror of
https://github.com/apache/superset.git
synced 2026-04-21 17:14:57 +00:00
[dashboard] give user feedback when there are unsaved changes (#1633)
* show alert and use dialog window if there are unsaved changes. * add container class to alert
This commit is contained in:
@@ -48,10 +48,12 @@ class GridLayout extends React.Component {
|
||||
if (oldItem.w !== newItem.w || oldItem.h !== newItem.h) {
|
||||
this.setState({ layout }, () => newSlice.resize());
|
||||
}
|
||||
this.props.dashboard.onChange();
|
||||
}
|
||||
|
||||
onDragStop(layout) {
|
||||
this.setState({ layout });
|
||||
this.props.dashboard.onChange();
|
||||
}
|
||||
|
||||
removeSlice(sliceId) {
|
||||
@@ -64,6 +66,7 @@ class GridLayout extends React.Component {
|
||||
return slice.slice_id !== sliceId;
|
||||
}),
|
||||
});
|
||||
this.props.dashboard.onChange();
|
||||
}
|
||||
|
||||
serialize() {
|
||||
|
||||
Reference in New Issue
Block a user