changeset 1192:d57462b81444 schema-update

Set new field 'gemId' in messprogramm.
author Raimund Renkert <raimund.renkert@intevation.de>
date Wed, 07 Sep 2016 17:37:41 +0200
parents 793748ded4d4
children 8f65341723bf
files app/controller/form/Messprogramm.js
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/app/controller/form/Messprogramm.js	Wed Aug 31 16:24:53 2016 +0200
+++ b/app/controller/form/Messprogramm.js	Wed Sep 07 17:37:41 2016 +0200
@@ -180,9 +180,12 @@
     save: function(button) {
         var formPanel = button.up('form');
         var data = formPanel.getForm().getFieldValues(true);
+        var orte = Ext.data.StoreManager.get('orte');
+        var gemId = orte.getById(data['ortId']).get('gemId');
         for (var key in data) {
             formPanel.getForm().getRecord().set(key, data[key]);
         }
+        formPanel.getForm().getRecord().set('gemId', gemId);
         if (!formPanel.getForm().getRecord().get('letzteAenderung')) {
             formPanel.getForm().getRecord().data.letzteAenderung = new Date();
         }

http://lada.wald.intevation.org