Mercurial > lada > lada-client
comparison app/controller/form/Ortszuordnung.js @ 1147:1cf5280bbc45
Fix regex and validate more expressively and stringently.
author | Tom Gottfried <tom@intevation.de> |
---|---|
date | Fri, 27 May 2016 18:07:44 +0200 |
parents | 5ceb0381ae73 |
children | a792eecf1614 |
comparison
equal
deleted
inserted
replaced
1146:645f888e34be | 1147:1cf5280bbc45 |
---|---|
150 * The Buttons are only active if the content of the form was altered | 150 * The Buttons are only active if the content of the form was altered |
151 * (the form is dirty). | 151 * (the form is dirty). |
152 */ | 152 */ |
153 dirtyForm: function(form, dirty) { | 153 dirtyForm: function(form, dirty) { |
154 if (dirty) { | 154 if (dirty) { |
155 if (form.getValues().ortId !== '') { | 155 if (form.getValues().ortId !== '' |
156 && /[UEZA]/.test(form.getValues().ortszuordnungTyp) | |
157 ) { | |
156 form.owner.down('button[action=save]').setDisabled(false); | 158 form.owner.down('button[action=save]').setDisabled(false); |
157 } | 159 } |
158 form.owner.down('button[action=discard]').setDisabled(false); | 160 form.owner.down('button[action=discard]').setDisabled(false); |
159 } | 161 } |
160 else { | 162 else { |