mirror of
https://github.com/hanzoai/jube-fork.git
synced 2026-11-02 14:29:36 +00:00
126 lines
3.9 KiB
HTML
Executable File
126 lines
3.9 KiB
HTML
Executable File
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<title>Methods</title>
|
|
<meta charset="utf-8">
|
|
<link href="../content/shared/styles/examples-offline.css" rel="stylesheet">
|
|
<link href="../../styles/kendo.common.min.css" rel="stylesheet">
|
|
<link href="../../styles/kendo.rtl.min.css" rel="stylesheet">
|
|
<link href="../../styles/kendo.default.min.css" rel="stylesheet">
|
|
<link href="../../styles/kendo.default.mobile.min.css" rel="stylesheet">
|
|
<script src="../../js/jquery.min.js"></script>
|
|
<script src="../../js/jszip.min.js"></script>
|
|
<script src="../../js/kendo.all.min.js"></script>
|
|
<script src="../content/shared/js/console.js"></script>
|
|
<script>
|
|
|
|
</script>
|
|
|
|
|
|
</head>
|
|
<body>
|
|
|
|
<a class="offline-button" href="../index.html">Back</a>
|
|
|
|
<div id="example">
|
|
<div class="configurator">
|
|
<div class="header">Configurator</div>
|
|
<div class="box-col">
|
|
<h4>API Functions</h4>
|
|
<ul class="options">
|
|
<li>
|
|
<input id="typeColumn" name="seriesType"
|
|
type="radio" value="column" checked="checked" autocomplete="off" />
|
|
<label for="typeColumn">Columns</label>
|
|
</li>
|
|
<li>
|
|
<input id="typeBar" name="seriesType"
|
|
type="radio" value="bar" autocomplete="off" />
|
|
<label for="typeBar">Bars</label>
|
|
</li>
|
|
<li>
|
|
<input id="typeLine" name="seriesType"
|
|
type="radio" value="line" autocomplete="off" />
|
|
<label for="typeLine">Lines</label>
|
|
</li>
|
|
<li>
|
|
<input id="stack" type="checkbox" autocomplete="off" checked="checked" />
|
|
<label for="stack">Stacked</label>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="demo-section k-content wide">
|
|
<div id="chart"></div>
|
|
</div>
|
|
<script>
|
|
var series = [{
|
|
name: "Total Visits",
|
|
data: [56000, 63000, 74000, 91000, 117000, 138000],
|
|
|
|
// Line chart marker type
|
|
markers: { type: "square" }
|
|
}, {
|
|
name: "Unique visitors",
|
|
data: [52000, 34000, 23000, 48000, 67000, 83000]
|
|
}];
|
|
|
|
function createChart() {
|
|
$("#chart").kendoChart({
|
|
title: {
|
|
text: "Site Visitors Stats /thousands/"
|
|
},
|
|
legend: {
|
|
position: "bottom"
|
|
},
|
|
seriesDefaults: {
|
|
type: "column",
|
|
stack: true
|
|
},
|
|
series: series,
|
|
valueAxis: {
|
|
line: {
|
|
visible: false
|
|
}
|
|
},
|
|
categoryAxis: {
|
|
categories: ["Jan", "Feb", "Mar", "Apr", "May", "Jun"],
|
|
majorGridLines: {
|
|
visible: false
|
|
}
|
|
},
|
|
tooltip: {
|
|
visible: true,
|
|
format: "{0}"
|
|
}
|
|
});
|
|
}
|
|
|
|
$(document).ready(function () {
|
|
createChart();
|
|
$(document).bind("kendo:skinChange", createChart);
|
|
$(".options").bind("change", refresh);
|
|
});
|
|
|
|
function refresh() {
|
|
var chart = $("#chart").data("kendoChart"),
|
|
type = $("input[name=seriesType]:checked").val(),
|
|
stack = $("#stack").prop("checked");
|
|
|
|
for (var i = 0, length = series.length; i < length; i++) {
|
|
series[i].stack = stack;
|
|
series[i].type = type;
|
|
};
|
|
|
|
chart.setOptions({
|
|
series: series
|
|
});
|
|
}
|
|
</script>
|
|
</div>
|
|
|
|
|
|
|
|
</body>
|
|
</html>
|