Hi,
There seem to be a problem in DynamicForm when trying to turn canEdit() to false. Here is a small example:
And here is the datasource definition:
In the dynamic form, the BUNIT_NAME field is still editable, altough I've called setCanEdit(false) in the dynamic form.
Note that if I add:
... then the field is read-only as expected.
Can you please have a look if fix this if necessary?
Thanks,
Thomas
PS: We are using SGWT 4.0 (Power edition)
There seem to be a problem in DynamicForm when trying to turn canEdit() to false. Here is a small example:
Code:
DataSource.load("test", new Function() {
@Override
public void execute() {
DynamicForm form = new DynamicForm();
form.setDataSource(DataSource.get("test"));
form.setCanEdit(false);
form.fetchData(new Criteria("ID", "1"));
form.draw();
}
}, true);
Code:
<DataSource
ID="test"
serverType="sql"
tableName="SEC_OPERATOR"
>
<fields>
<field name="ID" type="integer" hidden="true" primaryKey="true" />
<field name="NAME" type="text" title="Name"/>
<field name="BUNIT_ID" type="integer" foreignKey="businessUnit.ID" hidden="true" title="Business Unit"/>
<field name="BUNIT_NAME" type="text" includeFrom="businessUnit.NAME" title="BUnit" />
</fields>
</DataSource>
Note that if I add:
Code:
form.getField("BUNIT_NAME").setCanEdit(false);
Can you please have a look if fix this if necessary?
Thanks,
Thomas
PS: We are using SGWT 4.0 (Power edition)
Comment