Let's see demo.
json:
[{"id":"1","value":"Apple"} ,{"id":"2","value":"Banana"} ,{"id":"3","value":"Lemon"} ,{"id":"4","value":"Melon"}]
generate checkbox or radio
$("#options").dataOption({ datasource:json ,init: ,optionType: ,buttonSet: }); |
options |
serial generate
$("#inits").dataOption({optionType:"checkbox",buttonSet:false ,init:[2,3] ,options:{start:1 ,genDatasource:4}});
generate select
$("#optionType").dataOption({ datasource:[{id:"checkbox",value:"checkbox"} ,{id:"radio",value:"radio"}]}); $("#buttonSet").dataOption({ datasource:[{id:"true",value:"true"} ,{id:"false",value:"false"}]});download jqDataOption
沒有留言:
張貼留言