diff app/model/Messprogramm.js @ 1234:390dabbf27ed

Empty string for media descriptor is disallowed. This follows server Rev 1ef08710aaeb.
author Tom Gottfried <tom@intevation.de>
date Fri, 28 Oct 2016 21:23:31 +0200
parents 4270da0f7d3b
children d1f43f1e7e84
line wrap: on
line diff
--- a/app/model/Messprogramm.js	Fri Oct 28 20:04:20 2016 +0200
+++ b/app/model/Messprogramm.js	Fri Oct 28 21:23:31 2016 +0200
@@ -40,7 +40,13 @@
     }, {
         name: 'ortId'
     }, {
-        name: 'mediaDesk'
+        name: 'mediaDesk',
+        serialize: function(value) {
+            if (value === '') {
+                return null;
+            }
+            return value;
+        }
     }, {
         name: 'umwId',
         serialize: function(value) {

http://lada.wald.intevation.org