timepicker now closes without exiting edit/view mode, close order: modal, timepicker, view

This commit is contained in:
Patrick O'Carroll 2018-03-29 15:02:00 +02:00
parent 8195c085fa
commit 9ef5f2700d

View File

@ -74,13 +74,13 @@ export class KeybindingSrv {
appEvents.emit('hide-modal');
if (this.timepickerOpen === true) {
this.$rootScope.appEvent('closeTimepicker');
this.timepickerOpen = false;
}
if (!this.modalOpen) {
this.$rootScope.appEvent('panel-change-view', { fullscreen: false, edit: false });
if (this.timepickerOpen) {
this.$rootScope.appEvent('closeTimepicker');
this.timepickerOpen = false;
} else {
this.$rootScope.appEvent('panel-change-view', { fullscreen: false, edit: false });
}
} else {
this.modalOpen = false;
}