Cynteka Pivot Table
Cynteka Pivot Table is a jQuery plugin for websites. It supports all usual pivot table's features: data rotating, dragging and dropping fields, summarization etc.
Demo
Getting Started
In order to start using the pivot table just include plugin's files into your webpage and invoke it.
<html>
<head>
<!-- Include jQuery and jQuery UI with css files -->
<script src='http://code.jquery.com/jquery-2.1.0.min.js' type="text/javascript"></script>
<link rel="stylesheet" href="//ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/themes/smoothness/jquery-ui.css"></link>
<script src="//ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/jquery-ui.min.js"></script>
<!-- Include jQuery Cookie plugin -->
<script src='//cdn.jsdelivr.net/jquery.cookie/1.4.0/jquery.cookie.js' type="text/javascript"></script>
<!-- Include jQuery Cynteka Pivot plugin -->
<link rel="stylesheet" media="screen" href="css/jquery.cy-pivot.css"></link>
<script src="js/jquery.cy-pivot.js" type="text/javascript"></script>
<script type="text/javascript">
$(document).ready(function(){
$("#pivot").cypivot({
// Params go here. See Constructor params
// ...
});
});
</script>
</head>
<body>
<div id="pivot"></div>
</body>
<html>
Documentation
Browser Compatibility
- IE 10+
- Chrome 14+
- Firefox 4+
- Safari 5.1+
- Opera 11.6+
Constructor
$("#pivot").cypivot({ /* Params go here ... */ });
Parameter | Type | Description |
---|---|---|
configuration |
boolean or object |
If true then user can reconfigurate column/row dimensions. If false user can not do this.
If you want to allow the user to reconfigurate only columns or rows, use the the following way:
|
data | array of objects |
Array of data to be used for pivoting. E.g.
|
dataCellRenderer | function(items, colContext, rowContext, opts) |
The function that create html for a cell specified by colContext/rowContext params. E.g.
|
dimensions | map of objects |
Map of dimension descriptors. E.g.
|
horizontalDimensions | array of strings |
Array of dimension's names that should be used for rows. E.g.
|
valueDataFields | array of strings |
Array of fields in data objects that should be used as value fields. E.g.
|
verticalDimensions | array of strings |
Array of dimension's names that should be used for columns. E.g.
|
Methods
Method | Params | Description |
---|---|---|
reload | newData array of objects |
Refreshes all data within pivot table.
E.g.
|
Download
You can download zip
file or download archive from
Github repository.
About
The plugin is developed in Cynteka company by
Sergey Grigorchuk.