How do I change selected value of select2 dropdown with JqGrid?

后端 未结 16 997
遥遥无期
遥遥无期 2020-11-27 10:27

I\'m using Oleg\'s select2 demo, but I am wondering whether it would be possible to change the currently selected value in the dropdown menu.

For example, if the fou

16条回答
  •  不知归路
    2020-11-27 10:54

    This should be even easier.

    $("#e1").select2("val", ["View" ,"Modify"]);
    

    But make sure the values which you pass are already present in the HTMl

提交回复
热议问题