Hi i was trying to populate the dropdown, but facing some issue, not able to find any xmaples. can you please help me. I am tying to send the drop down as map which is present ias one of the feilds in "data".
I think ThomD is correct in that we'll need to be able to see the code you are using. However, to populate the options list you can use the Field->options() method (assuming you are using the PHP libraries?) as documented here.
options:"this is what i wan to know how to populate"
You have two options. You can use the update() method of the select field type. Or you can have your viewOrder.do?method=listOfOrders JSON response include the options you want to show. You would do that by providing an options object with the options to be shown in a parameter name matching the field name.
Answers
this is the json that i am sending
data":
in this ordertypelist is the list i want to show
Please post a sample of the code you have so far.
Hi,
I think ThomD is correct in that we'll need to be able to see the code you are using. However, to populate the options list you can use the
Field->options()
method (assuming you are using the PHP libraries?) as documented here.There is an example available showing that in action.
Regards,
Allan
I am using java, not PHP. and sending the ajax content. I am a bit new to this, so not able to add the list to populate the dropdown, the following
You have two options. You can use the
update()
method of theselect
field type. Or you can have yourviewOrder.do?method=listOfOrders
JSON response include the options you want to show. You would do that by providing anoptions
object with the options to be shown in a parameter name matching the field name.For example:
Allan