原創|使用教程|編輯:龔雪|2020-12-30 10:23:06.410|閱讀 168 次
概述:Kendo UI for jQuery是創建現代Web應用程序的最完整UI庫,本文將為大家介紹Kendo UI PivotGrid的功能概述,歡迎下載最新版體驗!
# 界面/圖表報表/文檔/IDE等千款熱門軟控件火熱銷售中 >>
相關鏈接:
Kendo UI for jQuery R3 2020 SP2試用版下載
Kendo UI是帶有jQuery、Angular、React和Vue庫的JavaScript UI組件的最終集合,無論選擇哪種JavaScript框架,都可以快速構建高性能響應式Web應用程序。通過可自定義的UI組件,Kendo UI可以創建數據豐富的桌面、平板和移動Web應用程序。通過響應式的布局、強大的數據綁定、跨瀏覽器兼容性和即時使用的主題,Kendo UI將開發時間加快了50%。
Kendo UI PivotGrid以交叉表格式表示多維數據。
要將PivotGrid配置為托管在//demos.telerik.com上的Adventure Works多維數據集,請通過定義HTML <div>元素來創建小部件。
<!-- Define the HTML div that will hold the PivotGrid --> <div id="pivotgrid"> </div>
下面的示例演示如何進一步配置PivotGrid小部件。
<script> $(document).ready(function () { $("#pivotgrid").kendoPivotGrid({ height: 200, // Define the height of the widget. dataSource: { type: "xmla", // Define the type. columns: [{ name: "[Date].[Calendar]" }], // Specify a dimension on columns. rows: [{ name: "[Product].[Category]" }], // Specify a dimension on rows. measures: ["[Measures].[Internet Sales Amount]"], // Specify a measure to display. transport: { connection: { catalog: "Adventure Works DW 2008R2", // Specify the name of the catalog. cube: "Adventure Works" // Specify the name of the cube. }, read: { url: "http://demos.telerik.com/olap/msmdpump.dll", // Define the URL of the service. dataType: "text", contentType: "text/xml", type: "POST" } }, schema: { type: "xmla" // Specify the type of the schema. }, } }); }); </script>
前面的示例輸出以下結果。
要引用現有的PivotGrid實例,請使用jQuery.data()方法。 建立引用后,請使用PivotGrid API來控制其操作。
下面的示例演示如何訪問現有的PivotGrid實例。
var pivotgrid = $("#pivotgrid").data("kendoPivotGrid");
本站文章除注明轉載外,均為本站原創或翻譯。歡迎任何形式的轉載,但請務必注明出處、不得修改原文相關鏈接,如果存在內容上的異議請郵件反饋至chenjj@fc6vip.cn
文章轉載自:慧都網