Mercurial > lada > lada-client
diff app/controller/form/Messung.js @ 639:fdaabab6f4cc
Open Probe-/Messung-Edit window automatically if a new item was saved
successfully.
author | Raimund Renkert <raimund.renkert@intevation.de> |
---|---|
date | Tue, 17 Mar 2015 14:44:52 +0100 |
parents | ee92e352be20 |
children | 71e8b84d7829 |
line wrap: on
line diff
--- a/app/controller/form/Messung.js Tue Mar 17 14:33:13 2015 +0100 +++ b/app/controller/form/Messung.js Tue Mar 17 14:44:52 2015 +0100 @@ -39,6 +39,14 @@ formPanel.clearMessages(); formPanel.setRecord(record); formPanel.setMessages(json.errors, json.warnings); + if (response.action === 'create' && json.success) { + button.up('window').close(); + var win = Ext.create('Lada.view.window.MessungEdit', { + record: record + }); + win.show(); + win.initData(); + } } }, failure: function(record, response) {