jquery easyui datagrid 列和数据标准json 格式急。。。
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了jquery easyui datagrid 列和数据标准json 格式急。。。相关的知识,希望对你有一定的参考价值。
下面json格式有什么问题求解
"columns":[["field":"one","title":"10:00","width":50,"field":"two","title":"10:05","width":50,"field":"three","title":"10:10","width":50,"field":"four","title":"10:15","width":50,"field":"five","title":"10:20","width":50,"field":"six","title":"10:25","width":50,"field":"seven","title":"10:30","width":50,"field":"eight","title":"10:35","width":50,"field":"nine","title":"10:40","width":50,"field":"ten",""title"":"10:45","width":50,"field":"eleven","title":"10:50","width":50,"field":"twelve","title":"10:55","width":50]],"data":["total":24,"rows":["appId":1,"appName":"营销管理","average":0,"beginDate":"","deviation":0,"eaverage":0,"ebeginDate":"","eendDate":"","eight":0,"eighteen":0,"eleven":7.491,"emaxinum":0,"endDate":"","fault":0,"fifteen":0,"five":0,"forty":0,"fortyOne":0,"fortyTwo":0,"four":0,"fourteen":0,"id":0,"maxinum":0,"minnum":0,"nine":2.491,"nineteen":0,"one":0,"optime":null,"passnum":0,"runDate":"2014-07-14","seven":0,"seventeen":0,"six":0,"sixteen":0,"status":"00","stopNum":0,"ten":6.491,"thirteen":0,"thirty":0,"thirtyEight":0,"thirtyFive":0,"thirtyFour":0,"thirtyNine":0,"thirtyOne":0,"thirtySeven":0,"thirtySix":0,"thirtyThree":0,"thirtyTwo":0,"three":0,"time":"","twelve":5.491,"twenty":0,"twentyEight":0,"twentyFive":0,"twentyFour":0,"twentyNine":0,"twentyOne":0,"twentySeven":0,"twentySix":0,"twentyThree":0,"twentyTwo":0,"two":0,"type":"查询工作单"]]
$('#dg').datagrid(
url:'datagrid_data.json',
columns:[[
field:'code',title:'Code',width:100,
field:'name',title:'Name',width:100,
field:'price',title:'Price',width:100,align:'right'
]]
);
2、json数据格式
"total":2,"rows":[
"code":"RP-LI-02","name":"Persian","price":89.50,
"code":"AV-CB-01","name":"Amazon Parrot","price":63.50
] 参考技术B 一眼看上去没有什么问题。。。。。
数据有问题。
你的data:xxxx 左侧的data也是你返回来的吗?
建议你打开easyui官网,看看里面的demo中的datagrid返回的格式。那个嘴标准
以上是关于jquery easyui datagrid 列和数据标准json 格式急。。。的主要内容,如果未能解决你的问题,请参考以下文章