100 строки
5.1 KiB
HTML
100 строки
5.1 KiB
HTML
|
<!DOCTYPE html>
|
|||
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|||
|
<head>
|
|||
|
<title></title>
|
|||
|
<link href="../content/bootstrap.min.css" rel="stylesheet" />
|
|||
|
<link href="../content/ejthemes/default-theme/ej.web.all.min.css" rel="stylesheet" />
|
|||
|
<link href="../content/default.css" rel="stylesheet" />
|
|||
|
<link href="../content/default-responsive.css" rel="stylesheet" />
|
|||
|
<!--[if lt IE 9]>
|
|||
|
<script src="../scripts/jquery-1.11.3.min.js" type="text/javascript"></script>
|
|||
|
<!--<![endif]-->
|
|||
|
<!--[if gte IE 9]><!-->
|
|||
|
<script src="../scripts/jquery-3.4.1.min.js" type="text/javascript"></script>
|
|||
|
<!--<![endif]-->
|
|||
|
<script src="../scripts/ej.web.all.min.js" type="text/javascript"></script>
|
|||
|
<script src="../scripts/properties.js" type="text/javascript"></script>
|
|||
|
<script src="../scripts/jsrender.min.js"></script>
|
|||
|
</head>
|
|||
|
<body>
|
|||
|
<div class="content-container-fluid">
|
|||
|
<div class="row">
|
|||
|
<div class="cols-sample-area">
|
|||
|
<div class="control" style="margin-left: -16px;">
|
|||
|
<div id="PivotClient" style="min-height: 275px; min-width: 525px;" />
|
|||
|
<script type="text/javascript">
|
|||
|
$(function () {
|
|||
|
$("#PivotClient").ejPivotClient({
|
|||
|
dataSource: {
|
|||
|
data: window.biurl + "olap/msmdpump.dll", //data
|
|||
|
catalog: "Adventure Works DW 2008 SE",
|
|||
|
cube: "Adventure Works",
|
|||
|
rows: [
|
|||
|
{
|
|||
|
fieldName: "[Date].[Fiscal]"
|
|||
|
}
|
|||
|
],
|
|||
|
columns: [
|
|||
|
{
|
|||
|
fieldName: "[Customer].[Customer Geography]"
|
|||
|
}
|
|||
|
],
|
|||
|
values: [
|
|||
|
{
|
|||
|
measures: [
|
|||
|
{
|
|||
|
fieldName: "[Measures].[Internet Sales Amount]"
|
|||
|
}
|
|||
|
],
|
|||
|
axis: "columns"
|
|||
|
}
|
|||
|
]
|
|||
|
},
|
|||
|
title: "OLAP Browser", enableRTL: true, renderSuccess: "setChartProperties", customObject: { Language: "en-US" }, beforeExport: "Export", saveReport: "saveReportSettings", fetchReport: "saveReportSettings", loadReport: "saveReportSettings"
|
|||
|
});
|
|||
|
});
|
|||
|
function setChartProperties(args) {
|
|||
|
this._pivotChart.model.load = "loadTheme";
|
|||
|
if (args._successAction == undefined || args._successAction == "Filter") {
|
|||
|
this._pivotChart.model.legend.rowCount = 2;
|
|||
|
this._pivotChart.model.primaryXAxis = { title: { text: "Fiscal Year" }, labelRotation: 270 };
|
|||
|
this._pivotChart.model.primaryYAxis = { title: { text: "Internet Sales Amount" } };
|
|||
|
}
|
|||
|
}
|
|||
|
function Export(args) {
|
|||
|
args.url = window.baseurl + "api/PivotClient/Olap/Export";
|
|||
|
}
|
|||
|
function saveReportSettings(args) {
|
|||
|
if (args.fetchReportSetting)
|
|||
|
args.fetchReportSetting.url = window.baseurl + "api/PivotClient/Olap";
|
|||
|
else if (args.loadReportSetting)
|
|||
|
args.loadReportSetting.url = window.baseurl + "api/PivotClient/Olap";
|
|||
|
else
|
|||
|
args.saveReportSetting.url = window.baseurl + "api/PivotClient/Olap";
|
|||
|
return args;
|
|||
|
}
|
|||
|
</script>
|
|||
|
</div>
|
|||
|
</div>
|
|||
|
</div>
|
|||
|
</div>
|
|||
|
|
|||
|
<!--PivotTreeMap Tooltip labels can be localized here-->
|
|||
|
<script id="tooltipTemplate" type="application/jsrender">
|
|||
|
<div style="background:White; color:black; font-size:12px; font-weight:normal; border: 1px solid #4D4D4D; white-space: nowrap;border-radius: 2px; margin-right: 25px; min-width: 110px;padding-right: 5px; padding-left: 5px; padding-bottom: 2px ;width: auto; height: auto;">
|
|||
|
<div>Measure(s) : {{:~Measures(#data)}}</div><div>Row : {{:~Row(#data)}}</div><div>Column : {{:~Column(#data)}}</div><div>Value : {{:~Value(#data)}}</div>
|
|||
|
</div>
|
|||
|
</script>
|
|||
|
<style>
|
|||
|
.samplecontent {
|
|||
|
padding: 4px;
|
|||
|
}
|
|||
|
|
|||
|
.row .cols-sample-area {
|
|||
|
overflow: auto;
|
|||
|
}
|
|||
|
</style>
|
|||
|
|
|||
|
</body>
|
|||
|
</html>
|