changeset 765:62721a75d31d

A draft on how the Nuklide could be selected... maybe this path can be used
author Dustin Demuth <dustin@intevation.de>
date Fri, 08 May 2015 16:12:01 +0200 (2015-05-08)
parents ba8c0e754979
children 31eaed998531
files app/controller/grid/Messmethode.js
diffstat 1 files changed, 12 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/app/controller/grid/Messmethode.js	Fri May 08 15:31:58 2015 +0200
+++ b/app/controller/grid/Messmethode.js	Fri May 08 16:12:01 2015 +0200
@@ -88,7 +88,19 @@
         if (!store) {
             store = Ext.create('Lada.store.Messgroessen');
         }
+        //get selection model
+        var selectedRecords = [];
+        //iterate store and slecet all records which are in nuklide array
+        store.each(function(record){
+            //TODO if(record.get('id') in nuklide){
+                selectedRecords.push(record);
+            //TODO}
+        });
         ngrid.setData(store);
+
+        var selModel = ngrid.getSelectionModel();
+        console.log(selModel);
+        selModel.select(selectedRecords, false, false);
     },
 
     /**

http://lada.wald.intevation.org