Mercurial > lada > lada-client
comparison app/controller/Sql.js @ 25:f964a50bfe57
Restructured the application. Fixed layouts etc.
author | Torsten Irländer <torsten.irlaender@intevation.de> |
---|---|
date | Wed, 08 May 2013 12:20:06 +0200 |
parents | 3eaeeec2bb28 |
children | 4d60b9ebce15 |
comparison
equal
deleted
inserted
replaced
24:72778ac34dbb | 25:f964a50bfe57 |
---|---|
22 onPanelRendered: function() { | 22 onPanelRendered: function() { |
23 console.log('The panel was rendered'); | 23 console.log('The panel was rendered'); |
24 }, | 24 }, |
25 selectSql: function(grid, record) { | 25 selectSql: function(grid, record) { |
26 var selection = record.get('id'); | 26 var selection = record.get('id'); |
27 var variables = Ext.getCmp('searchVariables'); | 27 var variables = Ext.getCmp('variables'); |
28 console.log('Selected SQL' + selection); | 28 var result = Ext.getCmp('result'); |
29 // Set correct form for the current SQL-Selection | 29 console.log('Selected SQL ' + selection); |
30 console.log('Length is ' + variables.items.length); | 30 //// Set correct form for the current SQL-Selection |
31 if (variables.items.length > 1) { | 31 //console.log('Length is ' + variables.items.length); |
32 console.log('Length is > than 1'); | 32 //if (variables.items.length > 1) { |
33 variables.remove(currentVar.id); | 33 // console.log('Length is > than 1'); |
34 } | 34 // variables.remove(currentVar.id); |
35 if (selection == 1) { | 35 //} |
36 currentVar = variables1; | 36 //if (selection == 1) { |
37 } | 37 // currentVar = variables1; |
38 else { | 38 //} |
39 currentVar = variables2; | 39 //else { |
40 } | 40 // currentVar = variables2; |
41 variables.add(currentVar); | 41 //} |
42 // Show the panel for the variable definiton. | 42 //variables.add(currentVar); |
43 variables.show(); | 43 //// Show the panel for the variable definiton. |
44 //variables.show(); | |
44 | 45 |
45 // Show the results. | 46 // Show the results. |
46 Ext.getCmp('searchResult').show(); | 47 result.getStore().load(); |
48 result.show(); | |
47 } | 49 } |
48 }); | 50 }); |
49 | 51 |
50 | 52 |
51 var currentVar = null; | 53 var currentVar = null; |