如何使用 jsgrid 在表格上呈现数据,就像 jsgrid 使用的那样
我尝试按照本文档 https://firebase.google.com/docs/database/rest/retrieve-data#section-rest-reading-data-get所述检索数据
$.getJSON("/*url of databse*/.json",
function(data){
clients = data;
console.log(clients);
});
$("#jsGrid").jsGrid({
width: "100%",
height: "400px",
inserting: true,
editing: true,
sorting: true,
paging: true,
data: clients,
fields: [
{ name: "Name", type: "text", width: 150, validate: "required" },
{ name: "Email", type: "number", width: 50 },
{ type: "control" }
]
});
无论如何要在 jsgrid 中的表格上显示数据吗?