easyui-combobox获取后台传递的值

1、页面代码:

 

<input name="provinceid" class="easyui-combobox" data-options="
			valueField: 'id',
			textField: 'name',
			url: 'hospital/baseinfo/listProv.action'"/>


2、后台获取值:

 

 

    @RequestMapping("/listProv")
    @ResponseBody
    public List<TbProvince> qryAllProvs()
    {
        List<TbProvince> list = this.provinceService.qryAllProvs();
        return list;
    }


返回json报文格式:

 

 

[{"name":"北京","id":1},{"name":"上海","id":2},{"name":"广东","id":3},{"name":"广西","id":4},{"name":"江苏","id":5},{"name":"浙江","id":6},{"name":"安徽","id":7},{"name":"江西","id":8},{"name":"山东","id":9},{"name":"福建","id":10},{"name":"山西","id":11},{"name":"河北","id":12},{"name":"天津","id":13},{"name":"辽宁","id":14},{"name":"黑龙江","id":15},{"name":"吉林","id":16},{"name":"湖北","id":17},{"name":"湖南","id":18},{"name":"四川","id":19},{"name":"重庆","id":20},{"name":"陕西","id":21},{"name":"甘肃","id":22},{"name":"云南","id":23},{"name":"新疆","id":24},{"name":"内蒙古","id":25},{"name":"海南","id":26},{"name":"贵州","id":27},{"name":"青海","id":28},{"name":"宁夏","id":29},{"name":"西藏","id":30},{"name":"河南","id":31},{"name":"台湾","id":32}]

 

 

 

 

 

评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值