[Lada-commits] [PATCH 2 of 6] Updated status model

Wald Commits scm-commit at wald.intevation.org
Thu Mar 12 09:48:14 CET 2015


# HG changeset patch
# User Raimund Renkert <raimund.renkert at intevation.de>
# Date 1426149952 -3600
# Node ID 9b3adfb7b1aec2e4756bde70015fc08cf4dc23e1
# Parent  825973ca386fd3636b1860e65aa6c34948119016
Updated status model.

diff -r 825973ca386f -r 9b3adfb7b1ae app/model/Status.js
--- a/app/model/Status.js	Thu Mar 12 09:44:47 2015 +0100
+++ b/app/model/Status.js	Thu Mar 12 09:45:52 2015 +0100
@@ -17,9 +17,19 @@
     }, {
         name: 'messungsId'
     }, {
+        name: 'erzeuger'
+    }, {
         name: 'status'
     }, {
-        name: 'sdatum'
+        name: 'sdatum',
+        type: 'date',
+        convert: function(v) {
+            if (!v) {
+                return v;
+            }
+            return new Date(v);
+        },
+        defaultValue: new Date()
     }, {
         name: 'skommentar'
     }],


More information about the Lada-commits mailing list