diff app/view/window/MessungEdit.js @ 710:f204f30b824a

Handle readonly mode and refresh operations.
author Raimund Renkert <raimund.renkert@intevation.de>
date Wed, 08 Apr 2015 10:50:33 +0200
parents 6f6d2df00130
children baef70abfe71
line wrap: on
line diff
--- a/app/view/window/MessungEdit.js	Tue Apr 07 17:16:59 2015 +0200
+++ b/app/view/window/MessungEdit.js	Wed Apr 08 10:50:33 2015 +0200
@@ -145,12 +145,15 @@
                 if (json) {
                     this.setMessages(json.errors, json.warnings);
                 }
+                if (this.record.get('readonly') === true) {
+                    this.disableForm();
+                }
+                else {
+                    this.enableForm();
+                }
             },
             scope: this
         });
-        if (this.record.get('readonly') == true){
-            this.disableForm();
-        }
     },
 
     disableForm: function(){

http://lada.wald.intevation.org