jQuery MiniUI

标题: 单选按钮组怎么填上字典表啊 [打印本页]

作者: Soft_Vigorous    时间: 2013-11-25 09:47:02     标题: 单选按钮组怎么填上字典表啊

<div class="mini-radiobuttonlist" repeatItems="2" repeatLayout="table" repeatDirection="vertical"
    textField="text" valueField="id" value="cn"
    url="../data/countrys.txt" >
</div>
单选按钮组怎么填上字典表啊,
作者: factory    时间: 2013-11-25 10:01:54

例子里面的就是啊

是一个数组,里面是一个key value的对象
  1. [
  2.     { "id": "usa", "text": "美国" },
  3.     { "id": "cn", "text": "中国" },
  4.     { "id": "jp", "text": "日本" },
  5.     { "id": "en", "text": "英国" },
  6.     { "id": "de", "text": "德国" },
  7.     { "id": "fr", "text": "法国" },
  8.         { "id": "ca", "text": "加拿大" },
  9.         { "id": "at", "text": "奥地利" },
  10.         { "id": "ch", "text": "瑞士" }
  11. ]
复制代码

作者: Soft_Vigorous    时间: 2013-11-25 11:33:17

factory 发表于 2013-11-25 10:01
例子里面的就是啊

是一个数组,里面是一个key value的对象

你误解了我的意思了,我是要直接在表中取到的数据,不是写死的txt文档。
作者: factory    时间: 2013-11-25 11:55:12

Soft_Vigorous 发表于 2013-11-25 11:33
你误解了我的意思了,我是要直接在表中取到的数据,不是写死的txt文档。 ...

没区别的啊..那你后台返回这样的json字符串好了

http://www.miniui.com/demo/#src=combobox/linkage-combo.html

这个是服务端的获取数据




欢迎光临 jQuery MiniUI (http://miniui.com/discuss/) Powered by Discuz! X2