diff app.js @ 497:7c0653e8d9f7

Fixed some js related issues (unused vars, arrays, etc.) and code style.
author Raimund Renkert <raimund.renkert@intevation.de>
date Thu, 06 Nov 2014 10:38:17 +0100
parents d07e5086a64b
children 8b4ec61c5752
line wrap: on
line diff
--- a/app.js	Thu Nov 06 10:35:35 2014 +0100
+++ b/app.js	Thu Nov 06 10:38:17 2014 +0100
@@ -1,11 +1,11 @@
-/* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz
+/**
+ * Copyright (C) 2013 by Bundesamt fuer Strahlenschutz
  * Software engineering by Intevation GmbH
  *
  * This file is Free Software under the GNU GPL (v>=3)
  * and comes with ABSOLUTELY NO WARRANTY! Check out
  * the documentation coming with IMIS-Labordaten-Application for details.
  */
-
 Ext.Loader.setConfig({
     enabled: true,
     paths: {
@@ -113,25 +113,23 @@
 });
 
 Ext.data.writer.Json.override({
-    getRecordData: function(record, getEverything) {
-        if(this.writeEverything || record.writeEverything){
-            console.log('getRecordData', this,arguments);
+    getRecordData: function(record) {
+        if (this.writeEverything || record.writeEverything) {
+            console.log('getRecordData', arguments);
             return record.getAllData();
         }
-        else {
-            return this.callOverridden(arguments);
-        }
+        return this.callOverridden(arguments);
     }
 });
 
 Ext.data.Model.addMembers({
     getAllData: function() {
         var data1 = this.getData();
-        var data2 = this.getAssociatedData( );
+        var data2 = this.getAssociatedData();
         var dataMerged = Ext.Object.merge(data1, data2);
         return dataMerged;
     },
     getEidi: function() {
-        return "/" + this.getId();
+        return '/' + this.getId();
     }
 });

http://lada.wald.intevation.org