mirror of
https://github.com/wassname/talk.git
synced 2026-08-06 13:41:02 +08:00
Readd save dialog on section change
This commit is contained in:
@@ -49,7 +49,13 @@ class ConfigureContainer extends React.Component {
|
||||
|
||||
handleSectionChange = async section => {
|
||||
const nextRoute = `/admin/configure/${section}`;
|
||||
this.props.router.push(nextRoute);
|
||||
if (this.hasPendingData()) {
|
||||
this.nextRoute = nextRoute;
|
||||
this.props.showSaveDialog();
|
||||
} else {
|
||||
// Just go to the section
|
||||
this.props.router.push(nextRoute);
|
||||
}
|
||||
};
|
||||
|
||||
navigationPrompt = e => {
|
||||
|
||||
Reference in New Issue
Block a user