I have the following problem:
Inside a jqGrid there is a dropdownlist with option dataUrl to fetch data from a server.
If I click on form edit (or add) the dropdown is OK, but I need to disable it if the row is already existing. I saw that by using afterShowForm events, it works only when the dropdown is already populated (after the first time). The first time, it seems that afterShowForm is fired before the dropdown is populated by dataUrl.
How can I solve this issue?
It seems to me that the most simplest way to disable dropdown would be to use
buildSelectevent in the editoptions additionally to the thedataUrl. If the data returned bydataUrlhas already correctform the
buildSelectcan just return the input parameter back, but one can additionally disable theYou should also use
recreateForm:truefor the form to be sure that all callback will be always called. The code schema can be about the following: