Revision 1852

View differences:

org.gvsig.tools/library/trunk/org.gvsig.tools/org.gvsig.tools.dynform/org.gvsig.tools.dynform.impl/src/main/java/org/gvsig/tools/dynform/impl/DefaultJDynForm.java
254 254
            Iterator it = this.getFieldsIterator();
255 255
            while (it.hasNext()) {
256 256
                JDynFormField field = (JDynFormField) it.next();
257
                field.setReadOnly(readOnly);
257
                if( readOnly ) {
258
                    field.setReadOnly(true);
259
                } else if( field.getDefinition().isReadOnly() ) {
260
                    field.setReadOnly(true);
261
                } else {
262
                    field.setReadOnly(false);
263
                }
258 264
            }
259 265
        }
260 266
    }
......
308 314
        for (DynField field : fields) {
309 315
            String name = field.getName();
310 316
            JDynFormField jfield = (JDynFormField) this.getField(name);
311
            if (jfield != null) {
317
            if (jfield != null && !jfield.isReadOnly()) {
312 318
                try {
313 319
                    jfield.fetch(values);
314 320
                } catch (Exception ex) {

Also available in: Unified diff