Hi Isomorphic,
I have a DynamicForm linked to a Listgrid. The Listgrid acts as a record selector, so that in the form you can edit the details of the record selected in the Listgrid.
One of the fields of the form is a Combobox, and the available options (which are dynamic and have to be retrieved from the server) depend on what record is being edited. Hence, each time the selection is updated in the Listgrid, the set of available values in the Combobox should be refreshed accordingly.
The approach that I have used is the following: I am using an optionDataSource to retrieve the Combobox available values. This optionDataSource has an inner attribute that marks the PK of the currently selected record. This attribute will be sent to the server in the fetchData call (inserted throught the transformRequest method). The problem I'm facing is that althought this attribute is updated each time the Listgrid selection changes (in the listgrid.selectionUpdated method), Smart Client does not call the fetchData in order to refresh the available values. I've seen that Smart Client does call the fetchData method, but it seems that the aim of this call is to update the value of the displayField, but not the list of available values.
What is the best approach to solve this problem? How can I force Smart Client to refresh the list of available values?
Smart client version: v8.3p_2013-05-28 (2013-05-28)
Browser: Google Chrome 27.0.1453.94 m
I have a DynamicForm linked to a Listgrid. The Listgrid acts as a record selector, so that in the form you can edit the details of the record selected in the Listgrid.
One of the fields of the form is a Combobox, and the available options (which are dynamic and have to be retrieved from the server) depend on what record is being edited. Hence, each time the selection is updated in the Listgrid, the set of available values in the Combobox should be refreshed accordingly.
The approach that I have used is the following: I am using an optionDataSource to retrieve the Combobox available values. This optionDataSource has an inner attribute that marks the PK of the currently selected record. This attribute will be sent to the server in the fetchData call (inserted throught the transformRequest method). The problem I'm facing is that althought this attribute is updated each time the Listgrid selection changes (in the listgrid.selectionUpdated method), Smart Client does not call the fetchData in order to refresh the available values. I've seen that Smart Client does call the fetchData method, but it seems that the aim of this call is to update the value of the displayField, but not the list of available values.
What is the best approach to solve this problem? How can I force Smart Client to refresh the list of available values?
Smart client version: v8.3p_2013-05-28 (2013-05-28)
Browser: Google Chrome 27.0.1453.94 m
Comment