前端的页面如果是用datagrid 数据可直接用function loadData(pars) {
$(’#jzxxgl’).datagrid({
columns: [[
{ field: ‘bh’, title: ‘编号’, align: ‘center’, width: 100},
{ field: ‘sfkt’, title: ‘是否开通’, align: ‘center’, width: 100 },
{ field: ‘cz’, title: ‘操作’, align: ‘center’, width: 100,
formatter: function(value,row,index){
var s = '查看 ';
return s;
}
},
]],
});
}
可直接绑定,
但如果用ajax请求的话就用
$.ajax({
type:“POST”,
dataType:“json”,
data:info,
url:"/parentajax/selectFkxxO",
success:function(data){
CloseLoader();
//添加框关闭
if(data.code==-1){
alert_error_GN(decodeURIComponent(data.msg),function(){
window.parent.returnindex();
});
}else {
$("#xs").combobox(“setValue”,data.ssxs)
$("#bt").textbox(“setValue”,data.bt)
$("#xxlx").combobox(“setValue”,data.xxlx)
$("#nr").textbox(“setValue”,data.nr)
$("#ss_js_xm").combobox(“setValue”,data.ssjs)
}
},
error:function(){
timeout()
}
});
}