GrapheneDataGrid provides a full tabular interface for managing, manipulating, and displaying data. The DataGrid offers:
<script>
gdg = new GrapheneDataGrid({el:'#myGrapheneDataGrid',
search: false,columns: false,upload:false,download:false,title:'Demo Content',
entries:[],
count:4,
schema:[
{type:"text", name:"name", label:"Name", required:true},
{type:"text", name:"number",label:"Age"}
], data: [
{name:'Bob'},
{name:'Adam', number: 30},
{name:'Tim', number: 30.5},
{name:'Lauri', number: 21},
{name:'Scott'},
]
})
</script>
Dependencies - jQuery, Bootstrap 3.4.1 (Both JS and CSS), Lodash, GrapheneForms (BootStrap)
The first two dependencies we incorporate are jQuery and Bootstrap 3.4.1 for the purpose of styling and functionality.
For Bootstrap make sure to include both:
- Bootstrap's get started page helps you setup jquery -
<script src='//ajax.googleapis.com/ajax/libs/jquery/2.0.3/jquery.min.js'></script>
<style src='//maxcdn.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css'></style>
--To Set Up GrapheneForms, navigate to Graphene Forms, go to the top of the page and select "Get Code". Include the downloaded code in your project--
A minimum setup might look something like this:
<!DOCTYPE html>
<html>
<head>
<script src='//ajax.googleapis.com/ajax/libs/jquery/2.0.3/jquery.min.js'></script>
<style src='//maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css'></style>
<style src='//netdna.bootstrapcdn.com/font-awesome/4.1.0/css/font-awesome.min.css'></style>
<script type='text/javascript' src='https://cdnjs.cloudflare.com/ajax/libs/lodash.js/4.17.11/lodash.min.js'></script>
<script type='text/javascript' src='https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js'></script>
<script type='text/javascript' src='gform.bootstrap.min.js'></script>
<script type='text/javascript' src='GrapheneDataGrid.min.js'></script>
//CSS Includes
</head>
<body>
<div class="myTable">
//Other HTML
</div>
<script>
//Make DataGrids Here
</script>
</body>
</html>