EasyUI Forum

General Category => EasyUI for jQuery => Topic started by: kayjay on January 22, 2016, 08:43:01 AM



Title: edatagrid with dynamic combobox
Post by: kayjay on January 22, 2016, 08:43:01 AM
Hi,

I use a 'edatagrid' to display and edit valued in my db. Two of my five columns are combobox. I use a 'url:' to get the combobox values from the server. The values for combobox2 depend on what is selected in combobox1. When the user starts to edit a row and they change the field that depends on combobox1 I want to give them the correct set of options for combobox2.

Ideally when the user moves to the field that depends on combobox2 if I could somehow pass the row index as a parameter in the 'url:' then the server could return the correct combobox values but I cannot see any way to do this. Is there some clever way to achieve this functionality?

Thanks


Title: Re: edatagrid with dynamic combobox
Post by: jarry on January 22, 2016, 07:40:11 PM
You must get all the combobox editors and set their binding relations when beginning to edit a row. Please refer to http://www.jeasyui.com/tutorial/datagrid/datagrid15.php