Mercurial > lada > lada-client
annotate app/view/ModeSwitcher.js @ 1060:070255c0db28
Do not show a tooltip for empty data fields.
author | Raimund Renkert <raimund.renkert@intevation.de> |
---|---|
date | Wed, 09 Mar 2016 15:38:55 +0100 |
parents | 7f5219b8e1bf |
children | 2a5d42045c63 |
rev | line source |
---|---|
747
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
1 /* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
2 * Software engineering by Intevation GmbH |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
3 * |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
4 * This file is Free Software under the GNU GPL (v>=3) |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
5 * and comes with ABSOLUTELY NO WARRANTY! Check out |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
6 * the documentation coming with IMIS-Labordaten-Application for details. |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
7 */ |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
8 |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
9 /** |
978
7f5219b8e1bf
Renamed the ProbePlanungSwitcher to a more generic ModeSwitcher and refactored the application
Dustin Demuth <dustin@intevation.de>
parents:
975
diff
changeset
|
10 * This is a Widget for a ModeSwitcher |
747
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
11 */ |
978
7f5219b8e1bf
Renamed the ProbePlanungSwitcher to a more generic ModeSwitcher and refactored the application
Dustin Demuth <dustin@intevation.de>
parents:
975
diff
changeset
|
12 Ext.define('Lada.view.ModeSwitcher', { |
751
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
13 extend: 'Ext.form.FieldSet', |
978
7f5219b8e1bf
Renamed the ProbePlanungSwitcher to a more generic ModeSwitcher and refactored the application
Dustin Demuth <dustin@intevation.de>
parents:
975
diff
changeset
|
14 alias: 'widget.modeswitcher', |
747
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
15 |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
16 mixins: { |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
17 observable: 'Ext.util.Observable' |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
18 }, |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
19 /** |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
20 * Initialise the Widget. |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
21 * When the Checkbox is checked, it fires a 'check' Event |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
22 */ |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
23 initComponent: function() { |
751
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
24 var i18n = Lada.getApplication().bundle; |
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
25 this.title = i18n.getMsg('modus'); |
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
26 this.items= [{ |
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
27 xtype: 'radiogroup', |
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
28 columns: 1, |
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
29 width: '100%', |
747
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
30 items: [{ |
751
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
31 xtype: 'radiofield', |
978
7f5219b8e1bf
Renamed the ProbePlanungSwitcher to a more generic ModeSwitcher and refactored the application
Dustin Demuth <dustin@intevation.de>
parents:
975
diff
changeset
|
32 name: 'modeswitch', |
975
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
33 boxLabel: i18n.getMsg('proben'), |
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
34 inputValue: 'proben', //this determines the store |
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
35 // which will be loaded by the controller, |
794
bc6bc71efb78
Preselect Proben in PPS, Preselect the first entry in the Filter Combobox
Dustin Demuth <dustin@intevation.de>
parents:
792
diff
changeset
|
36 checked: true, |
751
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
37 handler: function(field, state){ |
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
38 if (state === true) { |
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
39 this.fireEvent('check', field); |
747
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
40 } |
751
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
41 } |
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
42 },{ |
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
43 xtype: 'radiofield', |
978
7f5219b8e1bf
Renamed the ProbePlanungSwitcher to a more generic ModeSwitcher and refactored the application
Dustin Demuth <dustin@intevation.de>
parents:
975
diff
changeset
|
44 name: 'modeswitch', |
975
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
45 boxLabel: i18n.getMsg('messprogramme'), |
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
46 inputValue: 'messprogramme', |
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
47 handler: function(field, state){ |
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
48 if (state === true) { |
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
49 this.fireEvent('check', field); |
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
50 } |
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
51 } |
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
52 },{ |
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
53 xtype: 'radiofield', |
978
7f5219b8e1bf
Renamed the ProbePlanungSwitcher to a more generic ModeSwitcher and refactored the application
Dustin Demuth <dustin@intevation.de>
parents:
975
diff
changeset
|
54 name: 'modeswitch', |
975
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
55 boxLabel: i18n.getMsg('stammdaten'), |
fb99332bb48e
Severe changes concerning the Resultgrids.
Dustin Demuth <dustin@intevation.de>
parents:
794
diff
changeset
|
56 inputValue: 'stammdaten', |
751
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
57 handler: function(field, state){ |
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
58 if (state === true) { |
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
59 this.fireEvent('check', field); |
747
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
60 } |
751
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
61 } |
747
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
62 }] |
751
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
63 }]; |
704bb359c0fe
dynamically exchange the store of the resultfiltergrid
Dustin Demuth <dustin@intevation.de>
parents:
747
diff
changeset
|
64 this.callParent(arguments); |
747
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
65 } |
3ffecbce17d6
Radio-Buttons to switch between query-modes: Probenliste und Probenplanung. Filter-Combobox store wird automatisch gewechselt. ToDo: Query-Store für Probenplanung
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
66 }); |