[Edit] CreateAction closes editor after save

This commit is contained in:
Alex M
2016-09-13 23:59:28 +03:00
parent d87ed1414e
commit 0be84a4e51
3 changed files with 10 additions and 4 deletions

View File

@@ -67,12 +67,17 @@ define(
editAction,
editorCapability;
function closeEditor() {
return editorCapability.finish();
}
function onSave() {
return editorCapability.save();
return editorCapability.save()
.then(closeEditor);
}
function onCancel() {
return editorCapability.finish();
return closeEditor();
}
newModel.type = this.type.getKey();