All create/edit forms now allow staying on the page after save.

This commit is contained in:
Tomas Bures 2019-02-24 11:10:23 +00:00
parent d54f941caa
commit 4a6aed4cf7
31 changed files with 1118 additions and 1454 deletions

View file

@ -250,7 +250,7 @@ class RouteContent extends Component {
componentDidUpdate(prevProps) {
this.registerSidebarAnimationListener();
if (this.props.match.params !== prevProps.match.params && needsResolve(prevProps.route, this.props.route, prevProps.match, this.props.match)) {
if (this.props.location.state !== prevProps.location.state || (this.props.match.params !== prevProps.match.params && needsResolve(prevProps.route, this.props.route, prevProps.match, this.props.match))) {
// noinspection JSIgnoredPromiseFromCall
this.resolve();
}
@ -332,7 +332,7 @@ class RouteContent extends Component {
} else {
content = (
<div className="container-fluid">
<div className="container-fluid my-3">
{t('loading')}
</div>
);