comparison app/view/window/ProbeEdit.js @ 707:c632c7c34029

added disable/enableChildren Method
author Dustin Demuth <dustin@intevation.de>
date Fri, 27 Mar 2015 15:22:32 +0100
parents 3e4be37e3e46
children 6f6d2df00130
comparison
equal deleted inserted replaced
706:3e4be37e3e46 707:c632c7c34029
144 enableAddMessungen: function(){ 144 enableAddMessungen: function(){
145 this.down('fset[name=messungen]').down('messunggrid').setReadOnly(false); 145 this.down('fset[name=messungen]').down('messunggrid').setReadOnly(false);
146 }, 146 },
147 147
148 disableChildren: function(){ 148 disableChildren: function(){
149 this.down('fset[name=messungen]').down('messunggrid').setReadOnly(true); 149 if (!this.record.get('owner')) {
150 // Disable only when the User is not the owner of the Probe
151 // Works in symbiosis with success callback some lines above.
152 this.down('fset[name=messungen]').down('messunggrid').setReadOnly(true);
153 }
150 this.down('fset[name=orte]').down('ortgrid').setReadOnly(true); 154 this.down('fset[name=orte]').down('ortgrid').setReadOnly(true);
151 this.down('fset[name=probenzusatzwerte]').down('probenzusatzwertgrid').setReadOnly(true); 155 this.down('fset[name=probenzusatzwerte]').down('probenzusatzwertgrid').setReadOnly(true);
152 this.down('fset[name=pkommentare]').down('pkommentargrid').setReadOnly(true); 156 this.down('fset[name=pkommentare]').down('pkommentargrid').setReadOnly(true);
153 }, 157 },
154 158

http://lada.wald.intevation.org