├── src ├── images │ ├── img_data.png │ ├── login_bg.png │ └── login_box_bg.png ├── css │ ├── images │ │ ├── ice-asc.gif │ │ ├── ice-desc.gif │ │ ├── black-asc.gif │ │ ├── black-desc.gif │ │ ├── dropbox-asc.png │ │ ├── green-asc.gif │ │ ├── green-desc.gif │ │ ├── white-asc.gif │ │ ├── white-desc.gif │ │ ├── dropbox-desc.png │ │ ├── green-header.gif │ │ ├── ice-unsorted.gif │ │ ├── metro-loading.gif │ │ ├── black-unsorted.gif │ │ ├── dragtable-handle.png │ │ ├── green-unsorted.gif │ │ ├── metro-black-asc.png │ │ ├── metro-black-desc.png │ │ ├── metro-unsorted.png │ │ ├── metro-white-asc.png │ │ ├── metro-white-desc.png │ │ ├── white-unsorted.gif │ │ ├── dropbox-asc-hovered.png │ │ ├── dropbox-desc-hovered.png │ │ ├── bootstrap-black-unsorted.png │ │ ├── bootstrap-white-unsorted.png │ │ └── dragtable-handle.svg │ ├── ztree │ │ ├── img │ │ │ ├── diy │ │ │ │ ├── 2.png │ │ │ │ ├── 3.png │ │ │ │ ├── 4.png │ │ │ │ ├── 5.png │ │ │ │ ├── 6.png │ │ │ │ ├── 7.png │ │ │ │ ├── 8.png │ │ │ │ ├── 9.png │ │ │ │ ├── 1_open.png │ │ │ │ └── 1_close.png │ │ │ ├── loading.gif │ │ │ ├── line_conn.gif │ │ │ ├── zTreeStandard.gif │ │ │ └── zTreeStandard.png │ │ └── zTreeStyle.css │ ├── autoHimg │ │ └── arrow │ │ │ ├── arrow1_05301.gif │ │ │ ├── arrow1_05302.gif │ │ │ ├── arrow1_05303.gif │ │ │ ├── arrow1_05401.gif │ │ │ ├── arrow1_05402.gif │ │ │ ├── arrow1_05403.gif │ │ │ ├── arrow1_05501.gif │ │ │ ├── arrow1_05502.gif │ │ │ ├── arrow1_05503.gif │ │ │ ├── arrow1_05601.gif │ │ │ ├── arrow1_05602.gif │ │ │ ├── arrow1_05603.gif │ │ │ ├── arrow1_05701.gif │ │ │ ├── arrow1_05702.gif │ │ │ ├── arrow1_05703.gif │ │ │ ├── arrow1_05801.gif │ │ │ ├── arrow1_05802.gif │ │ │ └── arrow1_05803.gif │ ├── style.css │ ├── highLight.css │ ├── theme.bootstrap.css │ └── screen.css ├── fonts │ ├── glyphicons-halflings-regular.eot │ ├── glyphicons-halflings-regular.ttf │ ├── glyphicons-halflings-regular.woff │ └── glyphicons-halflings-regular.woff2 └── js │ ├── table2excel.js │ ├── exporting.js │ └── highcharts-3d.js ├── LICENSE ├── autoHeader.jquery.json ├── index.html ├── example ├── exampleList.html ├── base │ ├── simple.html │ ├── description.html │ ├── compare.html │ ├── avg.html │ ├── simple.js │ ├── description.js │ ├── compare.js │ └── avg.js └── extend │ ├── sort.html │ ├── export.html │ ├── chart.html │ ├── all.html │ ├── sort.js │ └── export.js └── h5lib ├── html5shiv.js └── respond.min.js /src/images/img_data.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/images/img_data.png -------------------------------------------------------------------------------- /src/images/login_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/images/login_bg.png -------------------------------------------------------------------------------- /src/css/images/ice-asc.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/ice-asc.gif -------------------------------------------------------------------------------- /src/css/images/ice-desc.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/ice-desc.gif -------------------------------------------------------------------------------- /src/css/ztree/img/diy/2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/diy/2.png -------------------------------------------------------------------------------- /src/css/ztree/img/diy/3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/diy/3.png -------------------------------------------------------------------------------- /src/css/ztree/img/diy/4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/diy/4.png -------------------------------------------------------------------------------- /src/css/ztree/img/diy/5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/diy/5.png -------------------------------------------------------------------------------- /src/css/ztree/img/diy/6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/diy/6.png -------------------------------------------------------------------------------- /src/css/ztree/img/diy/7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/diy/7.png -------------------------------------------------------------------------------- /src/css/ztree/img/diy/8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/diy/8.png -------------------------------------------------------------------------------- /src/css/ztree/img/diy/9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/diy/9.png -------------------------------------------------------------------------------- /src/images/login_box_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/images/login_box_bg.png -------------------------------------------------------------------------------- /src/css/images/black-asc.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/black-asc.gif -------------------------------------------------------------------------------- /src/css/images/black-desc.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/black-desc.gif -------------------------------------------------------------------------------- /src/css/images/dropbox-asc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/dropbox-asc.png -------------------------------------------------------------------------------- /src/css/images/green-asc.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/green-asc.gif -------------------------------------------------------------------------------- /src/css/images/green-desc.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/green-desc.gif -------------------------------------------------------------------------------- /src/css/images/white-asc.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/white-asc.gif -------------------------------------------------------------------------------- /src/css/images/white-desc.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/white-desc.gif -------------------------------------------------------------------------------- /src/css/ztree/img/loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/loading.gif -------------------------------------------------------------------------------- /src/css/images/dropbox-desc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/dropbox-desc.png -------------------------------------------------------------------------------- /src/css/images/green-header.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/green-header.gif -------------------------------------------------------------------------------- /src/css/images/ice-unsorted.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/ice-unsorted.gif -------------------------------------------------------------------------------- /src/css/images/metro-loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/metro-loading.gif -------------------------------------------------------------------------------- /src/css/ztree/img/diy/1_open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/diy/1_open.png -------------------------------------------------------------------------------- /src/css/ztree/img/line_conn.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/line_conn.gif -------------------------------------------------------------------------------- /src/css/images/black-unsorted.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/black-unsorted.gif -------------------------------------------------------------------------------- /src/css/images/dragtable-handle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/dragtable-handle.png -------------------------------------------------------------------------------- /src/css/images/green-unsorted.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/green-unsorted.gif -------------------------------------------------------------------------------- /src/css/images/metro-black-asc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/metro-black-asc.png -------------------------------------------------------------------------------- /src/css/images/metro-black-desc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/metro-black-desc.png -------------------------------------------------------------------------------- /src/css/images/metro-unsorted.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/metro-unsorted.png -------------------------------------------------------------------------------- /src/css/images/metro-white-asc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/metro-white-asc.png -------------------------------------------------------------------------------- /src/css/images/metro-white-desc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/metro-white-desc.png -------------------------------------------------------------------------------- /src/css/images/white-unsorted.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/white-unsorted.gif -------------------------------------------------------------------------------- /src/css/ztree/img/diy/1_close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/diy/1_close.png -------------------------------------------------------------------------------- /src/css/ztree/img/zTreeStandard.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/zTreeStandard.gif -------------------------------------------------------------------------------- /src/css/ztree/img/zTreeStandard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/ztree/img/zTreeStandard.png -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05301.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05301.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05302.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05302.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05303.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05303.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05401.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05401.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05402.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05402.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05403.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05403.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05501.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05501.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05502.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05502.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05503.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05503.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05601.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05601.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05602.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05602.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05603.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05603.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05701.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05701.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05702.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05702.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05703.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05703.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05801.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05801.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05802.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05802.gif -------------------------------------------------------------------------------- /src/css/autoHimg/arrow/arrow1_05803.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/autoHimg/arrow/arrow1_05803.gif -------------------------------------------------------------------------------- /src/css/images/dropbox-asc-hovered.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/dropbox-asc-hovered.png -------------------------------------------------------------------------------- /src/css/images/dropbox-desc-hovered.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/dropbox-desc-hovered.png -------------------------------------------------------------------------------- /src/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /src/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /src/css/images/bootstrap-black-unsorted.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/bootstrap-black-unsorted.png -------------------------------------------------------------------------------- /src/css/images/bootstrap-white-unsorted.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/css/images/bootstrap-white-unsorted.png -------------------------------------------------------------------------------- /src/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /src/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finira/autoHeader/HEAD/src/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /src/css/images/dragtable-handle.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2016 finira 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy of 6 | this software and associated documentation files (the "Software"), to deal in 7 | the Software without restriction, including without limitation the rights to 8 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of 9 | the Software, and to permit persons to whom the Software is furnished to do so, 10 | subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 17 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 18 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 19 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 20 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | -------------------------------------------------------------------------------- /autoHeader.jquery.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "autoHeader", 3 | "title": "AutoHeader", 4 | "description": "一个用于生成多层复杂表头的jquery插件,可以进行表头和数据的动态生成,动态筛选以及一定的统计分析功能 --Generate table with complex and multi meter header,with some analytical approach", 5 | "keywords": [ 6 | "complex", 7 | "multi", 8 | "meter", 9 | "header", 10 | "analysis" 11 | ], 12 | "version": "1.1.0", 13 | "author": { 14 | "name": "finira", 15 | "email": "finira@qq.com", 16 | "url": "https://github.com/finira" 17 | }, 18 | "maintainers": [ 19 | { 20 | "name": "finira", 21 | "email": "finira@qq.com", 22 | "url": "https://github.com/finira" 23 | } 24 | ], 25 | "licenses": [ 26 | { 27 | "type": "MIT", 28 | "url": "https://github.com/jquery/jquery-color/blob/2.1.2/MIT-LICENSE.txt" 29 | } 30 | ], 31 | "bugs": "https://github.com/finira/autoHeader/issues", 32 | "homepage": "https://github.com/finira/autoHeader/", 33 | "docs": "https://github.com/finira/autoHeader/", 34 | "demo":"https://github.com/finira/autoHeader/", 35 | "download": "https://github.com/finira/autoHeader/", 36 | "dependencies": { 37 | "jquery": ">=1.6" 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /src/css/style.css: -------------------------------------------------------------------------------- 1 | /*展示表格格式*/ 2 | #tabled {text-align:center;} 3 | #tabled caption{} 4 | #tabled th{padding:3px 3px 3px 3px;text-align:center; word-break: normal;cursor: pointer;vertical-align:middle;} 5 | #tabled td{padding:5px 35px 5px 35px;text-align:center;white-space:nowrap;} 6 | 7 | /*统计表格格式*/ 8 | #tabledcnt {text-align:center; width:100%} 9 | #tabledcnt caption{} 10 | #tabledcnt th{padding:5px;text-align:center; word-break: normal;} 11 | #tabledcnt td{padding:5px 10px 5px 10px;text-align:center;white-space:nowrap;cursor:pointer;} 12 | 13 | .backtolist{float: right;cursor: pointer;} 14 | 15 | /*统计级别格式*/ 16 | .lever1{background: #f2ff70;} 17 | .lever2{background: #ffac9f;} 18 | 19 | /*容器格式*/ 20 | #containdiv {height:510px;overflow-x: auto;overFlow-y: auto ;} 21 | #containdivcnt {height:190px;overflow: auto;display: none;} 22 | 23 | /*表头描述的双层容器*/ 24 | .descdivdefault_out{ height: auto !important;height:300px;min-height:300px;padding:10px;position:absolute;display:none} 25 | .descdivdefault_in { background: #d8f8c5;height:100%;overflow:auto;width:300px; position:absolute;color:#3b3b3b;border-radius: 5px; filter:alpha(Opacity=60);-moz-opacity:0.95;opacity: 0.95;position:absolute} 26 | .descdivdefault_in .close{float:right;cursor:pointer; color:#fff;margin:0px;} 27 | .descdivdefault_in .content{padding:10px;text-indent:2em; line-height:1.5; padding-bottom:1em;font-size:12px;} 28 | .descdivdefault_in .ttitle{height:30px;background:#6fce37;color:#fff;line-height:30px;padding:0 10px;font-size:14px;} 29 | 30 | /*最大最小平均值比较图标格式*/ 31 | .moreThanSpan { background : url("autoHimg/arrow/arrow1_05401.gif") no-repeat; width:13px; height:13px;display:inline-block;} 32 | .lessThanSpan { background: url("autoHimg/arrow/arrow1_05602.gif") no-repeat; width:13px; height:13px;display:inline-block;} 33 | .equalToSpan { background: url("autoHimg/arrow/arrow1_05303.gif") no-repeat; width:15px; height:13px;display:inline-block;} 34 | -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | autoHeader用例列表 6 | 7 | 11 | 12 | 13 | 14 | 15 |
16 | 17 |
18 |
19 |
20 |

用例列表

21 |
22 |
23 | 24 | 45 |
46 |
47 | 48 |
49 | 50 | 51 | 52 |
53 | 54 | 55 | 56 | 57 | -------------------------------------------------------------------------------- /example/exampleList.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | autoHeader用例列表 6 | 7 | 11 | 12 | 13 | 14 | 15 |
16 | 17 |
18 |
19 |
20 |

用例列表

21 |
22 | 46 |
47 | 48 |
49 | 50 | 51 | 52 |
53 | 54 | 55 | 56 | 57 | -------------------------------------------------------------------------------- /h5lib/html5shiv.js: -------------------------------------------------------------------------------- 1 | /* 2 | HTML5 Shiv v3.7.0 | @afarkas @jdalton @jon_neal @rem | MIT/GPL2 Licensed 3 | */ 4 | (function(l,f){function m(){var a=e.elements;return"string"==typeof a?a.split(" "):a}function i(a){var b=n[a[o]];b||(b={},h++,a[o]=h,n[h]=b);return b}function p(a,b,c){b||(b=f);if(g)return b.createElement(a);c||(c=i(b));b=c.cache[a]?c.cache[a].cloneNode():r.test(a)?(c.cache[a]=c.createElem(a)).cloneNode():c.createElem(a);return b.canHaveChildren&&!s.test(a)?c.frag.appendChild(b):b}function t(a,b){if(!b.cache)b.cache={},b.createElem=a.createElement,b.createFrag=a.createDocumentFragment,b.frag=b.createFrag(); 5 | a.createElement=function(c){return!e.shivMethods?b.createElem(c):p(c,a,b)};a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+m().join().replace(/[\w\-]+/g,function(a){b.createElem(a);b.frag.createElement(a);return'c("'+a+'")'})+");return n}")(e,b.frag)}function q(a){a||(a=f);var b=i(a);if(e.shivCSS&&!j&&!b.hasCSS){var c,d=a;c=d.createElement("p");d=d.getElementsByTagName("head")[0]||d.documentElement;c.innerHTML="x"; 6 | c=d.insertBefore(c.lastChild,d.firstChild);b.hasCSS=!!c}g||t(a,b);return a}var k=l.html5||{},s=/^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i,r=/^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i,j,o="_html5shiv",h=0,n={},g;(function(){try{var a=f.createElement("a");a.innerHTML="";j="hidden"in a;var b;if(!(b=1==a.childNodes.length)){f.createElement("a");var c=f.createDocumentFragment();b="undefined"==typeof c.cloneNode|| 7 | "undefined"==typeof c.createDocumentFragment||"undefined"==typeof c.createElement}g=b}catch(d){g=j=!0}})();var e={elements:k.elements||"abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output progress section summary template time video",version:"3.7.0",shivCSS:!1!==k.shivCSS,supportsUnknownElements:g,shivMethods:!1!==k.shivMethods,type:"default",shivDocument:q,createElement:p,createDocumentFragment:function(a,b){a||(a=f); 8 | if(g)return a.createDocumentFragment();for(var b=b||i(a),c=b.frag.cloneNode(),d=0,e=m(),h=e.length;d tr:hover > td, /* override tablesorter theme row hover */ 36 | table.hover-highlight tbody > tr.odd:hover > td, 37 | table.hover-highlight tbody > tr.even:hover > td { 38 | background-color: #ffa; 39 | } 40 | /* HOVER COLUMN highlight colors */ 41 | .hover-highlight tbody tr td:hover::after, 42 | .hover-highlight tbody tr th:hover::after { 43 | background-color: #ffa; 44 | } 45 | 46 | /* ************************************************* */ 47 | /* **** No need to modify the definitions below **** */ 48 | /* ************************************************* */ 49 | .focus-highlight td:focus::after, .focus-highlight th:focus::after, 50 | .hover-highlight td:hover::after, .hover-highlight th:hover::after { 51 | content: ''; 52 | position: absolute; 53 | width: 100%; 54 | height: 999em; 55 | left: 0; 56 | top: -555em; 57 | z-index: -1; 58 | } 59 | .focus-highlight td:focus::before, .focus-highlight th:focus::before { 60 | content: ''; 61 | position: absolute; 62 | width: 999em; 63 | height: 100%; 64 | left: -555em; 65 | top: 0; 66 | z-index: -2; 67 | } 68 | /* required styles */ 69 | .hover-highlight, 70 | .focus-highlight { 71 | overflow: hidden; 72 | } 73 | .hover-highlight td, .hover-highlight th, 74 | .focus-highlight td, .focus-highlight th { 75 | position: relative; 76 | outline: 0; 77 | } 78 | /* override the tablesorter theme styling */ 79 | table.hover-highlight, table.hover-highlight tbody > tr > td, 80 | table.focus-highlight, table.focus-highlight tbody > tr > td, 81 | /* override zebra styling */ 82 | table.hover-highlight tbody tr.even > th, 83 | table.hover-highlight tbody tr.even > td, 84 | table.hover-highlight tbody tr.odd > th, 85 | table.hover-highlight tbody tr.odd > td, 86 | table.focus-highlight tbody tr.even > th, 87 | table.focus-highlight tbody tr.even > td, 88 | table.focus-highlight tbody tr.odd > th, 89 | table.focus-highlight tbody tr.odd > td { 90 | background: transparent; 91 | } 92 | /* table background positioned under the highlight */ 93 | table.hover-highlight td:before, 94 | table.focus-highlight td:before { 95 | content: ''; 96 | position: absolute; 97 | width: 100%; 98 | height: 100%; 99 | left: 0; 100 | top: 0; 101 | z-index: -3; 102 | } -------------------------------------------------------------------------------- /h5lib/respond.min.js: -------------------------------------------------------------------------------- 1 | /*! matchMedia() polyfill - Test a CSS media type/query in JS. Authors & copyright (c) 2012: Scott Jehl, Paul Irish, Nicholas Zakas. Dual MIT/BSD license */ 2 | /*! NOTE: If you're already including a window.matchMedia polyfill via Modernizr or otherwise, you don't need this part */ 3 | window.matchMedia=window.matchMedia||function(a){"use strict";var c,d=a.documentElement,e=d.firstElementChild||d.firstChild,f=a.createElement("body"),g=a.createElement("div");return g.id="mq-test-1",g.style.cssText="position:absolute;top:-100em",f.style.background="none",f.appendChild(g),function(a){return g.innerHTML='­',d.insertBefore(f,e),c=42===g.offsetWidth,d.removeChild(f),{matches:c,media:a}}}(document); 4 | 5 | /*! Respond.js v1.3.0: min/max-width media query polyfill. (c) Scott Jehl. MIT/GPLv2 Lic. j.mp/respondjs */ 6 | (function(a){"use strict";function x(){u(!0)}var b={};if(a.respond=b,b.update=function(){},b.mediaQueriesSupported=a.matchMedia&&a.matchMedia("only all").matches,!b.mediaQueriesSupported){var q,r,t,c=a.document,d=c.documentElement,e=[],f=[],g=[],h={},i=30,j=c.getElementsByTagName("head")[0]||d,k=c.getElementsByTagName("gov")[0],l=j.getElementsByTagName("link"),m=[],n=function(){for(var b=0;l.length>b;b++){var c=l[b],d=c.href,e=c.media,f=c.rel&&"stylesheet"===c.rel.toLowerCase();d&&f&&!h[d]&&(c.styleSheet&&c.styleSheet.rawCssText?(p(c.styleSheet.rawCssText,d,e),h[d]=!0):(!/^([a-zA-Z:]*\/\/)/.test(d)&&!k||d.replace(RegExp.$1,"").split("/")[0]===a.location.host)&&m.push({href:d,media:e}))}o()},o=function(){if(m.length){var b=m.shift();v(b.href,function(c){p(c,b.href,b.media),h[b.href]=!0,a.setTimeout(function(){o()},0)})}},p=function(a,b,c){var d=a.match(/@media[^\{]+\{([^\{\}]*\{[^\}\{]*\})+/gi),g=d&&d.length||0;b=b.substring(0,b.lastIndexOf("/"));var h=function(a){return a.replace(/(url\()['"]?([^\/\)'"][^:\)'"]+)['"]?(\))/g,"$1"+b+"$2$3")},i=!g&&c;b.length&&(b+="/"),i&&(g=1);for(var j=0;g>j;j++){var k,l,m,n;i?(k=c,f.push(h(a))):(k=d[j].match(/@media *([^\{]+)\{([\S\s]+?)$/)&&RegExp.$1,f.push(RegExp.$2&&h(RegExp.$2))),m=k.split(","),n=m.length;for(var o=0;n>o;o++)l=m[o],e.push({media:l.split("(")[0].match(/(only\s+)?([a-zA-Z]+)\s?/)&&RegExp.$2||"all",rules:f.length-1,hasquery:l.indexOf("(")>-1,minw:l.match(/\(\s*min\-width\s*:\s*(\s*[0-9\.]+)(px|em)\s*\)/)&&parseFloat(RegExp.$1)+(RegExp.$2||""),maxw:l.match(/\(\s*max\-width\s*:\s*(\s*[0-9\.]+)(px|em)\s*\)/)&&parseFloat(RegExp.$1)+(RegExp.$2||"")})}u()},s=function(){var a,b=c.createElement("div"),e=c.body,f=!1;return b.style.cssText="position:absolute;font-size:1em;width:1em",e||(e=f=c.createElement("body"),e.style.background="none"),e.appendChild(b),d.insertBefore(e,d.firstChild),a=b.offsetWidth,f?d.removeChild(e):e.removeChild(b),a=t=parseFloat(a)},u=function(b){var h="clientWidth",k=d[h],m="CSS1Compat"===c.compatMode&&k||c.body[h]||k,n={},o=l[l.length-1],p=(new Date).getTime();if(b&&q&&i>p-q)return a.clearTimeout(r),r=a.setTimeout(u,i),void 0;q=p;for(var v in e)if(e.hasOwnProperty(v)){var w=e[v],x=w.minw,y=w.maxw,z=null===x,A=null===y,B="em";x&&(x=parseFloat(x)*(x.indexOf(B)>-1?t||s():1)),y&&(y=parseFloat(y)*(y.indexOf(B)>-1?t||s():1)),w.hasquery&&(z&&A||!(z||m>=x)||!(A||y>=m))||(n[w.media]||(n[w.media]=[]),n[w.media].push(f[w.rules]))}for(var C in g)g.hasOwnProperty(C)&&g[C]&&g[C].parentNode===j&&j.removeChild(g[C]);for(var D in n)if(n.hasOwnProperty(D)){var E=c.createElement("style"),F=n[D].join("\n");E.type="text/css",E.media=D,j.insertBefore(E,o.nextSibling),E.styleSheet?E.styleSheet.cssText=F:E.appendChild(c.createTextNode(F)),g.push(E)}},v=function(a,b){var c=w();c&&(c.open("GET",a,!0),c.onreadystatechange=function(){4!==c.readyState||200!==c.status&&304!==c.status||b(c.responseText)},4!==c.readyState&&c.send(null))},w=function(){var b=!1;try{b=new a.XMLHttpRequest}catch(c){b=new a.ActiveXObject("Microsoft.XMLHTTP")}return function(){return b}}();n(),b.update=n,a.addEventListener?a.addEventListener("resize",x,!1):a.attachEvent&&a.attachEvent("onresize",x)}})(this); 7 | -------------------------------------------------------------------------------- /example/base/simple.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 基础展示应用-书写表头和数据 6 | 7 | 11 | 12 | 13 | 14 | 15 | 16 | 17 |
18 |
19 |
20 |
21 |

结果中筛选

22 |
23 |
24 |
    25 |
    26 |
    27 |
    28 |
    29 |

    范例

    30 |
    31 |
    32 |

    返回范例列表

    33 |
    34 |
    35 | 36 | 37 | 38 | 39 | 40 |
    41 | 42 |
    43 |
    44 |
    45 |

    基础展示应用-书写表头和数据

    46 |
    47 |
    48 | 49 |
    50 | 53 |
      54 |
    • 使用说明:
    • 55 |
    • 点击"选择表头"按钮可以在树状态下进行表头的选择
    • 56 |
    • "结果中筛选"里,可以在树状态下进行结果集的选择
    • 57 |
    • 点击"筛选"按钮可以按照表头和结果集的选择进行数据筛选显示
    • 58 |
    59 |
    60 |
    61 |
    62 | 104 |
    105 | 106 | 107 | 108 |
    109 | 110 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | -------------------------------------------------------------------------------- /example/base/description.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 基础展示应用-表头描述 6 | 7 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 |
    19 |
    20 |
    21 |
    22 |

    结果中筛选

    23 |
    24 |
    25 |
      26 |
      27 |
      28 | 29 |
      30 |
      31 |

      范例

      32 |
      33 |
      34 |

      返回范例列表

      35 |
      36 |
      37 | 38 | 39 | 40 | 41 |
      42 | 43 |
      44 |
      45 |
      46 |

      基础展示应用-表头描述

      47 |
      48 |
      49 | 50 |
      51 | 54 |
        55 |
      • 使用说明:
      • 56 |
      • 页面包含基础书写展示功能
      • 57 |
      • 点击表头,如果表头配置了描述属性,则表头描述框会显示
      • 58 |
      • 描述可以选择div或者span模式,div模式的描述属性支持html标签,div的css也可自定义
      • 59 |
      • 表头描述默认使用click事件触发,与排序功能的默认触发事件冲突,如需同时使用,还需重定义两者的触发事件
      • 60 |
      • "综合总分"表头配置了带p标签的描述,其他表头配置了普通描述信息
      • 61 |
      62 |
      63 |
      64 |
      65 | 107 |
      108 | 109 | 110 | 111 |
      112 | 113 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | -------------------------------------------------------------------------------- /example/extend/sort.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 扩展使用-排序 6 | 7 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 |
      19 |
      20 |
      21 |
      22 |

      结果中筛选

      23 |
      24 |
      25 |
        26 |
        27 |
        28 | 29 |
        30 |
        31 |

        范例

        32 |
        33 |
        34 |

        返回范例列表

        35 |
        36 |
        37 | 38 | 39 | 40 | 41 |
        42 | 43 |
        44 |
        45 |
        46 |

        扩展使用-排序

        47 |
        48 |
        49 | 50 |
        51 | 54 |
          55 |
        • 使用说明:
        • 56 |
        • 页面包含基础书写展示功能
        • 57 |
        • 集成tablesorter插件,点击表头即可进行排序
        • 58 |
        • 本插件扩展的行序列号功能可以参看具体功能说明,默认为开启且正序排列状态
        • 59 |
        • 默认使用click事件触发,与表头描述的默认触发事件冲突,如需同时使用,还需重定义两者的触发事件
        • 60 |
        61 |
        62 |
        63 |
        64 | 106 |
        107 | 108 | 109 | 110 |
        111 | 112 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | 127 | -------------------------------------------------------------------------------- /example/extend/export.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 扩展使用-表格数据导出 6 | 7 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 |
        19 |
        20 |
        21 |
        22 |

        结果中筛选

        23 |
        24 |
        25 |
          26 |
          27 |
          28 | 29 |
          30 |
          31 |

          范例

          32 |
          33 |
          34 |

          返回范例列表

          35 |
          36 |
          37 | 38 | 39 | 40 | 41 |
          42 | 43 |
          44 |
          45 |
          46 |

          扩展使用-表格数据导出

          47 |
          48 |
          49 | 50 |
          51 | 54 |
            55 |
          • 使用说明:
          • 56 |
          • 页面包含基础书写展示功能
          • 57 |
          • 集成table2excel插件,点击"导出Excel"便可将整个表格导出为excel
          • 58 |
          59 |
          60 |
          61 |
          62 | 107 |
          108 | 109 | 110 | 111 |
          112 | 113 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | 127 | -------------------------------------------------------------------------------- /example/base/compare.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 基础展示应用-预设值比对 6 | 7 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 |
          19 |
          20 |
          21 |
          22 |

          结果中筛选

          23 |
          24 |
          25 |
            26 |
            27 |
            28 | 29 |
            30 |
            31 |

            范例

            32 |
            33 |
            34 |

            返回范例列表

            35 |
            36 |
            37 | 38 | 39 | 40 | 41 |
            42 | 43 |
            44 |
            45 |
            46 |

            基础展示应用-预设值比对

            47 |
            48 |
            49 | 50 |
            51 | 54 |
              55 |
            • 使用说明:
            • 56 |
            • 页面包含基础书写展示功能
            • 57 |
            • 点击"比对预设值"可以进行数据与预设值的比对结果
            • 58 |
            • 预设值可以是指定的数值,也可以是表格中的其他字段,比对公式支持基础运算符
            • 59 |
            • 比对公式设置可以参看说明文档
            • 60 |
            • 比对之后,总体比对结果会显示在最前方
            • 61 |
            • 比对之后,满足比对公式的单元格数据会对应覆盖相应的颜色,颜色可通过css自定义
            • 62 |
            • 点击总体结果中大于0的数字,表格将会自动筛选显示对应满足比对条件的表头(以及被比较的表头)和数据
            • 63 |
            • 本示例中的比对规则设置为:综合总分<95为警告;语文<90为不合格;体育考试分数小于体能测试为不合格
            • 64 |
            65 |
            66 |
            67 |
            68 | 113 |
            114 | 115 | 116 | 117 |
            118 | 119 | 123 | 124 | 125 | 126 | 127 | 128 | 129 | 130 | 131 | 132 | -------------------------------------------------------------------------------- /example/base/avg.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 基础展示应用-平均值/最大值/最小值/合计值 6 | 7 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 |
            19 |
            20 |
            21 |
            22 |

            结果中筛选

            23 |
            24 |
            25 |
              26 |
              27 |
              28 | 29 |
              30 |
              31 |

              范例

              32 |
              33 |
              34 |

              返回范例列表

              35 |
              36 |
              37 | 38 | 39 | 40 | 41 |
              42 | 43 |
              44 |
              45 |
              46 |

              基础展示应用-平均值/最大值/最小值/合计值

              47 |
              48 |
              49 | 50 |
              51 | 54 |
                55 |
              • 使用说明:
              • 56 |
              • 页面包含基础书写展示功能
              • 57 |
              • 点击"平均值/最大值/最小值/合计值"对应的按钮可以进行对应值的展示
              • 58 |
              • 平均值功能可以显示每个单元格数据与平均值的对比结果,结果以向上向下箭头图标展示,图标可自定义
              • 59 |
              • 最大值/最小值功能可以显示单元格数据与最大值/最小值相同的结果,以向右箭头图标展示,图标可自定义
              • 60 |
              61 |
              62 |
              63 |
              64 | 111 |
              112 | 113 | 114 | 115 |
              116 | 117 | 121 | 122 | 123 | 124 | 125 | 126 | 127 | 128 | 129 | 130 | -------------------------------------------------------------------------------- /src/js/table2excel.js: -------------------------------------------------------------------------------- 1 | //table2excel.js 2 | ;(function ( $, window, document, undefined ) { 3 | var pluginName = "table2excel", 4 | 5 | defaults = { 6 | exclude: ".noExl", 7 | name: "Table2Excel" 8 | }; 9 | 10 | // The actual plugin constructor 11 | function Plugin ( element, options ) { 12 | this.element = element; 13 | // jQuery has an extend method which merges the contents of two or 14 | // more objects, storing the result in the first object. The first object 15 | // is generally empty as we don't want to alter the default options for 16 | // future instances of the plugin 17 | // 18 | this.settings = $.extend( {}, defaults, options ); 19 | this._defaults = defaults; 20 | this._name = pluginName; 21 | this.init(); 22 | } 23 | 24 | Plugin.prototype = { 25 | init: function () { 26 | var e = this; 27 | 28 | e.template = { 29 | head: "", 35 | table: { 36 | head: "", 37 | tail: "
              " 38 | }, 39 | foot: "" 40 | }; 41 | 42 | e.tableRows = []; 43 | 44 | // get contents of table except for exclude 45 | $(e.element).each( function(i,o) { 46 | var tempRows = ""; 47 | $(o).find("tr").not(e.settings.exclude).each(function (i,o) { 48 | tempRows += "" + $(o).html() + ""; 49 | }); 50 | e.tableRows.push(tempRows); 51 | }); 52 | 53 | e.tableToExcel(e.tableRows, e.settings.name); 54 | }, 55 | 56 | tableToExcel: function (table, name) { 57 | var e = this, fullTemplate="", i, link, a; 58 | 59 | e.uri = "data:application/vnd.ms-excel;base64,"; 60 | e.base64 = function (s) { 61 | return window.btoa(unescape(encodeURIComponent(s))); 62 | }; 63 | e.format = function (s, c) { 64 | return s.replace(/{(\w+)}/g, function (m, p) { 65 | return c[p]; 66 | }); 67 | }; 68 | e.ctx = { 69 | worksheet: name || "Worksheet", 70 | table: table 71 | }; 72 | 73 | fullTemplate= e.template.head; 74 | 75 | if ( $.isArray(table) ) { 76 | for (i in table) { 77 | //fullTemplate += e.template.sheet.head + "{worksheet" + i + "}" + e.template.sheet.tail; 78 | fullTemplate += e.template.sheet.head + "Table" + i + "" + e.template.sheet.tail; 79 | } 80 | } 81 | 82 | fullTemplate += e.template.mid; 83 | 84 | if ( $.isArray(table) ) { 85 | for (i in table) { 86 | fullTemplate += e.template.table.head + "{table" + i + "}" + e.template.table.tail; 87 | } 88 | } 89 | 90 | fullTemplate += e.template.foot; 91 | 92 | for (i in table) { 93 | e.ctx["table" + i] = table[i]; 94 | } 95 | delete e.ctx.table; 96 | 97 | if (typeof msie !== "undefined" && msie > 0 || !!navigator.userAgent.match(/Trident.*rv\:11\./)) // If Internet Explorer 98 | { 99 | if (typeof Blob !== "undefined") { 100 | //use blobs if we can 101 | fullTemplate = [fullTemplate]; 102 | //convert to array 103 | var blob1 = new Blob(fullTemplate, { type: "text/html" }); 104 | window.navigator.msSaveBlob(blob1, getFileName(e.settings) ); 105 | } else { 106 | //otherwise use the iframe and save 107 | //requires a blank iframe on page called txtArea1 108 | txtArea1.document.open("text/html", "replace"); 109 | txtArea1.document.write(e.format(fullTemplate, e.ctx)); 110 | txtArea1.document.close(); 111 | txtArea1.focus(); 112 | sa = txtArea1.document.execCommand("SaveAs", true, getFileName(e.settings) ); 113 | } 114 | 115 | } else { 116 | link = e.uri + e.base64(e.format(fullTemplate, e.ctx)); 117 | a = document.createElement("a"); 118 | a.download = getFileName(e.settings); 119 | a.href = link; 120 | 121 | document.body.appendChild(a); 122 | 123 | a.click(); 124 | 125 | document.body.removeChild(a); 126 | } 127 | 128 | return true; 129 | } 130 | }; 131 | 132 | function getFileName(settings) { 133 | return ( settings.filename ? settings.filename : "table2excel") + ".xls"; 134 | } 135 | 136 | $.fn[ pluginName ] = function ( options ) { 137 | var e = this; 138 | e.each(function() { 139 | if ( !$.data( e, "plugin_" + pluginName ) ) { 140 | $.data( e, "plugin_" + pluginName, new Plugin( this, options ) ); 141 | } 142 | }); 143 | 144 | // chain jQuery functions 145 | return e; 146 | }; 147 | 148 | })( jQuery, window, document ); -------------------------------------------------------------------------------- /example/extend/chart.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 扩展使用-图表 6 | 7 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 |
              19 |
              20 |
              21 |
              22 |

              结果中筛选

              23 |
              24 |
              25 |
                26 |
                27 |
                28 | 29 |
                30 |
                31 |

                范例

                32 |
                33 |
                34 |

                返回范例列表

                35 |
                36 |
                37 | 38 | 39 | 40 | 41 |
                42 | 43 |
                44 |
                45 |
                46 |

                扩展使用-图表

                47 |
                48 |
                49 | 50 |
                51 | 54 |
                  55 |
                • 使用说明:
                • 56 |
                • 页面包含基础书写展示功能
                • 57 |
                • 集成highcharts插件进行图表的展示和导出
                • 58 |
                • 点击对应的图表按钮即可参看图表生成结果
                • 59 |
                • 页面针对不同类型,对表头数量进行了限制,饼状图必须只选一个表头(维度),其他为十个,此数量由具体应用决定
                • 60 |
                61 |
                62 |
                63 |
                64 | 112 |
                113 | 114 | 115 | 116 |
                117 | 118 | 122 | 123 | 124 | 125 | 126 | 127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | -------------------------------------------------------------------------------- /src/css/theme.bootstrap.css: -------------------------------------------------------------------------------- 1 | /************* 2 | Bootstrap theme 3 | *************/ 4 | /* jQuery Bootstrap Theme */ 5 | .tablesorter-bootstrap { 6 | width: 100%; 7 | } 8 | .tablesorter-bootstrap thead th{padding:3px;text-align:center; word-break: normal;} 9 | .tablesorter-bootstrap thead td, 10 | .tablesorter-bootstrap tfoot th, 11 | .tablesorter-bootstrap tfoot td { 12 | font: 14px/20px Arial, Sans-serif; 13 | font-weight: bold; 14 | padding: 4px; 15 | margin: 0 0 18px; 16 | } 17 | 18 | .tablesorter-bootstrap .sorter-false { 19 | cursor: default; 20 | } 21 | 22 | .tablesorter-bootstrap .tablesorter-header-inner { 23 | position: relative; 24 | } 25 | 26 | /* bootstrap uses for icons */ 27 | .tablesorter-bootstrap .tablesorter-header i.tablesorter-icon { 28 | font-size: 11px; 29 | /*position: absolute;*/ 30 | right: 2px; 31 | top: 50%; 32 | margin-top: -7px; /* half the icon height; older IE doesn't like this */ 33 | width: 14px; 34 | height: 14px; 35 | background-repeat: no-repeat; 36 | line-height: 14px; 37 | display: inline-block; 38 | } 39 | 40 | /* black unsorted icon */ 41 | .tablesorter-bootstrap .bootstrap-icon-unsorted { 42 | background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAOCAMAAADOvxanAAAAVFBMVEUAAABCQkJZWVkZGRnJyckgICAZGRkZGRn8/PweHh4dHR0aGhoaGhpUVFQbGxvQ0NDc3NxMTExSUlIbGxvr6+s4ODhKSkogICAtLS00NDQzMzMnJydSEPrQAAAAGHRSTlMA1ssZRLgdAQbDyisqsZo8QdXUq0r9xPepSRwiAAAAX0lEQVQI13XHSQKAIAwEwQAKxn13Ev7/T2Pu9qmarJKPXIicI4PH4hxaKNrhm2S8bJK5h4YzKHrzJNtK6yYT/TdXzpS5zuYg4MSQYF6i4IHExdw1UVRi05HPrrvT53a+qyMFC9t04gcAAAAASUVORK5CYII=); 43 | } 44 | 45 | /* white unsorted icon */ 46 | .tablesorter-bootstrap .icon-white.bootstrap-icon-unsorted { 47 | background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAOBAMAAAALT/umAAAAKlBMVEUAAAD///////////////////////////////////////////////////+Gu8ovAAAADXRSTlMA4EXKBtQqvR0+sxmalc142gAAAFdJREFUCNdjYGDoamAAAjZbMxCVfvd6AgMDd+3du9UMDKx3hWSvMjBwXZww8RYDGuC53NB8h4GB8a617UUGBs7Yu3cjGRhYVO9eVQFKOskKOQApFmUgBwBZ+xXRTttNdAAAAABJRU5ErkJggg==); 48 | } 49 | 50 | /* since bootstrap (table-striped) uses nth-child(), we just use this to add a zebra stripe color */ 51 | .tablesorter-bootstrap > tbody > tr.odd > td, 52 | .tablesorter-bootstrap > tbody > tr.tablesorter-hasChildRow.odd:hover ~ tr.tablesorter-hasChildRow.odd ~ .tablesorter-childRow.odd > td { 53 | background-color: #f9f9f9; 54 | } 55 | .tablesorter-bootstrap > tbody > tr.hover > td, 56 | .tablesorter-bootstrap > tbody > tr.odd:hover > td, 57 | .tablesorter-bootstrap > tbody > tr.even:hover > td, 58 | .tablesorter-bootstrap > tbody > tr.tablesorter-hasChildRow.odd:hover ~ .tablesorter-childRow.odd > td, 59 | .tablesorter-bootstrap > tbody > tr.tablesorter-hasChildRow.even:hover ~ .tablesorter-childRow.even > td { 60 | background-color: #f5f5f5; 61 | } 62 | .tablesorter-bootstrap > tbody > tr.even > td, 63 | .tablesorter-bootstrap > tbody > tr.tablesorter-hasChildRow.even:hover ~ tr.tablesorter-hasChildRow.even ~ .tablesorter-childRow.even > td { 64 | background-color: #fff; 65 | } 66 | 67 | /* processing icon */ 68 | .tablesorter-bootstrap .tablesorter-processing { 69 | background-image: url('data:image/gif;base64,R0lGODlhFAAUAKEAAO7u7lpaWgAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh+QQBCgACACwAAAAAFAAUAAACQZRvoIDtu1wLQUAlqKTVxqwhXIiBnDg6Y4eyx4lKW5XK7wrLeK3vbq8J2W4T4e1nMhpWrZCTt3xKZ8kgsggdJmUFACH5BAEKAAIALAcAAAALAAcAAAIUVB6ii7jajgCAuUmtovxtXnmdUAAAIfkEAQoAAgAsDQACAAcACwAAAhRUIpmHy/3gUVQAQO9NetuugCFWAAAh+QQBCgACACwNAAcABwALAAACE5QVcZjKbVo6ck2AF95m5/6BSwEAIfkEAQoAAgAsBwANAAsABwAAAhOUH3kr6QaAcSrGWe1VQl+mMUIBACH5BAEKAAIALAIADQALAAcAAAIUlICmh7ncTAgqijkruDiv7n2YUAAAIfkEAQoAAgAsAAAHAAcACwAAAhQUIGmHyedehIoqFXLKfPOAaZdWAAAh+QQFCgACACwAAAIABwALAAACFJQFcJiXb15zLYRl7cla8OtlGGgUADs='); 70 | background-position: center center !important; 71 | background-repeat: no-repeat !important; 72 | } 73 | 74 | /* caption */ 75 | .caption { 76 | background-color: #fff; 77 | } 78 | 79 | /* filter widget */ 80 | .tablesorter-bootstrap .tablesorter-filter-row input.tablesorter-filter, 81 | .tablesorter-bootstrap .tablesorter-filter-row select.tablesorter-filter { 82 | width: 98%; 83 | margin: 0; 84 | padding: 4px 6px; 85 | color: #333; 86 | -webkit-box-sizing: border-box; 87 | -moz-box-sizing: border-box; 88 | box-sizing: border-box; 89 | -webkit-transition: height 0.1s ease; 90 | -moz-transition: height 0.1s ease; 91 | -o-transition: height 0.1s ease; 92 | transition: height 0.1s ease; 93 | } 94 | .tablesorter-bootstrap .tablesorter-filter-row .tablesorter-filter.disabled { 95 | background-color: #eee; 96 | color: #555; 97 | cursor: not-allowed; 98 | border: 1px solid #ccc; 99 | border-radius: 4px; 100 | box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.075) inset; 101 | box-sizing: border-box; 102 | transition: height 0.1s ease; 103 | } 104 | .tablesorter-bootstrap .tablesorter-filter-row { 105 | background-color: #efefef; 106 | } 107 | .tablesorter-bootstrap .tablesorter-filter-row td { 108 | background-color: #efefef; 109 | line-height: normal; 110 | text-align: center; 111 | padding: 4px 6px; 112 | vertical-align: middle; 113 | -webkit-transition: line-height 0.1s ease; 114 | -moz-transition: line-height 0.1s ease; 115 | -o-transition: line-height 0.1s ease; 116 | transition: line-height 0.1s ease; 117 | } 118 | /* hidden filter row */ 119 | .tablesorter-bootstrap .tablesorter-filter-row.hideme td { 120 | padding: 2px; /* change this to modify the thickness of the closed border row */ 121 | margin: 0; 122 | line-height: 0; 123 | } 124 | .tablesorter-bootstrap .tablesorter-filter-row.hideme * { 125 | height: 1px; 126 | min-height: 0; 127 | border: 0; 128 | padding: 0; 129 | margin: 0; 130 | /* don't use visibility: hidden because it disables tabbing */ 131 | opacity: 0; 132 | filter: alpha(opacity=0); 133 | } 134 | /* rows hidden by filtering (needed for child rows) */ 135 | .tablesorter .filtered { 136 | display: none; 137 | } 138 | 139 | /* pager plugin */ 140 | .tablesorter-bootstrap .tablesorter-pager select { 141 | padding: 4px 6px; 142 | } 143 | .tablesorter-bootstrap .tablesorter-pager .pagedisplay { 144 | border: 0; 145 | } 146 | /* tfoot i for pager controls */ 147 | .tablesorter-bootstrap tfoot i { 148 | font-size: 11px; 149 | } 150 | 151 | /* ajax error row */ 152 | .tablesorter .tablesorter-errorRow td { 153 | text-align: center; 154 | cursor: pointer; 155 | background-color: #e6bf99; 156 | } 157 | -------------------------------------------------------------------------------- /src/css/ztree/zTreeStyle.css: -------------------------------------------------------------------------------- 1 | /*------------------------------------- 2 | zTree Style 3 | 4 | version: 3.5.19 5 | author: Hunter.z 6 | email: hunter.z@263.net 7 | website: http://code.google.com/p/jquerytree/ 8 | 9 | -------------------------------------*/ 10 | 11 | .ztree * {padding:0; margin:0; font-size:12px; font-family: Verdana, Arial, Helvetica, AppleGothic, sans-serif} 12 | .ztree {margin:0; padding:5px; color:#333} 13 | .ztree li{padding:0; margin:0; list-style:none; line-height:14px; text-align:left; white-space:nowrap; outline:0} 14 | .ztree li ul{ margin:0; padding:0 0 0 18px} 15 | .ztree li ul.line{ background:url(./img/line_conn.gif) 0 0 repeat-y;} 16 | 17 | .ztree li a {padding:1px 3px 0 0; margin:0; cursor:pointer; height:17px; color:#333; background-color: transparent; 18 | text-decoration:none; vertical-align:top; display: inline-block} 19 | .ztree li a:hover {text-decoration:underline} 20 | .ztree li a.curSelectedNode {padding-top:0px; background-color:#FFE6B0; color:black; height:16px; border:1px #FFB951 solid; opacity:0.8;} 21 | .ztree li a.curSelectedNode_Edit {padding-top:0px; background-color:#FFE6B0; color:black; height:16px; border:1px #FFB951 solid; opacity:0.8;} 22 | .ztree li a.tmpTargetNode_inner {padding-top:0px; background-color:#316AC5; color:white; height:16px; border:1px #316AC5 solid; 23 | opacity:0.8; filter:alpha(opacity=80)} 24 | .ztree li a.tmpTargetNode_prev {} 25 | .ztree li a.tmpTargetNode_next {} 26 | .ztree li a input.rename {height:14px; width:80px; padding:0; margin:0; 27 | font-size:12px; border:1px #7EC4CC solid; *border:0px} 28 | .ztree li span {line-height:16px; margin-right:2px} 29 | .ztree li span.button {line-height:0; margin:0; width:16px; height:16px; display: inline-block; vertical-align:middle; 30 | border:0 none; cursor: pointer;outline:none; 31 | background-color:transparent; background-repeat:no-repeat; background-attachment: scroll; 32 | background-image:url("./img/zTreeStandard.png"); *background-image:url("./img/zTreeStandard.gif")} 33 | 34 | .ztree li span.button.chk {width:13px; height:13px; margin:0 3px 0 0; cursor: auto} 35 | .ztree li span.button.chk.checkbox_false_full {background-position:0 0} 36 | .ztree li span.button.chk.checkbox_false_full_focus {background-position:0 -14px} 37 | .ztree li span.button.chk.checkbox_false_part {background-position:0 -28px} 38 | .ztree li span.button.chk.checkbox_false_part_focus {background-position:0 -42px} 39 | .ztree li span.button.chk.checkbox_false_disable {background-position:0 -56px} 40 | .ztree li span.button.chk.checkbox_true_full {background-position:-14px 0} 41 | .ztree li span.button.chk.checkbox_true_full_focus {background-position:-14px -14px} 42 | .ztree li span.button.chk.checkbox_true_part {background-position:-14px -28px} 43 | .ztree li span.button.chk.checkbox_true_part_focus {background-position:-14px -42px} 44 | .ztree li span.button.chk.checkbox_true_disable {background-position:-14px -56px} 45 | .ztree li span.button.chk.radio_false_full {background-position:-28px 0} 46 | .ztree li span.button.chk.radio_false_full_focus {background-position:-28px -14px} 47 | .ztree li span.button.chk.radio_false_part {background-position:-28px -28px} 48 | .ztree li span.button.chk.radio_false_part_focus {background-position:-28px -42px} 49 | .ztree li span.button.chk.radio_false_disable {background-position:-28px -56px} 50 | .ztree li span.button.chk.radio_true_full {background-position:-42px 0} 51 | .ztree li span.button.chk.radio_true_full_focus {background-position:-42px -14px} 52 | .ztree li span.button.chk.radio_true_part {background-position:-42px -28px} 53 | .ztree li span.button.chk.radio_true_part_focus {background-position:-42px -42px} 54 | .ztree li span.button.chk.radio_true_disable {background-position:-42px -56px} 55 | 56 | .ztree li span.button.switch {width:18px; height:18px} 57 | .ztree li span.button.root_open{background-position:-92px -54px} 58 | .ztree li span.button.root_close{background-position:-74px -54px} 59 | .ztree li span.button.roots_open{background-position:-92px 0} 60 | .ztree li span.button.roots_close{background-position:-74px 0} 61 | .ztree li span.button.center_open{background-position:-92px -18px} 62 | .ztree li span.button.center_close{background-position:-74px -18px} 63 | .ztree li span.button.bottom_open{background-position:-92px -36px} 64 | .ztree li span.button.bottom_close{background-position:-74px -36px} 65 | .ztree li span.button.noline_open{background-position:-92px -72px} 66 | .ztree li span.button.noline_close{background-position:-74px -72px} 67 | .ztree li span.button.root_docu{ background:none;} 68 | .ztree li span.button.roots_docu{background-position:-56px 0} 69 | .ztree li span.button.center_docu{background-position:-56px -18px} 70 | .ztree li span.button.bottom_docu{background-position:-56px -36px} 71 | .ztree li span.button.noline_docu{ background:none;} 72 | 73 | .ztree li span.button.ico_open{margin-right:2px; background-position:-110px -16px; vertical-align:top; *vertical-align:middle} 74 | .ztree li span.button.ico_close{margin-right:2px; background-position:-110px 0; vertical-align:top; *vertical-align:middle} 75 | .ztree li span.button.ico_docu{margin-right:2px; background-position:-110px -32px; vertical-align:top; *vertical-align:middle} 76 | .ztree li span.button.edit {margin-right:2px; background-position:-110px -48px; vertical-align:top; *vertical-align:middle} 77 | .ztree li span.button.remove {margin-right:2px; background-position:-110px -64px; vertical-align:top; *vertical-align:middle} 78 | 79 | .ztree li span.button.ico_loading{margin-right:2px; background:url(./img/loading.gif) no-repeat scroll 0 0 transparent; vertical-align:top; *vertical-align:middle} 80 | 81 | ul.tmpTargetzTree {background-color:#FFE6B0; opacity:0.8; filter:alpha(opacity=80)} 82 | 83 | span.tmpzTreeMove_arrow {width:16px; height:16px; display: inline-block; padding:0; margin:2px 0 0 1px; border:0 none; position:absolute; 84 | background-color:transparent; background-repeat:no-repeat; background-attachment: scroll; 85 | background-position:-110px -80px; background-image:url("./img/zTreeStandard.png"); *background-image:url("./img/zTreeStandard.gif")} 86 | 87 | ul.ztree.zTreeDragUL {margin:0; padding:0; position:absolute; width:auto; height:auto;overflow:hidden; background-color:#cfcfcf; border:1px #00B83F dotted; opacity:0.8; filter:alpha(opacity=80)} 88 | .zTreeMask {z-index:10000; background-color:#cfcfcf; opacity:0.0; filter:alpha(opacity=0); position:absolute} 89 | 90 | /* level style*/ 91 | /*.ztree li span.button.level0 { 92 | display:none; 93 | } 94 | .ztree li ul.level0 { 95 | padding:0; 96 | background:none; 97 | }*/ -------------------------------------------------------------------------------- /example/extend/all.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 总体功能集成 6 | 7 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 |
                19 |
                20 |
                21 |
                22 |

                结果中筛选

                23 |
                24 |
                25 |
                  26 |
                  27 |
                  28 | 29 |
                  30 |
                  31 |

                  范例

                  32 |
                  33 |
                  34 |

                  返回范例列表

                  35 |
                  36 |
                  37 | 38 | 39 | 40 | 41 |
                  42 | 43 |
                  44 |
                  45 |
                  46 |

                  总体功能集成

                  47 |
                  48 |
                  49 | 50 |
                  51 | 54 |
                    55 |
                  • 使用说明:
                  • 56 |
                  • 包括基础展示功能
                  • 57 |
                  • 集成平均值/最大值/最小值功能,预设值比对功能
                  • 58 |
                  • 集成导出功能,图表功能,排序功能,由于触发事件冲突,未集成表头描述功能
                  • 59 |
                  60 |
                  61 |
                  62 |
                  63 | 120 |
                  121 | 122 | 123 | 124 |
                  125 | 126 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | -------------------------------------------------------------------------------- /src/js/exporting.js: -------------------------------------------------------------------------------- 1 | /* 2 | Highcharts JS v4.2.1 (2015-12-21) 3 | Exporting module 4 | 5 | (c) 2010-2014 Torstein Honsi 6 | 7 | License: www.highcharts.com/license 8 | */ 9 | (function(f){typeof module==="object"&&module.exports?module.exports=f:f(Highcharts)})(function(f){var r=f.win,m=r.document,A=f.Chart,t=f.addEvent,B=f.removeEvent,C=f.fireEvent,n=f.createElement,s=f.discardElement,v=f.css,l=f.merge,i=f.each,q=f.extend,F=f.splat,G=Math.max,H=f.isTouchDevice,I=f.Renderer.prototype.symbols,y=f.getOptions(),z;q(y.lang,{printChart:"Print chart",downloadPNG:"Download PNG image",downloadJPEG:"Download JPEG image",downloadPDF:"Download PDF document",downloadSVG:"Download SVG vector image", 10 | contextButtonTitle:"Chart context menu"});y.navigation={menuStyle:{border:"1px solid #A0A0A0",background:"#FFFFFF",padding:"5px 0"},menuItemStyle:{padding:"0 10px",background:"none",color:"#303030",fontSize:H?"14px":"11px"},menuItemHoverStyle:{background:"#4572A5",color:"#FFFFFF"},buttonOptions:{symbolFill:"#E0E0E0",symbolSize:14,symbolStroke:"#666",symbolStrokeWidth:3,symbolX:12.5,symbolY:10.5,align:"right",buttonSpacing:3,height:22,theme:{fill:"white",stroke:"none"},verticalAlign:"top",width:24}}; 11 | y.exporting={type:"image/png",url:"http://export.highcharts.com/",buttons:{contextButton:{menuClassName:"highcharts-contextmenu",symbol:"menu",_titleKey:"contextButtonTitle",menuItems:[{textKey:"printChart",onclick:function(){this.print()}},{separator:!0},{textKey:"downloadPNG",onclick:function(){this.exportChart()}},{textKey:"downloadJPEG",onclick:function(){this.exportChart({type:"image/jpeg"})}},{textKey:"downloadPDF",onclick:function(){this.exportChart({type:"application/pdf"})}},{textKey:"downloadSVG", 12 | onclick:function(){this.exportChart({type:"image/svg+xml"})}}]}}};f.post=function(a,b,e){var c,a=n("form",l({method:"post",action:a,enctype:"multipart/form-data"},e),{display:"none"},m.body);for(c in b)n("input",{type:"hidden",name:c,value:b[c]},null,a);a.submit();s(a)};q(A.prototype,{sanitizeSVG:function(a){return a.replace(/zIndex="[^"]+"/g,"").replace(/isShadow="[^"]+"/g,"").replace(/symbolName="[^"]+"/g,"").replace(/jQuery[0-9]+="[^"]+"/g,"").replace(/url\([^#]+#/g,"url(#").replace(/.*?$/,"").replace(/(fill|stroke)="rgba\(([ 0-9]+,[ 0-9]+,[ 0-9]+),([ 0-9\.]+)\)"/g,'$1="rgb($2)" $1-opacity="$3"').replace(/ /g,"\u00a0").replace(/­/g,"\u00ad").replace(//g,"<$1title>").replace(/height=([^" ]+)/g,'height="$1"').replace(/width=([^" ]+)/g,'width="$1"').replace(/hc-svg-href="([^"]+)">/g,'xlink:href="$1"/>').replace(/ id=([^" >]+)/g,' id="$1"').replace(/class=([^" >]+)/g,'class="$1"').replace(/ transform /g, 14 | " ").replace(/:(path|rect)/g,"$1").replace(/style="([^"]+)"/g,function(b){return b.toLowerCase()})},getChartHTML:function(){return this.container.innerHTML},getSVG:function(a){var b=this,e,c,g,j,k,d=l(b.options,a),J=d.exporting.allowHTML;if(!m.createElementNS)m.createElementNS=function(b,a){return m.createElement(a)};c=n("div",null,{position:"absolute",top:"-9999em",width:b.chartWidth+"px",height:b.chartHeight+"px"},m.body);g=b.renderTo.style.width;k=b.renderTo.style.height;g=d.exporting.sourceWidth|| 15 | d.chart.width||/px$/.test(g)&&parseInt(g,10)||600;k=d.exporting.sourceHeight||d.chart.height||/px$/.test(k)&&parseInt(k,10)||400;q(d.chart,{animation:!1,renderTo:c,forExport:!0,renderer:"SVGRenderer",width:g,height:k});d.exporting.enabled=!1;delete d.data;d.series=[];i(b.series,function(a){j=l(a.options,{animation:!1,enableMouseTracking:!1,showCheckbox:!1,visible:a.visible});j.isInternal||d.series.push(j)});a&&i(["xAxis","yAxis"],function(b){i(F(a[b]),function(a,c){d[b][c]=l(d[b][c],a)})});e=new f.Chart(d, 16 | b.callback);i(["xAxis","yAxis"],function(a){i(b[a],function(b,c){var d=e[a][c],f=b.getExtremes(),g=f.userMin,f=f.userMax;d&&(g!==void 0||f!==void 0)&&d.setExtremes(g,f,!0,!1)})});g=e.getChartHTML();d=null;e.destroy();s(c);if(J&&(c=g.match(/<\/svg>(.*?$)/)))c=''+c[1]+"",g=g.replace("",c+"");g=this.sanitizeSVG(g);return g=g.replace(/(url\(#highcharts-[0-9]+)"/g,"$1").replace(/"/g, 17 | "'")},getSVGForExport:function(a,b){var e=this.options.exporting;return this.getSVG(l({chart:{borderRadius:0}},e.chartOptions,b,{exporting:{sourceWidth:a&&a.sourceWidth||e.sourceWidth,sourceHeight:a&&a.sourceHeight||e.sourceHeight}}))},exportChart:function(a,b){var e=this.getSVGForExport(a,b),a=l(this.options.exporting,a);f.post(a.url,{filename:a.filename||"chart",type:a.type,width:a.width||0,scale:a.scale||2,svg:e},a.formAttributes)},print:function(){var a=this,b=a.container,e=[],c=b.parentNode, 18 | f=m.body,j=f.childNodes;if(!a.isPrinting)a.isPrinting=!0,a.pointer.reset(null,0),C(a,"beforePrint"),i(j,function(a,b){if(a.nodeType===1)e[b]=a.style.display,a.style.display="none"}),f.appendChild(b),r.focus(),r.print(),setTimeout(function(){c.appendChild(b);i(j,function(a,b){if(a.nodeType===1)a.style.display=e[b]});a.isPrinting=!1;C(a,"afterPrint")},1E3)},contextMenu:function(a,b,e,c,f,j,k){var d=this,l=d.options.navigation,D=l.menuItemStyle,o=d.chartWidth,p=d.chartHeight,E="cache-"+a,h=d[E],u=G(f, 19 | j),w,x,r,s=function(b){d.pointer.inClass(b.target,a)||x()};if(!h)d[E]=h=n("div",{className:a},{position:"absolute",zIndex:1E3,padding:u+"px"},d.container),w=n("div",null,q({MozBoxShadow:"3px 3px 10px #888",WebkitBoxShadow:"3px 3px 10px #888",boxShadow:"3px 3px 10px #888"},l.menuStyle),h),x=function(){v(h,{display:"none"});k&&k.setState(0);d.openMenu=!1},t(h,"mouseleave",function(){r=setTimeout(x,500)}),t(h,"mouseenter",function(){clearTimeout(r)}),t(m,"mouseup",s),t(d,"destroy",function(){B(m,"mouseup", 20 | s)}),i(b,function(a){if(a){var b=a.separator?n("hr",null,null,w):n("div",{onmouseover:function(){v(this,l.menuItemHoverStyle)},onmouseout:function(){v(this,D)},onclick:function(b){b&&b.stopPropagation();x();a.onclick&&a.onclick.apply(d,arguments)},innerHTML:a.text||d.options.lang[a.textKey]},q({cursor:"pointer"},D),w);d.exportDivElements.push(b)}}),d.exportDivElements.push(w,h),d.exportMenuWidth=h.offsetWidth,d.exportMenuHeight=h.offsetHeight;b={display:"block"};e+d.exportMenuWidth>o?b.right=o-e- 21 | f-u+"px":b.left=e-u+"px";c+j+d.exportMenuHeight>p&&k.alignOptions.verticalAlign!=="top"?b.bottom=p-c-u+"px":b.top=c+j-u+"px";v(h,b);d.openMenu=!0},addButton:function(a){var b=this,e=b.renderer,c=l(b.options.navigation.buttonOptions,a),g=c.onclick,j=c.menuItems,k,d,m={stroke:c.symbolStroke,fill:c.symbolFill},i=c.symbolSize||12;if(!b.btnCount)b.btnCount=0;if(!b.exportDivElements)b.exportDivElements=[],b.exportSVGElements=[];if(c.enabled!==!1){var o=c.theme,p=o.states,n=p&&p.hover,p=p&&p.select,h;delete o.states; 22 | g?h=function(a){a.stopPropagation();g.call(b,a)}:j&&(h=function(){b.contextMenu(d.menuClassName,j,d.translateX,d.translateY,d.width,d.height,d);d.setState(2)});c.text&&c.symbol?o.paddingLeft=f.pick(o.paddingLeft,25):c.text||q(o,{width:c.width,height:c.height,padding:0});d=e.button(c.text,0,0,h,o,n,p).attr({title:b.options.lang[c._titleKey],"stroke-linecap":"round"});d.menuClassName=a.menuClassName||"highcharts-menu-"+b.btnCount++;c.symbol&&(k=e.symbol(c.symbol,c.symbolX-i/2,c.symbolY-i/2,i,i).attr(q(m, 23 | {"stroke-width":c.symbolStrokeWidth||1,zIndex:1})).add(d));d.add().align(q(c,{width:d.width,x:f.pick(c.x,z)}),!0,"spacingBox");z+=(d.width+c.buttonSpacing)*(c.align==="right"?-1:1);b.exportSVGElements.push(d,k)}},destroyExport:function(a){var a=a.target,b,e;for(b=0;b a { color: #d32412; text-decoration: none; } 65 | .main-navigation .menu li ul { visibility: hidden; background: #ffffff; text-align: left; padding: 7px 0px; margin: 0; position: absolute; left: 0; top: 120%; width: 200px; z-index: 999; opacity: 0; filter: alpha(opacity=0); -webkit-transition: all 0.2s ease; -o-transition: all 0.2s ease; transition: all 0.2s ease; } 66 | .main-navigation .menu li ul li { display: block; margin: 0; } 67 | .main-navigation .menu li ul li a { line-height: 2.5em; color: #505050; } 68 | .main-navigation .menu li ul:hover > a { color: #d32412; } 69 | .main-navigation .menu li:hover ul { visibility: visible; opacity: 1; filter: alpha(opacity=100); top: 100%; } 70 | 71 | @media (max-width: 767px) { 72 | .main-navigation { text-align: left; } 73 | .main-navigation .menu li { display: block; } 74 | .main-navigation .menu li:hover > a { color: #d32412; text-decoration: none; } 75 | .main-navigation .menu li ul { visibility: visible; padding: 0px 0px 0px 20px; margin: 0; position: relative; top: 0; width: 100%; opacity: 1; filter: alpha(opacity=100); } 76 | } 77 | /* navbar */ 78 | .navbar-header { text-align: center; } 79 | .navbar-header i { height: 56px; line-height: 56px; font-size: 2em; cursor: pointer; } 80 | 81 | @media (min-width: 768px) { 82 | .nav-toggle-button { display: none; } 83 | } 84 | /* post */ 85 | /*==================================================== 86 | main post area 87 | ====================================================*/ 88 | .post { padding: 20px; background: #ffffff; margin-bottom: 35px; position: relative; } 89 | .post .featured { position: absolute; background: #d32412; color: #ffffff; text-align: center; top: -12px; right: -32px; width: 80px; height: 40px; line-height: 54px; -webkit-transform: rotate(45deg); -ms-transform: rotate(45deg); -o-transform: rotate(45deg); transform: rotate(45deg); } 90 | .post .featured i { -webkit-transform: rotate(-45deg); -ms-transform: rotate(-45deg); -o-transform: rotate(-45deg); transform: rotate(-45deg); } 91 | .post .post-head { text-align: center; } 92 | .post .post-head .post-title { margin: 0; font-size: 2.5em; line-height: 1em; } 93 | .post .post-head .post-title a { color: #303030; } 94 | .post .post-head .post-title a:hover, .post .post-head .post-title a:focus { text-decoration: none; } 95 | .post .post-head .post-meta { color: #959595; margin: 14px 0 0px; } 96 | .post .post-head .post-meta span { margin: 0px 7px; white-space: nowrap; } 97 | .post .featured-media { margin-top: 30px; overflow: hidden; } 98 | .post .featured-media img { width: 100%; } 99 | .post .post-content { margin: 30px 0; } 100 | .post .post-footer { margin-top: 30px; border-top: 1px solid #ebebeb; padding: 21px 0 0; } 101 | .post .post-footer .tag-list { color: #959595; line-height: 28px; } 102 | .post .post-footer .tag-list a { color: #959595; margin-left: 7px; } 103 | .post .post-footer .tag-list a:hover { color: #d32412; } 104 | /* post content */ 105 | 106 | /* sidebar */ 107 | /*==================================================== 108 | sidebar 109 | ====================================================*/ 110 | .sidebar .widget { background: #ffffff; padding: 20px 20px 10px; } 111 | .main-footer .widget { padding: 0px 30px; } 112 | .widget { margin-bottom: 15px; } 113 | .widget .title { margin-top: 0; padding-bottom: 7px; border-bottom: 1px solid #ebebeb; margin-bottom: 21px; position: relative; } 114 | .widget .title:after { content: ""; width: 110px; height: 1px; background: #d32412; position: absolute; left: 0; bottom: -1px; } 115 | .widget .community a{ 116 | /*1line-height:36px;*/ 117 | font-size:16px; color:#333;} 118 | .widget .recent-post .recent-single-post { border-bottom: 1px dashed #ebebeb; padding-bottom: 14px; margin-bottom: 14px; } 119 | .widget .recent-post .recent-single-post:last-child { margin-bottom: 0; } 120 | .widget .recent-post .recent-single-post .post-title { color: #505050; -webkit-transition: all 0.2s ease; -o-transition: all 0.2s ease; transition: all 0.2s ease; } 121 | .widget .recent-post .recent-single-post .post-title:hover { color: #d32412; text-decoration: none; } 122 | .widget .recent-post .recent-single-post .date { color: #959595; } 123 | .widget .tag-cloud a { border: 1px solid #ebebeb; padding: 2px 7px; color: #959595; line-height: 1.5em; display: inline-block; margin: 0 7px 7px 0; -webkit-transition: all 0.2s ease; -o-transition: all 0.2s ease; transition: all 0.2s ease; } 124 | .widget .tag-cloud a:hover { color: #ffffff; background: #d32412; border: 1px solid #d32412; text-decoration: none; } 125 | .widget .social { padding: 0; margin: 0; } 126 | .widget .social li { display: inline-block; margin: 0 2px 5px 0; text-align: center; } 127 | .widget .social li a i { width: 35px; height: 35px; line-height: 35px; border: 1px solid #ebebeb; color: #959595; -webkit-transition: all 0.2s; -o-transition: all 0.2s; transition: all 0.2s; } 128 | .widget .social li:hover i { color: #ffffff; background: #d32412; border: 1px solid #d32412; } 129 | .widget .newsletter .input-group { margin-bottom: 10px; display: block; } 130 | .widget .newsletter .input-group .email, .widget .newsletter .input-group btn { width: 100%; } 131 | .widget .ad { text-align: center; } 132 | .widget .ad img { max-width: 100%; } 133 | 134 | 135 | .widget .community a.current{background: #d43f3a; color:#ffffff; display:inline-block;padding:5px; border-radius: 3px;} 136 | -------------------------------------------------------------------------------- /example/base/simple.js: -------------------------------------------------------------------------------- 1 | /** 2 | * autoHeader 应用 3 | * created by Finira 2016-1-11 4 | */ 5 | 6 | $(function(){ 7 | //返回列表按钮 8 | $('#backlist').on('click', function() { 9 | $('#listdiv').slideDown(); 10 | $('#viewdiv').slideUp(); 11 | }); 12 | //结果集树 13 | $.fn.zTree.init($("#treeDemo_org"), setting, treejson_); 14 | 15 | //筛选按钮 16 | $('#generator').on('click', function() { 17 | //获取表头筛选数据,重新生成table 18 | var treeObj = $.fn.zTree.getZTreeObj("header_tree"); 19 | var nodes = treeObj.getCheckedNodes(); 20 | var bodyjson_ = getSelectOrg(); 21 | initTable("tabled",nodes,bodyjson_); 22 | $("#containdivcnt").hide(); 23 | //统计总表清空 24 | $('#tabledcnt').empty(); 25 | //表头树默认缩回 26 | $('#headtre').slideUp(); 27 | $('#headerchoose').html(' 选择表头'); 28 | 29 | }); 30 | 31 | 32 | //最大化按钮功能 33 | $("#maxbt").on('click', function() { 34 | if(!ismax){ 35 | $('#refdiv').fadeOut(); 36 | $('#navs').fadeOut(); 37 | $('#alldiv').fadeIn(); 38 | $(this).html(' 回复原状'); 39 | //复制按钮和table的内容到alldiv 中 40 | $('#buttons').insertBefore('#dtiyp'); 41 | //增加导航css,滚动条滚动导航条不动 42 | $('#buttons').addClass('navbar-fixed-top'); 43 | $('#analyzz').insertAfter('#dtiyp'); 44 | $('#containdivcnt').insertAfter('#dtiyp'); 45 | $('body').attr('class','bodyafter'); 46 | ismax = true; 47 | }else{ 48 | //div隐藏关系改变,按钮和table内容重新复制回原来的位置 49 | $('#alldiv').fadeOut(); 50 | $('#navs').fadeIn(); 51 | $('#refdiv').fadeIn(); 52 | $('#buttons').insertBefore('#datev'); 53 | $('#analyzz').insertAfter('#tablepositonid'); 54 | $('#containdivcnt').insertAfter('#datev'); 55 | $('#buttons').removeClass('navbar-fixed-top'); 56 | $(this).html(' 最大化'); 57 | $('body').attr('class','bodypre'); 58 | ismax = false; 59 | } 60 | 61 | }); 62 | 63 | //表头树,按钮激发 64 | $('#headerchoose').on('click', function(e) { 65 | if($('#headtre').is(":hidden")){ 66 | $('#headtre').slideDown(); 67 | $(this).html(' 收回表头'); 68 | }else{ 69 | $('#headtre').slideUp(); 70 | $(this).html(' 选择表头'); 71 | } 72 | }); 73 | 74 | }); 75 | 76 | 77 | 78 | /** 79 | * 根据选择的部门信息过滤数据包,将符合条件的留下 80 | */ 81 | function validateBodyJson(orgstr){ 82 | if(orgstr){ 83 | var newJson =[]; 84 | //循环json,获取上报部门ID字段 85 | $.each(bodyjson, function (j,itemj) { 86 | var orgcode = "_"+itemj.rep_org_code+"_"; 87 | //如果不在选中的部门ID范围内 则删除数据 88 | if(orgstr.indexOf(orgcode)>=0){ 89 | newJson.push(itemj); 90 | } 91 | }); 92 | return newJson; 93 | } 94 | } 95 | 96 | 97 | //定义树 98 | var setting = { 99 | check: { 100 | enable: true, 101 | chkboxType:{ "Y":"ps", "N":"ps"} 102 | 103 | }, 104 | data: { 105 | simpleData: { 106 | enable: true 107 | } 108 | } 109 | }; 110 | 111 | var code; 112 | var ismax=false; 113 | var treejson=null; 114 | var bodyjson = null; 115 | var currentJson =null; 116 | 117 | 118 | 119 | /** 120 | * 初始化表格方法 121 | */ 122 | function initTable(tableId,headstr,bodystr){ 123 | 124 | $.fn.autoHeader.init({ 125 | laynum:5, 126 | headJson:headstr, 127 | dataJson:bodystr, 128 | tableid:'tabled', 129 | needsort:true, 130 | cssConfig:{ 131 | table:' table-hover table-striped table-bordered table-responsive', 132 | tr:'' 133 | } 134 | }); 135 | } 136 | 137 | 138 | //表格初始化 139 | function showView(){ 140 | $('#listdiv').slideUp(); 141 | $('#viewdiv').slideDown(); 142 | var headjson_ = header_; 143 | var bodyjson_= dataer_; 144 | treejson = headjson_ ; 145 | currentJson = bodyjson = bodyjson_ ; 146 | initTable("tabled",headjson_,bodyjson_); 147 | $.fn.zTree.init($("#header_tree"), setting, treejson); 148 | 149 | } 150 | 151 | //获取已选结果集 152 | function getSelectOrg(){ 153 | var treeOrg = $.fn.zTree.getZTreeObj("treeDemo_org"); 154 | var orgnodes = treeOrg.getCheckedNodes(); 155 | 156 | var orgstr='_'; 157 | //循环遍历已选org 158 | $.each(orgnodes, function (i, item) { 159 | orgstr += item.id+"_"; 160 | }); 161 | var bodyjson_ = bodyjson; 162 | //如果有选择部门,就去筛选body数据 163 | if(orgstr!='_' ){ 164 | bodyjson_ = validateBodyJson(orgstr); 165 | } 166 | currentJson = bodyjson_; 167 | //console.log(JSON.stringify(currentJson) ); 168 | return bodyjson_; 169 | } 170 | 171 | 172 | 173 | var treejson_ = [{id:1, name: "三年级","isParent":1,"open":false}, 174 | {id:232, "pid":1, name: "三年一班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 175 | {id:240, "pid":1, name: "三年二班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 176 | {id:701, "pid":1, name: "三年三班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 177 | {id:89, "pid":1, name: "三年四班","open":false}, 178 | {id:247, "pid":1, name: "三年五班","open":false}, 179 | {id:262, "pid":1, name: "三年六班","open":false}, 180 | {id:281, "pid":1, name: "三年七班","open":false}, 181 | {id:294, "pid":1, name: "三年八班","open":false}, 182 | {id:313, "pid":1, name: "三年九班","open":false}, 183 | {id:702, "pid":1, name: "三年十班","open":false}, 184 | {id:703, "pid":1, name: "三年十一班","open":false}, 185 | {id:704, "pid":1, name: "三年十二班","open":false} 186 | 187 | ]; 188 | 189 | var dataer_ = [{"column_001":"99.41","column_002":"99.74","column_003":"98.90","column_004":"99","column_005":"100","column_006":"99.29","column_007":"99.70","column_008":"97.59","column_009":"99.10","column_010":"98.89","id":227,"main_id":214,"rep_org_code":"232","rep_org_name":"三年一班","report_id":5},{"column_001":"98.91","column_002":"99.39","column_003":"97.90","column_004":"99","column_005":"100","column_006":"98.89","column_007":"99.86","column_008":"98.01","column_009":"98.90","column_010":"99.02","id":228,"main_id":201,"rep_org_code":"240","rep_org_name":"三年二班","report_id":5},{"column_001":"98.78","column_002":"99.23","column_003":"98.30","column_004":"99","column_005":"100","column_006":"98.96","column_007":"99.88","column_008":"95.43","column_009":"98.28","column_010":"98.06","id":229,"main_id":208,"rep_org_code":"703","rep_org_name":"三年十一班","report_id":5},{"column_001":"97.98","column_002":"95.59","column_003":"98.10","column_004":"98.50","column_005":"100","column_006":"97.66","column_007":"100","column_008":"97.81","column_009":"99.78","column_010":"99.28","id":230,"main_id":206,"rep_org_code":"701","rep_org_name":"三年三班","report_id":5},{"column_001":"97.88","column_002":"96.49","column_003":"98.80","column_004":"99","column_005":"100","column_006":"98.29","column_007":"98.79","column_008":"97.16","column_009":"91.96","column_010":"96.25","id":231,"main_id":219,"rep_org_code":"281","rep_org_name":"三年七班","report_id":5},{"column_001":"97.84","column_002":"95.61","column_003":"97.95","column_004":"100","column_005":"100","column_006":"98.07","column_007":"97.37","column_008":"97.31","column_009":"95.89","column_010":"96.91","id":232,"main_id":205,"rep_org_code":"313","rep_org_name":"三年九班","report_id":5},{"column_001":"97.54","column_002":"95.13","column_003":"97.90","column_004":"98.50","column_005":"100","column_006":"97.46","column_007":"100","column_008":"96.28","column_009":"96.65","column_010":"97.88","id":233,"main_id":209,"rep_org_code":"704","rep_org_name":"三年十二班","report_id":5},{"column_001":"97.23","column_002":"96.17","column_003":"97","column_004":"98.50","column_005":"100","column_006":"97.50","column_007":"99.85","column_008":"95.37","column_009":"91.94","column_010":"96.13","id":235,"main_id":215,"rep_org_code":"89","rep_org_name":"三年四班","report_id":5},{"column_001":"97.01","column_002":"92.18","column_003":"97.90","column_004":"98.50","column_005":"100","column_006":"96.57","column_007":"99.85","column_008":"97.69","column_009":"98.41","column_010":"98.77","id":236,"main_id":202,"rep_org_code":"247","rep_org_name":"三年五班","report_id":5},{"column_001":"95.36","column_002":"87.27","column_003":"98.55","column_004":"98","column_005":"100","column_006":"95.33","column_007":"98.68","column_008":"97.85","column_009":"92.16","column_010":"96.48","id":237,"main_id":203,"rep_org_code":"262","rep_org_name":"三年六班","report_id":5},{"column_001":"94.74","column_002":"83.24","column_003":"98.35","column_004":"98.50","column_005":"100","column_006":"94.03","column_007":"97.62","column_008":"96.81","column_009":"98.36","column_010":"97.60","id":238,"main_id":207,"rep_org_code":"702","rep_org_name":"三年十班","report_id":5},{"column_001":"92.15","column_002":"75.50","column_003":"96.50","column_004":"93.50","column_005":"100","column_006":"91.85","column_007":"97.56","column_008":"97.21","column_009":"97.22","column_010":"97.35","id":239,"main_id":220,"rep_org_code":"294","rep_org_name":"三年八班","report_id":5}]; 190 | var header_ = [{"checked":1,"cssstyle":"","headDesc":"三年级综合考试评定分析","id":502,"isleaf":"N","isopen":0,"level":"0","name":"三年级综合考试评定分析","pid":502,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"","id":503,"isleaf":"Y","isopen":0,"level":"1","name":"班级","pid":502,"reportColumnName":"rep_org_name","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"1210","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"80%A+20%B","id":504,"isleaf":"Y","isopen":0,"level":"1","name":"综合总分","pid":502,"reportColumnName":"column_001","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1211","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"","id":505,"isleaf":"N","isopen":0,"level":"1","name":"考核项目","pid":502,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"1212","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"描述","id":506,"isleaf":"N","isopen":0,"level":"2","name":"文化课程","pid":505,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"121210","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"语文分数","id":507,"isleaf":"Y","isopen":0,"level":"3","name":"语文","pid":506,"reportColumnName":"column_002","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121010","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"数学分数","id":508,"isleaf":"Y","isopen":0,"level":"3","name":"数学","pid":506,"reportColumnName":"column_003","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121011","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合科目分数","id":509,"isleaf":"Y","isopen":0,"level":"3","name":"综合科目","pid":506,"reportColumnName":"column_004","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121012","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"外语","id":510,"isleaf":"Y","isopen":0,"level":"3","name":"外语","pid":506,"reportColumnName":"column_005","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121013","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"文化课程综合评估分数","id":511,"isleaf":"Y","isopen":0,"level":"3","name":"文化总体","pid":506,"reportColumnName":"column_006","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121001","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合素质","id":512,"isleaf":"N","isopen":0,"level":"2","name":"综合素质","pid":505,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"121211","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"美术评定","id":513,"isleaf":"Y","isopen":0,"level":"3","name":"美术","pid":512,"reportColumnName":"column_007","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121110","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"体育评定","id":514,"isleaf":"N","isopen":0,"level":"3","name":"体育","pid":512,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121111","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"基本体测评定","id":515,"isleaf":"Y","isopen":0,"level":"4","name":"体能测试","pid":514,"reportColumnName":"column_008","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1212111110","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"体育考试评定","id":516,"isleaf":"Y","isopen":0,"level":"4","name":"体育考试","pid":514,"reportColumnName":"column_009","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1212111111","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合总体评定分数","id":517,"isleaf":"Y","isopen":0,"level":"3","name":"综合总体","pid":512,"reportColumnName":"column_010","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121101","type":"org_exam"}]; 191 | -------------------------------------------------------------------------------- /example/extend/sort.js: -------------------------------------------------------------------------------- 1 | /** 2 | * autoHeader 应用 3 | * created by Finira 2016-1-11 4 | */ 5 | 6 | $(function(){ 7 | //返回列表按钮 8 | $('#backlist').on('click', function() { 9 | $('#listdiv').slideDown(); 10 | $('#viewdiv').slideUp(); 11 | }); 12 | //结果集树 13 | $.fn.zTree.init($("#treeDemo_org"), setting, treejson_); 14 | 15 | //筛选按钮 16 | $('#generator').on('click', function() { 17 | //获取表头筛选数据,重新生成table 18 | var treeObj = $.fn.zTree.getZTreeObj("header_tree"); 19 | var nodes = treeObj.getCheckedNodes(); 20 | var bodyjson_ = getSelectOrg(); 21 | initTable("tabled",nodes,bodyjson_); 22 | $("#containdivcnt").hide(); 23 | //统计总表清空 24 | $('#tabledcnt').empty(); 25 | //表头树默认缩回 26 | $('#headtre').slideUp(); 27 | $('#headerchoose').html(' 选择表头'); 28 | 29 | }); 30 | 31 | 32 | //最大化按钮功能 33 | $("#maxbt").on('click', function() { 34 | if(!ismax){ 35 | $('#refdiv').fadeOut(); 36 | $('#navs').fadeOut(); 37 | $('#alldiv').fadeIn(); 38 | $(this).html(' 回复原状'); 39 | //复制按钮和table的内容到alldiv 中 40 | $('#buttons').insertBefore('#dtiyp'); 41 | //增加导航css,滚动条滚动导航条不动 42 | $('#buttons').addClass('navbar-fixed-top'); 43 | $('#analyzz').insertAfter('#dtiyp'); 44 | $('#containdivcnt').insertAfter('#dtiyp'); 45 | $('body').attr('class','bodyafter'); 46 | ismax = true; 47 | }else{ 48 | //div隐藏关系改变,按钮和table内容重新复制回原来的位置 49 | $('#alldiv').fadeOut(); 50 | $('#navs').fadeIn(); 51 | $('#refdiv').fadeIn(); 52 | $('#buttons').insertBefore('#datev'); 53 | $('#analyzz').insertAfter('#tablepositonid'); 54 | $('#containdivcnt').insertAfter('#datev'); 55 | $('#buttons').removeClass('navbar-fixed-top'); 56 | $(this).html(' 最大化'); 57 | $('body').attr('class','bodypre'); 58 | ismax = false; 59 | } 60 | 61 | }); 62 | 63 | //表头树,按钮激发 64 | $('#headerchoose').on('click', function(e) { 65 | if($('#headtre').is(":hidden")){ 66 | $('#headtre').slideDown(); 67 | $(this).html(' 收回表头'); 68 | }else{ 69 | $('#headtre').slideUp(); 70 | $(this).html(' 选择表头'); 71 | } 72 | }); 73 | 74 | 75 | 76 | }); 77 | 78 | 79 | 80 | /** 81 | * 根据选择的部门信息过滤数据包,将符合条件的留下 82 | */ 83 | function validateBodyJson(orgstr){ 84 | if(orgstr){ 85 | var newJson =[]; 86 | //循环json,获取上报部门ID字段 87 | $.each(bodyjson, function (j,itemj) { 88 | var orgcode = "_"+itemj.rep_org_code+"_"; 89 | //如果不在选中的部门ID范围内 则删除数据 90 | if(orgstr.indexOf(orgcode)>=0){ 91 | newJson.push(itemj); 92 | } 93 | }); 94 | return newJson; 95 | } 96 | } 97 | 98 | 99 | //定义树 100 | var setting = { 101 | check: { 102 | enable: true, 103 | chkboxType:{ "Y":"ps", "N":"ps"} 104 | 105 | }, 106 | data: { 107 | simpleData: { 108 | enable: true 109 | } 110 | } 111 | }; 112 | 113 | var code; 114 | var ismax=false; 115 | var treejson=null; 116 | var bodyjson = null; 117 | var currentJson =null; 118 | 119 | 120 | 121 | /** 122 | * 初始化表格方法 123 | */ 124 | function initTable(tableId,headstr,bodystr){ 125 | 126 | $.fn.autoHeader.init({ 127 | laynum:5, 128 | headJson:headstr, 129 | dataJson:bodystr, 130 | tableid:'tabled', 131 | needsort:true, 132 | cssConfig:{ 133 | table:' table-hover table-striped table-bordered table-responsive', 134 | tr:'' 135 | }, 136 | sort:{ 137 | enable:1, 138 | rank:1, 139 | theme : "bootstrap", 140 | debug:0, 141 | } 142 | }); 143 | } 144 | 145 | 146 | //表格初始化 147 | function showView(){ 148 | $('#listdiv').slideUp(); 149 | $('#viewdiv').slideDown(); 150 | var headjson_ = header_; 151 | var bodyjson_= dataer_; 152 | treejson = headjson_ ; 153 | currentJson = bodyjson = bodyjson_ ; 154 | initTable("tabled",headjson_,bodyjson_); 155 | $.fn.zTree.init($("#header_tree"), setting, treejson); 156 | 157 | } 158 | 159 | //获取已选结果集 160 | function getSelectOrg(){ 161 | var treeOrg = $.fn.zTree.getZTreeObj("treeDemo_org"); 162 | var orgnodes = treeOrg.getCheckedNodes(); 163 | 164 | var orgstr='_'; 165 | //循环遍历已选org 166 | $.each(orgnodes, function (i, item) { 167 | orgstr += item.id+"_"; 168 | }); 169 | var bodyjson_ = bodyjson; 170 | //如果有选择部门,就去筛选body数据 171 | if(orgstr!='_' ){ 172 | bodyjson_ = validateBodyJson(orgstr); 173 | } 174 | currentJson = bodyjson_; 175 | //console.log(JSON.stringify(currentJson) ); 176 | return bodyjson_; 177 | } 178 | 179 | 180 | 181 | var treejson_ = [{id:1, name: "三年级","isParent":1,"open":false}, 182 | {id:232, "pid":1, name: "三年一班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 183 | {id:240, "pid":1, name: "三年二班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 184 | {id:701, "pid":1, name: "三年三班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 185 | {id:89, "pid":1, name: "三年四班","open":false}, 186 | {id:247, "pid":1, name: "三年五班","open":false}, 187 | {id:262, "pid":1, name: "三年六班","open":false}, 188 | {id:281, "pid":1, name: "三年七班","open":false}, 189 | {id:294, "pid":1, name: "三年八班","open":false}, 190 | {id:313, "pid":1, name: "三年九班","open":false}, 191 | {id:702, "pid":1, name: "三年十班","open":false}, 192 | {id:703, "pid":1, name: "三年十一班","open":false}, 193 | {id:704, "pid":1, name: "三年十二班","open":false} 194 | 195 | ]; 196 | 197 | var dataer_ = [{"column_001":"99.41","column_002":"99.74","column_003":"98.90","column_004":"99","column_005":"100","column_006":"99.29","column_007":"99.70","column_008":"97.59","column_009":"99.10","column_010":"98.89","id":227,"main_id":214,"rep_org_code":"232","rep_org_name":"三年一班","report_id":5},{"column_001":"98.91","column_002":"99.39","column_003":"97.90","column_004":"99","column_005":"100","column_006":"98.89","column_007":"99.86","column_008":"98.01","column_009":"98.90","column_010":"99.02","id":228,"main_id":201,"rep_org_code":"240","rep_org_name":"三年二班","report_id":5},{"column_001":"98.78","column_002":"99.23","column_003":"98.30","column_004":"99","column_005":"100","column_006":"98.96","column_007":"99.88","column_008":"95.43","column_009":"98.28","column_010":"98.06","id":229,"main_id":208,"rep_org_code":"703","rep_org_name":"三年十一班","report_id":5},{"column_001":"97.98","column_002":"95.59","column_003":"98.10","column_004":"98.50","column_005":"100","column_006":"97.66","column_007":"100","column_008":"97.81","column_009":"99.78","column_010":"99.28","id":230,"main_id":206,"rep_org_code":"701","rep_org_name":"三年三班","report_id":5},{"column_001":"97.88","column_002":"96.49","column_003":"98.80","column_004":"99","column_005":"100","column_006":"98.29","column_007":"98.79","column_008":"97.16","column_009":"91.96","column_010":"96.25","id":231,"main_id":219,"rep_org_code":"281","rep_org_name":"三年七班","report_id":5},{"column_001":"97.84","column_002":"95.61","column_003":"97.95","column_004":"100","column_005":"100","column_006":"98.07","column_007":"97.37","column_008":"97.31","column_009":"95.89","column_010":"96.91","id":232,"main_id":205,"rep_org_code":"313","rep_org_name":"三年九班","report_id":5},{"column_001":"97.54","column_002":"95.13","column_003":"97.90","column_004":"98.50","column_005":"100","column_006":"97.46","column_007":"100","column_008":"96.28","column_009":"96.65","column_010":"97.88","id":233,"main_id":209,"rep_org_code":"704","rep_org_name":"三年十二班","report_id":5},{"column_001":"97.23","column_002":"96.17","column_003":"97","column_004":"98.50","column_005":"100","column_006":"97.50","column_007":"99.85","column_008":"95.37","column_009":"91.94","column_010":"96.13","id":235,"main_id":215,"rep_org_code":"89","rep_org_name":"三年四班","report_id":5},{"column_001":"97.01","column_002":"92.18","column_003":"97.90","column_004":"98.50","column_005":"100","column_006":"96.57","column_007":"99.85","column_008":"97.69","column_009":"98.41","column_010":"98.77","id":236,"main_id":202,"rep_org_code":"247","rep_org_name":"三年五班","report_id":5},{"column_001":"95.36","column_002":"87.27","column_003":"98.55","column_004":"98","column_005":"100","column_006":"95.33","column_007":"98.68","column_008":"97.85","column_009":"92.16","column_010":"96.48","id":237,"main_id":203,"rep_org_code":"262","rep_org_name":"三年六班","report_id":5},{"column_001":"94.74","column_002":"83.24","column_003":"98.35","column_004":"98.50","column_005":"100","column_006":"94.03","column_007":"97.62","column_008":"96.81","column_009":"98.36","column_010":"97.60","id":238,"main_id":207,"rep_org_code":"702","rep_org_name":"三年十班","report_id":5},{"column_001":"92.15","column_002":"75.50","column_003":"96.50","column_004":"93.50","column_005":"100","column_006":"91.85","column_007":"97.56","column_008":"97.21","column_009":"97.22","column_010":"97.35","id":239,"main_id":220,"rep_org_code":"294","rep_org_name":"三年八班","report_id":5}]; 198 | var header_ = [{"checked":1,"cssstyle":"","headDesc":"三年级综合考试评定分析","id":502,"isleaf":"N","isopen":0,"level":"0","name":"三年级综合考试评定分析","pid":502,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"","id":503,"isleaf":"Y","isopen":0,"level":"1","name":"班级","pid":502,"reportColumnName":"rep_org_name","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"1210","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"80%A+20%B","id":504,"isleaf":"Y","isopen":0,"level":"1","name":"综合总分","pid":502,"reportColumnName":"column_001","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1211","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"","id":505,"isleaf":"N","isopen":0,"level":"1","name":"考核项目","pid":502,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"1212","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"描述","id":506,"isleaf":"N","isopen":0,"level":"2","name":"文化课程","pid":505,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"121210","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"语文分数","id":507,"isleaf":"Y","isopen":0,"level":"3","name":"语文","pid":506,"reportColumnName":"column_002","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121010","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"数学分数","id":508,"isleaf":"Y","isopen":0,"level":"3","name":"数学","pid":506,"reportColumnName":"column_003","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121011","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合科目分数","id":509,"isleaf":"Y","isopen":0,"level":"3","name":"综合科目","pid":506,"reportColumnName":"column_004","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121012","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"外语","id":510,"isleaf":"Y","isopen":0,"level":"3","name":"外语","pid":506,"reportColumnName":"column_005","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121013","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"文化课程综合评估分数","id":511,"isleaf":"Y","isopen":0,"level":"3","name":"文化总体","pid":506,"reportColumnName":"column_006","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121001","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合素质","id":512,"isleaf":"N","isopen":0,"level":"2","name":"综合素质","pid":505,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"121211","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"美术评定","id":513,"isleaf":"Y","isopen":0,"level":"3","name":"美术","pid":512,"reportColumnName":"column_007","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121110","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"体育评定","id":514,"isleaf":"N","isopen":0,"level":"3","name":"体育","pid":512,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121111","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"基本体测评定","id":515,"isleaf":"Y","isopen":0,"level":"4","name":"体能测试","pid":514,"reportColumnName":"column_008","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1212111110","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"体育考试评定","id":516,"isleaf":"Y","isopen":0,"level":"4","name":"体育考试","pid":514,"reportColumnName":"column_009","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1212111111","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合总体评定分数","id":517,"isleaf":"Y","isopen":0,"level":"3","name":"综合总体","pid":512,"reportColumnName":"column_010","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121101","type":"org_exam"}]; 199 | -------------------------------------------------------------------------------- /example/extend/export.js: -------------------------------------------------------------------------------- 1 | /** 2 | * autoHeader 应用 3 | * created by Finira 2016-1-11 4 | */ 5 | 6 | $(function(){ 7 | //返回列表按钮 8 | $('#backlist').on('click', function() { 9 | $('#listdiv').slideDown(); 10 | $('#viewdiv').slideUp(); 11 | }); 12 | //结果集树 13 | $.fn.zTree.init($("#treeDemo_org"), setting, treejson_); 14 | 15 | //筛选按钮 16 | $('#generator').on('click', function() { 17 | //获取表头筛选数据,重新生成table 18 | var treeObj = $.fn.zTree.getZTreeObj("header_tree"); 19 | var nodes = treeObj.getCheckedNodes(); 20 | var bodyjson_ = getSelectOrg(); 21 | initTable("tabled",nodes,bodyjson_); 22 | $("#containdivcnt").hide(); 23 | //统计总表清空 24 | $('#tabledcnt').empty(); 25 | //表头树默认缩回 26 | $('#headtre').slideUp(); 27 | $('#headerchoose').html(' 选择表头'); 28 | 29 | }); 30 | 31 | 32 | //最大化按钮功能 33 | $("#maxbt").on('click', function() { 34 | if(!ismax){ 35 | $('#refdiv').fadeOut(); 36 | $('#navs').fadeOut(); 37 | $('#alldiv').fadeIn(); 38 | $(this).html(' 回复原状'); 39 | //复制按钮和table的内容到alldiv 中 40 | $('#buttons').insertBefore('#dtiyp'); 41 | //增加导航css,滚动条滚动导航条不动 42 | $('#buttons').addClass('navbar-fixed-top'); 43 | $('#analyzz').insertAfter('#dtiyp'); 44 | $('#containdivcnt').insertAfter('#dtiyp'); 45 | $('body').attr('class','bodyafter'); 46 | ismax = true; 47 | }else{ 48 | //div隐藏关系改变,按钮和table内容重新复制回原来的位置 49 | $('#alldiv').fadeOut(); 50 | $('#navs').fadeIn(); 51 | $('#refdiv').fadeIn(); 52 | $('#buttons').insertBefore('#datev'); 53 | $('#analyzz').insertAfter('#tablepositonid'); 54 | $('#containdivcnt').insertAfter('#datev'); 55 | $('#buttons').removeClass('navbar-fixed-top'); 56 | $(this).html(' 最大化'); 57 | $('body').attr('class','bodypre'); 58 | ismax = false; 59 | } 60 | 61 | }); 62 | 63 | //表头树,按钮激发 64 | $('#headerchoose').on('click', function(e) { 65 | if($('#headtre').is(":hidden")){ 66 | $('#headtre').slideDown(); 67 | $(this).html(' 收回表头'); 68 | }else{ 69 | $('#headtre').slideUp(); 70 | $(this).html(' 选择表头'); 71 | } 72 | }); 73 | 74 | //导出Excel 75 | $("#export_excel").on('click', function() { 76 | $("#tabled").table2excel({ 77 | // 不被导出的表格行的CSS class类 78 | //exclude: ".noExl", 79 | // 导出的Excel文档的名称 80 | name: "autoHeader excel output result", 81 | // Excel文件的名称 82 | filename: "AH_output" 83 | }); 84 | }); 85 | 86 | }); 87 | 88 | 89 | 90 | /** 91 | * 根据选择的部门信息过滤数据包,将符合条件的留下 92 | */ 93 | function validateBodyJson(orgstr){ 94 | if(orgstr){ 95 | var newJson =[]; 96 | //循环json,获取上报部门ID字段 97 | $.each(bodyjson, function (j,itemj) { 98 | var orgcode = "_"+itemj.rep_org_code+"_"; 99 | //如果不在选中的部门ID范围内 则删除数据 100 | if(orgstr.indexOf(orgcode)>=0){ 101 | newJson.push(itemj); 102 | } 103 | }); 104 | return newJson; 105 | } 106 | } 107 | 108 | 109 | //定义树 110 | var setting = { 111 | check: { 112 | enable: true, 113 | chkboxType:{ "Y":"ps", "N":"ps"} 114 | 115 | }, 116 | data: { 117 | simpleData: { 118 | enable: true 119 | } 120 | } 121 | }; 122 | 123 | var code; 124 | var ismax=false; 125 | var treejson=null; 126 | var bodyjson = null; 127 | var currentJson =null; 128 | 129 | 130 | 131 | /** 132 | * 初始化表格方法 133 | */ 134 | function initTable(tableId,headstr,bodystr){ 135 | 136 | $.fn.autoHeader.init({ 137 | laynum:5, 138 | headJson:headstr, 139 | dataJson:bodystr, 140 | tableid:'tabled', 141 | needsort:true, 142 | columConfig:{ 143 | level:'lvl', 144 | showname:'viewname' 145 | }, 146 | cssConfig:{ 147 | table:' table-hover table-striped table-bordered table-responsive', 148 | tr:'' 149 | } 150 | }); 151 | } 152 | 153 | 154 | //表格初始化 155 | function showView(){ 156 | $('#listdiv').slideUp(); 157 | $('#viewdiv').slideDown(); 158 | var headjson_ = header_; 159 | var bodyjson_= dataer_; 160 | treejson = headjson_ ; 161 | currentJson = bodyjson = bodyjson_ ; 162 | initTable("tabled",headjson_,bodyjson_); 163 | $.fn.zTree.init($("#header_tree"), setting, treejson); 164 | 165 | } 166 | 167 | //获取已选结果集 168 | function getSelectOrg(){ 169 | var treeOrg = $.fn.zTree.getZTreeObj("treeDemo_org"); 170 | var orgnodes = treeOrg.getCheckedNodes(); 171 | 172 | var orgstr='_'; 173 | //循环遍历已选org 174 | $.each(orgnodes, function (i, item) { 175 | orgstr += item.id+"_"; 176 | }); 177 | var bodyjson_ = bodyjson; 178 | //如果有选择部门,就去筛选body数据 179 | if(orgstr!='_' ){ 180 | bodyjson_ = validateBodyJson(orgstr); 181 | } 182 | currentJson = bodyjson_; 183 | //console.log(JSON.stringify(currentJson) ); 184 | return bodyjson_; 185 | } 186 | 187 | 188 | 189 | var treejson_ = [{id:1, name: "三年级","isParent":1,"open":false}, 190 | {id:232, "pid":1, name: "三年一班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 191 | {id:240, "pid":1, name: "三年二班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 192 | {id:701, "pid":1, name: "三年三班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 193 | {id:89, "pid":1, name: "三年四班","open":false}, 194 | {id:247, "pid":1, name: "三年五班","open":false}, 195 | {id:262, "pid":1, name: "三年六班","open":false}, 196 | {id:281, "pid":1, name: "三年七班","open":false}, 197 | {id:294, "pid":1, name: "三年八班","open":false}, 198 | {id:313, "pid":1, name: "三年九班","open":false}, 199 | {id:702, "pid":1, name: "三年十班","open":false}, 200 | {id:703, "pid":1, name: "三年十一班","open":false}, 201 | {id:704, "pid":1, name: "三年十二班","open":false} 202 | 203 | ]; 204 | 205 | var dataer_ = [{"column_001":"99.41","column_002":"99.74","column_003":"98.90","column_004":"99","column_005":"100","column_006":"99.29","column_007":"99.70","column_008":"97.59","column_009":"99.10","column_010":"98.89","id":227,"main_id":214,"rep_org_code":"232","rep_org_name":"三年一班","report_id":5},{"column_001":"98.91","column_002":"99.39","column_003":"97.90","column_004":"99","column_005":"100","column_006":"98.89","column_007":"99.86","column_008":"98.01","column_009":"98.90","column_010":"99.02","id":228,"main_id":201,"rep_org_code":"240","rep_org_name":"三年二班","report_id":5},{"column_001":"98.78","column_002":"99.23","column_003":"98.30","column_004":"99","column_005":"100","column_006":"98.96","column_007":"99.88","column_008":"95.43","column_009":"98.28","column_010":"98.06","id":229,"main_id":208,"rep_org_code":"703","rep_org_name":"三年十一班","report_id":5},{"column_001":"97.98","column_002":"95.59","column_003":"98.10","column_004":"98.50","column_005":"100","column_006":"97.66","column_007":"100","column_008":"97.81","column_009":"99.78","column_010":"99.28","id":230,"main_id":206,"rep_org_code":"701","rep_org_name":"三年三班","report_id":5},{"column_001":"97.88","column_002":"96.49","column_003":"98.80","column_004":"99","column_005":"100","column_006":"98.29","column_007":"98.79","column_008":"97.16","column_009":"91.96","column_010":"96.25","id":231,"main_id":219,"rep_org_code":"281","rep_org_name":"三年七班","report_id":5},{"column_001":"97.84","column_002":"95.61","column_003":"97.95","column_004":"100","column_005":"100","column_006":"98.07","column_007":"97.37","column_008":"97.31","column_009":"95.89","column_010":"96.91","id":232,"main_id":205,"rep_org_code":"313","rep_org_name":"三年九班","report_id":5},{"column_001":"97.54","column_002":"95.13","column_003":"97.90","column_004":"98.50","column_005":"100","column_006":"97.46","column_007":"100","column_008":"96.28","column_009":"96.65","column_010":"97.88","id":233,"main_id":209,"rep_org_code":"704","rep_org_name":"三年十二班","report_id":5},{"column_001":"97.23","column_002":"96.17","column_003":"97","column_004":"98.50","column_005":"100","column_006":"97.50","column_007":"99.85","column_008":"95.37","column_009":"91.94","column_010":"96.13","id":235,"main_id":215,"rep_org_code":"89","rep_org_name":"三年四班","report_id":5},{"column_001":"97.01","column_002":"92.18","column_003":"97.90","column_004":"98.50","column_005":"100","column_006":"96.57","column_007":"99.85","column_008":"97.69","column_009":"98.41","column_010":"98.77","id":236,"main_id":202,"rep_org_code":"247","rep_org_name":"三年五班","report_id":5},{"column_001":"95.36","column_002":"87.27","column_003":"98.55","column_004":"98","column_005":"100","column_006":"95.33","column_007":"98.68","column_008":"97.85","column_009":"92.16","column_010":"96.48","id":237,"main_id":203,"rep_org_code":"262","rep_org_name":"三年六班","report_id":5},{"column_001":"94.74","column_002":"83.24","column_003":"98.35","column_004":"98.50","column_005":"100","column_006":"94.03","column_007":"97.62","column_008":"96.81","column_009":"98.36","column_010":"97.60","id":238,"main_id":207,"rep_org_code":"702","rep_org_name":"三年十班","report_id":5},{"column_001":"92.15","column_002":"75.50","column_003":"96.50","column_004":"93.50","column_005":"100","column_006":"91.85","column_007":"97.56","column_008":"97.21","column_009":"97.22","column_010":"97.35","id":239,"main_id":220,"rep_org_code":"294","rep_org_name":"三年八班","report_id":5}]; 206 | var header_ = [{"checked":1,"cssstyle":"","headDesc":"三年级综合考试评定分析","id":502,"isleaf":"N","isopen":0,"level":"0","name":"三年级综合考试评定分析","pid":502,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"","id":503,"isleaf":"Y","isopen":0,"level":"1","name":"班级","pid":502,"reportColumnName":"rep_org_name","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"1210","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"80%A+20%B","id":504,"isleaf":"Y","isopen":0,"level":"1","name":"综合总分","pid":502,"reportColumnName":"column_001","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1211","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"","id":505,"isleaf":"N","isopen":0,"level":"1","name":"考核项目","pid":502,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"1212","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"描述","id":506,"isleaf":"N","isopen":0,"level":"2","name":"文化课程","pid":505,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"121210","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"语文分数","id":507,"isleaf":"Y","isopen":0,"level":"3","name":"语文","pid":506,"reportColumnName":"column_002","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121010","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"数学分数","id":508,"isleaf":"Y","isopen":0,"level":"3","name":"数学","pid":506,"reportColumnName":"column_003","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121011","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合科目分数","id":509,"isleaf":"Y","isopen":0,"level":"3","name":"综合科目","pid":506,"reportColumnName":"column_004","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121012","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"外语","id":510,"isleaf":"Y","isopen":0,"level":"3","name":"外语","pid":506,"reportColumnName":"column_005","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121013","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"文化课程综合评估分数","id":511,"isleaf":"Y","isopen":0,"level":"3","name":"文化总体","pid":506,"reportColumnName":"column_006","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121001","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合素质","id":512,"isleaf":"N","isopen":0,"level":"2","name":"综合素质","pid":505,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"121211","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"美术评定","id":513,"isleaf":"Y","isopen":0,"level":"3","name":"美术","pid":512,"reportColumnName":"column_007","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121110","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"体育评定","id":514,"isleaf":"N","isopen":0,"level":"3","name":"体育","pid":512,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121111","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"基本体测评定","id":515,"isleaf":"Y","isopen":0,"level":"4","name":"体能测试","pid":514,"reportColumnName":"column_008","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1212111110","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"体育考试评定","id":516,"isleaf":"Y","isopen":0,"level":"4","name":"体育考试","pid":514,"reportColumnName":"column_009","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1212111111","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合总体评定分数","id":517,"isleaf":"Y","isopen":0,"level":"3","name":"综合总体","pid":512,"reportColumnName":"column_010","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121101","type":"org_exam"}]; 207 | -------------------------------------------------------------------------------- /example/base/description.js: -------------------------------------------------------------------------------- 1 | /** 2 | * autoHeader 应用 3 | * created by Finira 2016-1-11 4 | */ 5 | 6 | $(function(){ 7 | //返回列表按钮 8 | $('#backlist').on('click', function() { 9 | $('#listdiv').slideDown(); 10 | $('#viewdiv').slideUp(); 11 | }); 12 | //结果集树 13 | $.fn.zTree.init($("#treeDemo_org"), setting, treejson_); 14 | 15 | //筛选按钮 16 | $('#generator').on('click', function() { 17 | //获取表头筛选数据,重新生成table 18 | var treeObj = $.fn.zTree.getZTreeObj("header_tree"); 19 | var nodes = treeObj.getCheckedNodes(); 20 | var bodyjson_ = getSelectOrg(); 21 | initTable("tabled",nodes,bodyjson_); 22 | $("#containdivcnt").hide(); 23 | //统计总表清空 24 | $('#tabledcnt').empty(); 25 | //表头树默认缩回 26 | $('#headtre').slideUp(); 27 | $('#headerchoose').html(' 选择表头'); 28 | 29 | }); 30 | 31 | 32 | //最大化按钮功能 33 | $("#maxbt").on('click', function() { 34 | if(!ismax){ 35 | $('#refdiv').fadeOut(); 36 | $('#navs').fadeOut(); 37 | $('#alldiv').fadeIn(); 38 | $(this).html(' 回复原状'); 39 | //复制按钮和table的内容到alldiv 中 40 | $('#buttons').insertBefore('#dtiyp'); 41 | //增加导航css,滚动条滚动导航条不动 42 | $('#buttons').addClass('navbar-fixed-top'); 43 | $('#analyzz').insertAfter('#dtiyp'); 44 | $('#containdivcnt').insertAfter('#dtiyp'); 45 | $('body').attr('class','bodyafter'); 46 | ismax = true; 47 | }else{ 48 | //div隐藏关系改变,按钮和table内容重新复制回原来的位置 49 | $('#alldiv').fadeOut(); 50 | $('#navs').fadeIn(); 51 | $('#refdiv').fadeIn(); 52 | $('#buttons').insertBefore('#datev'); 53 | $('#analyzz').insertAfter('#tablepositonid'); 54 | $('#containdivcnt').insertAfter('#datev'); 55 | $('#buttons').removeClass('navbar-fixed-top'); 56 | $(this).html(' 最大化'); 57 | $('body').attr('class','bodypre'); 58 | ismax = false; 59 | } 60 | 61 | }); 62 | 63 | //表头树,按钮激发 64 | $('#headerchoose').on('click', function(e) { 65 | if($('#headtre').is(":hidden")){ 66 | $('#headtre').slideDown(); 67 | $(this).html(' 收回表头'); 68 | }else{ 69 | $('#headtre').slideUp(); 70 | $(this).html(' 选择表头'); 71 | } 72 | }); 73 | 74 | }); 75 | 76 | 77 | 78 | /** 79 | * 根据选择的部门信息过滤数据包,将符合条件的留下 80 | */ 81 | function validateBodyJson(orgstr){ 82 | if(orgstr){ 83 | var newJson =[]; 84 | //循环json,获取上报部门ID字段 85 | $.each(bodyjson, function (j,itemj) { 86 | var orgcode = "_"+itemj.rep_org_code+"_"; 87 | //如果不在选中的部门ID范围内 则删除数据 88 | if(orgstr.indexOf(orgcode)>=0){ 89 | newJson.push(itemj); 90 | } 91 | }); 92 | return newJson; 93 | } 94 | } 95 | 96 | 97 | //定义树 98 | var setting = { 99 | check: { 100 | enable: true, 101 | chkboxType:{ "Y":"ps", "N":"ps"} 102 | 103 | }, 104 | data: { 105 | simpleData: { 106 | enable: true 107 | } 108 | } 109 | }; 110 | 111 | var code; 112 | var ismax=false; 113 | var treejson=null; 114 | var bodyjson = null; 115 | var currentJson =null; 116 | 117 | 118 | 119 | /** 120 | * 初始化表格方法 121 | */ 122 | function initTable(tableId,headstr,bodystr){ 123 | 124 | $.fn.autoHeader.init({ 125 | laynum:5, 126 | headJson:headstr, 127 | dataJson:bodystr, 128 | tableid:'tabled', 129 | needsort:true, 130 | columConfig:{ 131 | level:'lvl', 132 | showname:'viewname' 133 | }, 134 | cssConfig:{ 135 | table:' table-hover table-striped table-bordered table-responsive', 136 | tr:'' 137 | }, 138 | descConfig:{ 139 | desc_type:'div', 140 | desc_th_class:'csshhn', 141 | enable:true, 142 | position:'fly',//div显示位置 有absolute和fly两种状态 absolute:div的位置是绝对值,以x和y作为起点。fly:div的位置以鼠标作为起点,x和y为偏移量 143 | pos_x:-100, 144 | pos_y:-100, 145 | showevent:'click' 146 | } 147 | }); 148 | } 149 | 150 | 151 | //表格初始化 152 | function showView(){ 153 | $('#listdiv').slideUp(); 154 | $('#viewdiv').slideDown(); 155 | var headjson_ = header_; 156 | var bodyjson_= dataer_; 157 | treejson = headjson_ ; 158 | currentJson = bodyjson = bodyjson_ ; 159 | initTable("tabled",headjson_,bodyjson_); 160 | $.fn.zTree.init($("#header_tree"), setting, treejson); 161 | 162 | } 163 | 164 | //获取已选结果集 165 | function getSelectOrg(){ 166 | var treeOrg = $.fn.zTree.getZTreeObj("treeDemo_org"); 167 | var orgnodes = treeOrg.getCheckedNodes(); 168 | 169 | var orgstr='_'; 170 | //循环遍历已选org 171 | $.each(orgnodes, function (i, item) { 172 | orgstr += item.id+"_"; 173 | }); 174 | var bodyjson_ = bodyjson; 175 | //如果有选择部门,就去筛选body数据 176 | if(orgstr!='_' ){ 177 | bodyjson_ = validateBodyJson(orgstr); 178 | } 179 | currentJson = bodyjson_; 180 | //console.log(JSON.stringify(currentJson) ); 181 | return bodyjson_; 182 | } 183 | 184 | 185 | 186 | var treejson_ = [{id:1, name: "三年级","isParent":1,"open":false}, 187 | {id:232, "pid":1, name: "三年一班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 188 | {id:240, "pid":1, name: "三年二班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 189 | {id:701, "pid":1, name: "三年三班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 190 | {id:89, "pid":1, name: "三年四班","open":false}, 191 | {id:247, "pid":1, name: "三年五班","open":false}, 192 | {id:262, "pid":1, name: "三年六班","open":false}, 193 | {id:281, "pid":1, name: "三年七班","open":false}, 194 | {id:294, "pid":1, name: "三年八班","open":false}, 195 | {id:313, "pid":1, name: "三年九班","open":false}, 196 | {id:702, "pid":1, name: "三年十班","open":false}, 197 | {id:703, "pid":1, name: "三年十一班","open":false}, 198 | {id:704, "pid":1, name: "三年十二班","open":false} 199 | 200 | ]; 201 | 202 | var dataer_ = [{"column_001":"99.41","column_002":"99.74","column_003":"98.90","column_004":"99","column_005":"100","column_006":"99.29","column_007":"99.70","column_008":"97.59","column_009":"99.10","column_010":"98.89","id":227,"main_id":214,"rep_org_code":"232","rep_org_name":"三年一班","report_id":5},{"column_001":"98.91","column_002":"99.39","column_003":"97.90","column_004":"99","column_005":"100","column_006":"98.89","column_007":"99.86","column_008":"98.01","column_009":"98.90","column_010":"99.02","id":228,"main_id":201,"rep_org_code":"240","rep_org_name":"三年二班","report_id":5},{"column_001":"98.78","column_002":"99.23","column_003":"98.30","column_004":"99","column_005":"100","column_006":"98.96","column_007":"99.88","column_008":"95.43","column_009":"98.28","column_010":"98.06","id":229,"main_id":208,"rep_org_code":"703","rep_org_name":"三年十一班","report_id":5},{"column_001":"97.98","column_002":"95.59","column_003":"98.10","column_004":"98.50","column_005":"100","column_006":"97.66","column_007":"100","column_008":"97.81","column_009":"99.78","column_010":"99.28","id":230,"main_id":206,"rep_org_code":"701","rep_org_name":"三年三班","report_id":5},{"column_001":"97.88","column_002":"96.49","column_003":"98.80","column_004":"99","column_005":"100","column_006":"98.29","column_007":"98.79","column_008":"97.16","column_009":"91.96","column_010":"96.25","id":231,"main_id":219,"rep_org_code":"281","rep_org_name":"三年七班","report_id":5},{"column_001":"97.84","column_002":"95.61","column_003":"97.95","column_004":"100","column_005":"100","column_006":"98.07","column_007":"97.37","column_008":"97.31","column_009":"95.89","column_010":"96.91","id":232,"main_id":205,"rep_org_code":"313","rep_org_name":"三年九班","report_id":5},{"column_001":"97.54","column_002":"95.13","column_003":"97.90","column_004":"98.50","column_005":"100","column_006":"97.46","column_007":"100","column_008":"96.28","column_009":"96.65","column_010":"97.88","id":233,"main_id":209,"rep_org_code":"704","rep_org_name":"三年十二班","report_id":5},{"column_001":"97.23","column_002":"96.17","column_003":"97","column_004":"98.50","column_005":"100","column_006":"97.50","column_007":"99.85","column_008":"95.37","column_009":"91.94","column_010":"96.13","id":235,"main_id":215,"rep_org_code":"89","rep_org_name":"三年四班","report_id":5},{"column_001":"97.01","column_002":"92.18","column_003":"97.90","column_004":"98.50","column_005":"100","column_006":"96.57","column_007":"99.85","column_008":"97.69","column_009":"98.41","column_010":"98.77","id":236,"main_id":202,"rep_org_code":"247","rep_org_name":"三年五班","report_id":5},{"column_001":"95.36","column_002":"87.27","column_003":"98.55","column_004":"98","column_005":"100","column_006":"95.33","column_007":"98.68","column_008":"97.85","column_009":"92.16","column_010":"96.48","id":237,"main_id":203,"rep_org_code":"262","rep_org_name":"三年六班","report_id":5},{"column_001":"94.74","column_002":"83.24","column_003":"98.35","column_004":"98.50","column_005":"100","column_006":"94.03","column_007":"97.62","column_008":"96.81","column_009":"98.36","column_010":"97.60","id":238,"main_id":207,"rep_org_code":"702","rep_org_name":"三年十班","report_id":5},{"column_001":"92.15","column_002":"75.50","column_003":"96.50","column_004":"93.50","column_005":"100","column_006":"91.85","column_007":"97.56","column_008":"97.21","column_009":"97.22","column_010":"97.35","id":239,"main_id":220,"rep_org_code":"294","rep_org_name":"三年八班","report_id":5}]; 203 | var header_ = [{"checked":1,"cssstyle":"","headDesc":"三年级综合考试评定分析","id":502,"isleaf":"N","isopen":0,"level":"0","name":"三年级综合考试评定分析","pid":502,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"","id":503,"isleaf":"Y","isopen":0,"level":"1","name":"班级","pid":502,"reportColumnName":"rep_org_name","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"1210","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"

                  支持p标签的自定义描述

                  综合总分:由文化总体和综合总体计算而来

                  数据提供部门:教导处

                  联系人:教导员 finira

                  ","id":504,"isleaf":"Y","isopen":0,"level":"1","name":"综合总分","pid":502,"reportColumnName":"column_001","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1211","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"","id":505,"isleaf":"N","isopen":0,"level":"1","name":"考核项目","pid":502,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"1212","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"描述","id":506,"isleaf":"N","isopen":0,"level":"2","name":"文化课程","pid":505,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"121210","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"语文分数","id":507,"isleaf":"Y","isopen":0,"level":"3","name":"语文","pid":506,"reportColumnName":"column_002","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121010","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"数学分数","id":508,"isleaf":"Y","isopen":0,"level":"3","name":"数学","pid":506,"reportColumnName":"column_003","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121011","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合科目分数","id":509,"isleaf":"Y","isopen":0,"level":"3","name":"综合科目","pid":506,"reportColumnName":"column_004","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121012","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"外语","id":510,"isleaf":"Y","isopen":0,"level":"3","name":"外语","pid":506,"reportColumnName":"column_005","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121013","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"文化课程综合评估分数","id":511,"isleaf":"Y","isopen":0,"level":"3","name":"文化总体","pid":506,"reportColumnName":"column_006","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121001","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合素质","id":512,"isleaf":"N","isopen":0,"level":"2","name":"综合素质","pid":505,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"121211","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"美术评定","id":513,"isleaf":"Y","isopen":0,"level":"3","name":"美术","pid":512,"reportColumnName":"column_007","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121110","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"体育评定","id":514,"isleaf":"N","isopen":0,"level":"3","name":"体育","pid":512,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121111","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"基本体测评定","id":515,"isleaf":"Y","isopen":0,"level":"4","name":"体能测试","pid":514,"reportColumnName":"column_008","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1212111110","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"体育考试评定","id":516,"isleaf":"Y","isopen":0,"level":"4","name":"体育考试","pid":514,"reportColumnName":"column_009","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1212111111","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合总体评定分数","id":517,"isleaf":"Y","isopen":0,"level":"3","name":"综合总体","pid":512,"reportColumnName":"column_010","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121101","type":"org_exam"}]; 204 | -------------------------------------------------------------------------------- /example/base/compare.js: -------------------------------------------------------------------------------- 1 | /** 2 | * autoHeader 应用 3 | * created by Finira 2016-1-11 4 | */ 5 | 6 | 7 | 8 | $(function(){ 9 | //返回列表按钮 10 | $('#backlist').on('click', function() { 11 | $('#listdiv').slideDown(); 12 | $('#viewdiv').slideUp(); 13 | }); 14 | 15 | $('#compare_tran').on('click', function(e) { 16 | $.fn.autoHeader.transCompare({anaJson:currentJson,baseJson:bodyjson,tableid:'tabled'}); 17 | $("#containdivcnt").show(); 18 | }); 19 | 20 | $.fn.zTree.init($("#treeDemo_org"), setting, treejson_); 21 | 22 | //筛选按钮 23 | $('#generator').on('click', function() { 24 | //获取表头筛选数据,重新生成table 25 | var treeObj = $.fn.zTree.getZTreeObj("header_tree"); 26 | var nodes = treeObj.getCheckedNodes(); 27 | var bodyjson_ = getSelectOrg(); 28 | initTable("tabled",nodes,bodyjson_); 29 | $("#containdivcnt").hide(); 30 | //统计总表清空 31 | $('#tabledcnt').empty(); 32 | //表头树默认缩回 33 | $('#headtre').slideUp(); 34 | $('#headerchoose').html(' 选择表头'); 35 | 36 | }); 37 | 38 | 39 | //最大化按钮功能 40 | $("#maxbt").on('click', function() { 41 | if(!ismax){ 42 | $('#refdiv').fadeOut(); 43 | $('#navs').fadeOut(); 44 | $('#alldiv').fadeIn(); 45 | $(this).html(' 回复原状'); 46 | //复制按钮和table的内容到alldiv 中 47 | $('#buttons').insertBefore('#dtiyp'); 48 | //增加导航css,滚动条滚动导航条不动 49 | $('#buttons').addClass('navbar-fixed-top'); 50 | $('#analyzz').insertAfter('#dtiyp'); 51 | $('#containdivcnt').insertAfter('#dtiyp'); 52 | $('body').attr('class','bodyafter'); 53 | ismax = true; 54 | }else{ 55 | //div隐藏关系改变,按钮和table内容重新复制回原来的位置 56 | $('#alldiv').fadeOut(); 57 | $('#navs').fadeIn(); 58 | $('#refdiv').fadeIn(); 59 | $('#buttons').insertBefore('#datev'); 60 | $('#analyzz').insertAfter('#tablepositonid'); 61 | $('#containdivcnt').insertAfter('#datev'); 62 | $('#buttons').removeClass('navbar-fixed-top'); 63 | $(this).html(' 最大化'); 64 | $('body').attr('class','bodypre'); 65 | ismax = false; 66 | } 67 | 68 | }); 69 | 70 | //表头树,按钮激发 71 | $('#headerchoose').on('click', function(e) { 72 | if($('#headtre').is(":hidden")){ 73 | $('#headtre').slideDown(); 74 | $(this).html(' 收回表头'); 75 | }else{ 76 | $('#headtre').slideUp(); 77 | $(this).html(' 选择表头'); 78 | } 79 | }); 80 | 81 | }); 82 | 83 | 84 | 85 | /** 86 | * 根据选择的部门信息过滤数据包,将符合条件的留下 87 | */ 88 | function validateBodyJson(orgstr){ 89 | if(orgstr){ 90 | var newJson =[]; 91 | //循环json,获取上报部门ID字段 92 | $.each(bodyjson, function (j,itemj) { 93 | var orgcode = "_"+itemj.rep_org_code+"_"; 94 | //如果不在选中的部门ID范围内 则删除数据 95 | if(orgstr.indexOf(orgcode)>=0){ 96 | newJson.push(itemj); 97 | } 98 | }); 99 | return newJson; 100 | } 101 | } 102 | 103 | 104 | //定义树 105 | var setting = { 106 | check: { 107 | enable: true, 108 | chkboxType:{ "Y":"ps", "N":"ps"} 109 | 110 | }, 111 | data: { 112 | simpleData: { 113 | enable: true 114 | } 115 | } 116 | }; 117 | 118 | var code; 119 | var ismax=false; 120 | var treejson=null; 121 | var bodyjson = null; 122 | var currentJson =null; 123 | 124 | 125 | 126 | /** 127 | * 初始化表格方法 128 | */ 129 | function initTable(tableId,headstr,bodystr){ 130 | 131 | $.fn.autoHeader.init({ 132 | laynum:5, 133 | headJson:headstr, 134 | dataJson:bodystr, 135 | tableid:'tabled', 136 | //caption:'报表展示标题', 137 | outspanid:'datev', 138 | //startlay:3, 139 | datamulti:30, 140 | debug:false, 141 | outspanid:'datev', 142 | needsort:true, 143 | columConfig:{ 144 | level:'lvl', 145 | showname:'viewname' 146 | }, 147 | cssConfig:{ 148 | table:' table-hover table-striped table-bordered table-responsive', 149 | tr:'' 150 | }, 151 | colConfig:{ 152 | transcomp:'transanalyzz' 153 | } 154 | }); 155 | } 156 | 157 | 158 | //表格初始化 159 | function showView(){ 160 | $('#listdiv').slideUp(); 161 | $('#viewdiv').slideDown(); 162 | var headjson_ = header_; 163 | var bodyjson_= dataer_; 164 | treejson = headjson_ ; 165 | currentJson = bodyjson = bodyjson_ ; 166 | initTable("tabled",headjson_,bodyjson_); 167 | $.fn.zTree.init($("#header_tree"), setting, treejson); 168 | 169 | } 170 | 171 | function getSelectOrg(){ 172 | var treeOrg = $.fn.zTree.getZTreeObj("treeDemo_org"); 173 | var orgnodes = treeOrg.getCheckedNodes(); 174 | 175 | var orgstr='_'; 176 | //循环遍历已选部门 打包部门ID 177 | $.each(orgnodes, function (i, item) { 178 | orgstr += item.id+"_"; 179 | }); 180 | var bodyjson_ = bodyjson; 181 | //如果有选择部门,就去筛选body数据 182 | if(orgstr!='_' ){ 183 | bodyjson_ = validateBodyJson(orgstr); 184 | } 185 | currentJson = bodyjson_; 186 | //console.log(JSON.stringify(currentJson) ); 187 | return bodyjson_; 188 | } 189 | 190 | 191 | 192 | var treejson_ = [{id:1, name: "三年级","isParent":1,"open":false}, 193 | {id:232, "pid":1, name: "三年一班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 194 | {id:240, "pid":1, name: "三年二班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 195 | {id:701, "pid":1, name: "三年三班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 196 | {id:89, "pid":1, name: "三年四班","open":false}, 197 | {id:247, "pid":1, name: "三年五班","open":false}, 198 | {id:262, "pid":1, name: "三年六班","open":false}, 199 | {id:281, "pid":1, name: "三年七班","open":false}, 200 | {id:294, "pid":1, name: "三年八班","open":false}, 201 | {id:313, "pid":1, name: "三年九班","open":false}, 202 | {id:702, "pid":1, name: "三年十班","open":false}, 203 | {id:703, "pid":1, name: "三年十一班","open":false}, 204 | {id:704, "pid":1, name: "三年十二班","open":false} 205 | 206 | ]; 207 | 208 | var dataer_ = [{"column_001":"99.21","column_002":"99.74","column_003":"98.90","column_004":"99","column_005":"100","column_006":"99.29","column_007":"99.70","column_008":"97.59","column_009":"99.10","column_010":"98.89","id":227,"main_id":214,"rep_org_code":"232","rep_org_name":"三年一班","report_id":5},{"column_001":"98.91","column_002":"99.39","column_003":"97.90","column_004":"99","column_005":"100","column_006":"98.89","column_007":"99.86","column_008":"98.01","column_009":"98.90","column_010":"99.02","id":228,"main_id":201,"rep_org_code":"240","rep_org_name":"三年二班","report_id":5},{"column_001":"98.78","column_002":"99.23","column_003":"98.30","column_004":"99","column_005":"100","column_006":"98.96","column_007":"99.88","column_008":"95.43","column_009":"98.28","column_010":"98.06","id":229,"main_id":208,"rep_org_code":"703","rep_org_name":"三年十一班","report_id":5},{"column_001":"97.98","column_002":"95.59","column_003":"98.10","column_004":"98.50","column_005":"100","column_006":"97.66","column_007":"100","column_008":"97.81","column_009":"99.78","column_010":"99.28","id":230,"main_id":206,"rep_org_code":"701","rep_org_name":"三年三班","report_id":5},{"column_001":"97.88","column_002":"96.49","column_003":"98.80","column_004":"99","column_005":"100","column_006":"98.29","column_007":"98.79","column_008":"97.16","column_009":"91.96","column_010":"96.25","id":231,"main_id":219,"rep_org_code":"281","rep_org_name":"三年七班","report_id":5},{"column_001":"97.84","column_002":"95.61","column_003":"97.95","column_004":"100","column_005":"100","column_006":"98.07","column_007":"97.37","column_008":"97.31","column_009":"95.89","column_010":"96.91","id":232,"main_id":205,"rep_org_code":"313","rep_org_name":"三年九班","report_id":5},{"column_001":"97.54","column_002":"95.13","column_003":"97.90","column_004":"98.50","column_005":"100","column_006":"97.46","column_007":"100","column_008":"96.28","column_009":"96.65","column_010":"97.88","id":233,"main_id":209,"rep_org_code":"704","rep_org_name":"三年十二班","report_id":5},{"column_001":"97.23","column_002":"96.17","column_003":"97","column_004":"98.50","column_005":"100","column_006":"97.50","column_007":"99.85","column_008":"95.37","column_009":"91.94","column_010":"96.13","id":235,"main_id":215,"rep_org_code":"89","rep_org_name":"三年四班","report_id":5},{"column_001":"97.01","column_002":"92.18","column_003":"97.90","column_004":"98.50","column_005":"100","column_006":"96.57","column_007":"99.85","column_008":"97.69","column_009":"98.41","column_010":"98.77","id":236,"main_id":202,"rep_org_code":"247","rep_org_name":"三年五班","report_id":5},{"column_001":"95.56","column_002":"87.87","column_003":"98.55","column_004":"98","column_005":"100","column_006":"95.33","column_007":"98.68","column_008":"97.85","column_009":"92.16","column_010":"96.48","id":237,"main_id":203,"rep_org_code":"262","rep_org_name":"三年六班","report_id":5},{"column_001":"94.74","column_002":"83.24","column_003":"98.35","column_004":"98.50","column_005":"100","column_006":"94.03","column_007":"97.62","column_008":"96.81","column_009":"98.36","column_010":"97.60","id":238,"main_id":207,"rep_org_code":"702","rep_org_name":"三年十班","report_id":5},{"column_001":"92.15","column_002":"75.50","column_003":"96.50","column_004":"97.50","column_005":"100","column_006":"90.85","column_007":"97.56","column_008":"97.21","column_009":"97.22","column_010":"97.35","id":239,"main_id":220,"rep_org_code":"294","rep_org_name":"三年八班","report_id":5}]; 209 | var header_ = [{"checked":1,"cssstyle":"","headDesc":"三年级综合考试评定分析","id":502,"isleaf":"N","isopen":0,"level":"0","name":"三年级综合考试评定分析","pid":502,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"","id":503,"isleaf":"Y","isopen":0,"level":"1","name":"班级","pid":502,"reportColumnName":"rep_org_name","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"1210","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"80%A+20%B","id":504,"isleaf":"Y","isopen":0,"level":"1","name":"综合总分","pid":502,"reportColumnName":"column_001","reportColumnType":"Number","sts":"Y","transanalyzz":"<95,yellow","treeCode":"1211","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"","id":505,"isleaf":"N","isopen":0,"level":"1","name":"考核项目","pid":502,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"1212","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"描述","id":506,"isleaf":"N","isopen":0,"level":"2","name":"文化课程","pid":505,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"121210","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"语文分数","id":507,"isleaf":"Y","isopen":0,"level":"3","name":"语文","pid":506,"reportColumnName":"column_002","reportColumnType":"String","sts":"Y","transanalyzz":"<90,red","treeCode":"12121010","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"数学分数","id":508,"isleaf":"Y","isopen":0,"level":"3","name":"数学","pid":506,"reportColumnName":"column_003","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121011","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合科目分数","id":509,"isleaf":"Y","isopen":0,"level":"3","name":"综合科目","pid":506,"reportColumnName":"column_004","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121012","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"外语","id":510,"isleaf":"Y","isopen":0,"level":"3","name":"外语","pid":506,"reportColumnName":"column_005","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121013","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"文化课程综合评估分数","id":511,"isleaf":"Y","isopen":0,"level":"3","name":"文化总体","pid":506,"reportColumnName":"column_006","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121001","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合素质","id":512,"isleaf":"N","isopen":0,"level":"2","name":"综合素质","pid":505,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"121211","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"美术评定","id":513,"isleaf":"Y","isopen":0,"level":"3","name":"美术","pid":512,"reportColumnName":"column_007","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121110","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"体育评定","id":514,"isleaf":"N","isopen":0,"level":"3","name":"体育","pid":512,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121111","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"基本体测评定","id":515,"isleaf":"Y","isopen":0,"level":"4","name":"体能测试","pid":514,"reportColumnName":"column_008","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1212111110","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"体育考试评定","id":516,"isleaf":"Y","isopen":0,"level":"4","name":"体育考试","pid":514,"reportColumnName":"column_009","reportColumnType":"Number","sts":"Y","transanalyzz":"<#column_008,red","treeCode":"1212111111","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合总体评定分数","id":517,"isleaf":"Y","isopen":0,"level":"3","name":"综合总体","pid":512,"reportColumnName":"column_010","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121101","type":"org_exam"}]; 210 | -------------------------------------------------------------------------------- /example/base/avg.js: -------------------------------------------------------------------------------- 1 | /** 2 | * autoHeader 应用 3 | * created by Finira 2016-1-11 4 | */ 5 | 6 | 7 | 8 | $(function(){ 9 | //返回列表按钮 10 | $('#backlist').on('click', function() { 11 | $('#listdiv').slideDown(); 12 | $('#viewdiv').slideUp(); 13 | }); 14 | $('#compare_avg').on('click', function(e) { 15 | $.fn.autoHeader.anaLyz({anaJson:currentJson,baseJson:bodyjson,anatype:'avg',tableid:'tabled',digit:2,compare:{enable:true}}); 16 | }); 17 | $('#compare_max').on('click', function(e) { 18 | $.fn.autoHeader.anaLyz({anaJson:currentJson,baseJson:bodyjson,anatype:'max',tableid:'tabled',digit:2,compare:{enable:true}}); 19 | }); 20 | $('#compare_min').on('click', function(e) { 21 | $.fn.autoHeader.anaLyz({anaJson:currentJson,baseJson:bodyjson,anatype:'min',tableid:'tabled',digit:2,compare:{enable:true}}); 22 | }); 23 | $('#compare_all').on('click', function(e) { 24 | $.fn.autoHeader.anaLyz({anaJson:currentJson,baseJson:bodyjson,anatype:'all',tableid:'tabled',digit:2,compare:{enable:true}}); 25 | }); 26 | 27 | $.fn.zTree.init($("#treeDemo_org"), setting, treejson_); 28 | 29 | //筛选按钮 30 | $('#generator').on('click', function() { 31 | //获取表头筛选数据,重新生成table 32 | var treeObj = $.fn.zTree.getZTreeObj("header_tree"); 33 | var nodes = treeObj.getCheckedNodes(); 34 | var bodyjson_ = getSelectOrg(); 35 | initTable("tabled",nodes,bodyjson_); 36 | $("#containdivcnt").hide(); 37 | //统计总表清空 38 | $('#tabledcnt').empty(); 39 | //表头树默认缩回 40 | $('#headtre').slideUp(); 41 | $('#headerchoose').html(' 选择表头'); 42 | 43 | }); 44 | 45 | 46 | //最大化按钮功能 47 | $("#maxbt").on('click', function() { 48 | if(!ismax){ 49 | $('#refdiv').fadeOut(); 50 | $('#navs').fadeOut(); 51 | $('#alldiv').fadeIn(); 52 | $(this).html(' 回复原状'); 53 | //复制按钮和table的内容到alldiv 中 54 | $('#buttons').insertBefore('#dtiyp'); 55 | //增加导航css,滚动条滚动导航条不动 56 | $('#buttons').addClass('navbar-fixed-top'); 57 | $('#analyzz').insertAfter('#dtiyp'); 58 | $('#containdivcnt').insertAfter('#dtiyp'); 59 | $('body').attr('class','bodyafter'); 60 | //$('#tabled').insertAfter('#tabledcnt'); 61 | //$('#container').insertAfter('#tabled'); 62 | ismax = true; 63 | }else{ 64 | //div隐藏关系改变,按钮和table内容重新复制回原来的位置 65 | $('#alldiv').fadeOut(); 66 | $('#navs').fadeIn(); 67 | $('#refdiv').fadeIn(); 68 | $('#buttons').insertBefore('#datev'); 69 | $('#analyzz').insertAfter('#tablepositonid'); 70 | $('#containdivcnt').insertAfter('#datev'); 71 | //$('#tabled').insertAfter('#tabledcnt'); 72 | //$('#container').insertAfter('#tabled'); 73 | $('#buttons').removeClass('navbar-fixed-top'); 74 | $(this).html(' 最大化'); 75 | $('body').attr('class','bodypre'); 76 | ismax = false; 77 | } 78 | 79 | }); 80 | 81 | //表头树,按钮激发 82 | $('#headerchoose').on('click', function(e) { 83 | if($('#headtre').is(":hidden")){ 84 | $('#headtre').slideDown(); 85 | $(this).html(' 收回表头'); 86 | }else{ 87 | $('#headtre').slideUp(); 88 | $(this).html(' 选择表头'); 89 | } 90 | }); 91 | 92 | }); 93 | 94 | 95 | 96 | /** 97 | * 根据选择的部门信息过滤数据包,将符合条件的留下 98 | */ 99 | function validateBodyJson(orgstr){ 100 | if(orgstr){ 101 | var newJson =[]; 102 | //循环json,获取上报部门ID字段 103 | $.each(bodyjson, function (j,itemj) { 104 | var orgcode = "_"+itemj.rep_org_code+"_"; 105 | //如果不在选中的部门ID范围内 则删除数据 106 | if(orgstr.indexOf(orgcode)>=0){ 107 | newJson.push(itemj); 108 | } 109 | }); 110 | return newJson; 111 | } 112 | } 113 | 114 | 115 | //定义树 116 | var setting = { 117 | check: { 118 | enable: true, 119 | chkboxType:{ "Y":"ps", "N":"ps"} 120 | 121 | }, 122 | data: { 123 | simpleData: { 124 | enable: true 125 | } 126 | } 127 | }; 128 | 129 | var code; 130 | var ismax=false; 131 | var treejson=null; 132 | var bodyjson = null; 133 | var currentJson =null; 134 | 135 | 136 | 137 | /** 138 | * 初始化表格方法 139 | */ 140 | function initTable(tableId,headstr,bodystr){ 141 | 142 | $.fn.autoHeader.init({ 143 | laynum:5, 144 | headJson:headstr, 145 | dataJson:bodystr, 146 | tableid:'tabled', 147 | needsort:true, 148 | cssConfig:{ 149 | table:' table-hover table-striped table-bordered table-responsive', 150 | tr:'' 151 | } 152 | }); 153 | } 154 | 155 | 156 | //表格初始化 157 | function showView(){ 158 | $('#listdiv').slideUp(); 159 | $('#viewdiv').slideDown(); 160 | var headjson_ = header_; 161 | var bodyjson_= dataer_; 162 | treejson = headjson_ ; 163 | currentJson = bodyjson = bodyjson_ ; 164 | initTable("tabled",headjson_,bodyjson_); 165 | $.fn.zTree.init($("#header_tree"), setting, treejson); 166 | 167 | } 168 | 169 | function getSelectOrg(){ 170 | var treeOrg = $.fn.zTree.getZTreeObj("treeDemo_org"); 171 | var orgnodes = treeOrg.getCheckedNodes(); 172 | 173 | var orgstr='_'; 174 | //循环遍历已选部门 打包部门ID 175 | $.each(orgnodes, function (i, item) { 176 | orgstr += item.id+"_"; 177 | }); 178 | var bodyjson_ = bodyjson; 179 | //如果有选择部门,就去筛选body数据 180 | if(orgstr!='_' ){ 181 | bodyjson_ = validateBodyJson(orgstr); 182 | } 183 | currentJson = bodyjson_; 184 | //console.log(JSON.stringify(currentJson) ); 185 | return bodyjson_; 186 | } 187 | 188 | 189 | 190 | var treejson_ = [{id:1, name: "三年级","isParent":1,"open":false}, 191 | {id:232, "pid":1, name: "三年一班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 192 | {id:240, "pid":1, name: "三年二班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 193 | {id:701, "pid":1, name: "三年三班","open":false,icon:"../../src/css/ztree/img/diy/2.png"}, 194 | {id:89, "pid":1, name: "三年四班","open":false}, 195 | {id:247, "pid":1, name: "三年五班","open":false}, 196 | {id:262, "pid":1, name: "三年六班","open":false}, 197 | {id:281, "pid":1, name: "三年七班","open":false}, 198 | {id:294, "pid":1, name: "三年八班","open":false}, 199 | {id:313, "pid":1, name: "三年九班","open":false}, 200 | {id:702, "pid":1, name: "三年十班","open":false}, 201 | {id:703, "pid":1, name: "三年十一班","open":false}, 202 | {id:704, "pid":1, name: "三年十二班","open":false} 203 | 204 | ]; 205 | 206 | var dataer_ = [{"column_001":"99.21","column_002":"99.74","column_003":"98.90","column_004":"99","column_005":"100","column_006":"99.29","column_007":"99.70","column_008":"97.59","column_009":"99.10","column_010":"98.89","id":227,"main_id":214,"rep_org_code":"232","rep_org_name":"三年一班","report_id":5},{"column_001":"98.91","column_002":"99.39","column_003":"97.90","column_004":"99","column_005":"100","column_006":"98.89","column_007":"99.86","column_008":"98.01","column_009":"98.90","column_010":"99.02","id":228,"main_id":201,"rep_org_code":"240","rep_org_name":"三年二班","report_id":5},{"column_001":"98.78","column_002":"99.23","column_003":"98.30","column_004":"99","column_005":"100","column_006":"98.96","column_007":"99.88","column_008":"95.43","column_009":"98.28","column_010":"98.06","id":229,"main_id":208,"rep_org_code":"703","rep_org_name":"三年十一班","report_id":5},{"column_001":"97.98","column_002":"95.59","column_003":"98.10","column_004":"98.50","column_005":"100","column_006":"97.66","column_007":"100","column_008":"97.81","column_009":"99.78","column_010":"99.28","id":230,"main_id":206,"rep_org_code":"701","rep_org_name":"三年三班","report_id":5},{"column_001":"97.88","column_002":"96.49","column_003":"98.80","column_004":"99","column_005":"100","column_006":"98.29","column_007":"98.79","column_008":"97.16","column_009":"91.96","column_010":"96.25","id":231,"main_id":219,"rep_org_code":"281","rep_org_name":"三年七班","report_id":5},{"column_001":"97.84","column_002":"95.61","column_003":"97.95","column_004":"100","column_005":"100","column_006":"98.07","column_007":"97.37","column_008":"97.31","column_009":"95.89","column_010":"96.91","id":232,"main_id":205,"rep_org_code":"313","rep_org_name":"三年九班","report_id":5},{"column_001":"97.54","column_002":"95.13","column_003":"97.90","column_004":"98.50","column_005":"100","column_006":"97.46","column_007":"100","column_008":"96.28","column_009":"96.65","column_010":"97.88","id":233,"main_id":209,"rep_org_code":"704","rep_org_name":"三年十二班","report_id":5},{"column_001":"97.23","column_002":"96.17","column_003":"97","column_004":"98.50","column_005":"100","column_006":"97.50","column_007":"99.85","column_008":"95.37","column_009":"91.94","column_010":"96.13","id":235,"main_id":215,"rep_org_code":"89","rep_org_name":"三年四班","report_id":5},{"column_001":"97.01","column_002":"92.18","column_003":"97.90","column_004":"98.50","column_005":"100","column_006":"96.57","column_007":"99.85","column_008":"97.69","column_009":"98.41","column_010":"98.77","id":236,"main_id":202,"rep_org_code":"247","rep_org_name":"三年五班","report_id":5},{"column_001":"95.56","column_002":"87.87","column_003":"98.55","column_004":"98","column_005":"100","column_006":"95.33","column_007":"98.68","column_008":"97.85","column_009":"92.16","column_010":"96.48","id":237,"main_id":203,"rep_org_code":"262","rep_org_name":"三年六班","report_id":5},{"column_001":"94.74","column_002":"83.24","column_003":"98.35","column_004":"98.50","column_005":"100","column_006":"94.03","column_007":"97.62","column_008":"96.81","column_009":"98.36","column_010":"97.60","id":238,"main_id":207,"rep_org_code":"702","rep_org_name":"三年十班","report_id":5},{"column_001":"92.15","column_002":"75.50","column_003":"96.50","column_004":"97.50","column_005":"100","column_006":"90.85","column_007":"97.56","column_008":"97.21","column_009":"97.22","column_010":"97.35","id":239,"main_id":220,"rep_org_code":"294","rep_org_name":"三年八班","report_id":5}]; 207 | var header_ = [{"checked":1,"cssstyle":"","headDesc":"三年级综合考试评定分析","id":502,"isleaf":"N","isopen":0,"level":"0","name":"三年级综合考试评定分析","pid":502,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"","id":503,"isleaf":"Y","isopen":0,"level":"1","name":"班级","pid":502,"reportColumnName":"rep_org_name","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"1210","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"80%A+20%B","id":504,"isleaf":"Y","isopen":0,"level":"1","name":"综合总分","pid":502,"reportColumnName":"column_001","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1211","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"","id":505,"isleaf":"N","isopen":0,"level":"1","name":"考核项目","pid":502,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"1212","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"描述","id":506,"isleaf":"N","isopen":0,"level":"2","name":"文化课程","pid":505,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"121210","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"语文分数","id":507,"isleaf":"Y","isopen":0,"level":"3","name":"语文","pid":506,"reportColumnName":"column_002","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121010","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"数学分数","id":508,"isleaf":"Y","isopen":0,"level":"3","name":"数学","pid":506,"reportColumnName":"column_003","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121011","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合科目分数","id":509,"isleaf":"Y","isopen":0,"level":"3","name":"综合科目","pid":506,"reportColumnName":"column_004","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121012","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"外语","id":510,"isleaf":"Y","isopen":0,"level":"3","name":"外语","pid":506,"reportColumnName":"column_005","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121013","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"文化课程综合评估分数","id":511,"isleaf":"Y","isopen":0,"level":"3","name":"文化总体","pid":506,"reportColumnName":"column_006","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121001","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合素质","id":512,"isleaf":"N","isopen":0,"level":"2","name":"综合素质","pid":505,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"121211","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"美术评定","id":513,"isleaf":"Y","isopen":0,"level":"3","name":"美术","pid":512,"reportColumnName":"column_007","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121110","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"体育评定","id":514,"isleaf":"N","isopen":0,"level":"3","name":"体育","pid":512,"reportColumnName":"","reportColumnType":"String","sts":"Y","transanalyzz":"","treeCode":"12121111","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"基本体测评定","id":515,"isleaf":"Y","isopen":0,"level":"4","name":"体能测试","pid":514,"reportColumnName":"column_008","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1212111110","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"体育考试评定","id":516,"isleaf":"Y","isopen":0,"level":"4","name":"体育考试","pid":514,"reportColumnName":"column_009","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"1212111111","type":"org_exam"},{"checked":1,"cssstyle":"","headDesc":"综合总体评定分数","id":517,"isleaf":"Y","isopen":0,"level":"3","name":"综合总体","pid":512,"reportColumnName":"column_010","reportColumnType":"Number","sts":"Y","transanalyzz":"","treeCode":"12121101","type":"org_exam"}]; 208 | -------------------------------------------------------------------------------- /src/js/highcharts-3d.js: -------------------------------------------------------------------------------- 1 | /* 2 | Highcharts JS v4.2.1 (2015-12-21) 3 | 4 | 3D features for Highcharts JS 5 | 6 | @license: www.highcharts.com/license 7 | */ 8 | (function(d){typeof module==="object"&&module.exports?module.exports=d:d(Highcharts)})(function(d){function r(c,b,a){var e,f,g=b.options.chart.options3d,d=!1;a?(d=b.inverted,a=b.plotWidth/2,b=b.plotHeight/2,e=g.depth/2,f=u(g.depth,1)*u(g.viewDistance,0)):(a=b.plotLeft+b.plotWidth/2,b=b.plotTop+b.plotHeight/2,e=g.depth/2,f=u(g.depth,1)*u(g.viewDistance,0));var j=[],k=a,i=b,l=e,w=f,a=A*(d?g.beta:-g.beta),g=A*(d?-g.alpha:g.alpha),o=p(a),q=m(a),n=p(g),y=m(g),x,s,z,t,v,C;B(c,function(a){x=(d?a.y:a.x)- 9 | k;s=(d?a.x:a.y)-i;z=(a.z||0)-l;t=q*x-o*z;v=-o*n*x+y*s-q*n*z;C=o*y*x+n*s+q*y*z;w>0&&wf&&g-f>o/2+1.0E-4?(k=k.concat(q(c, 10 | b,a,e,f,f+o/2,d,j)),k=k.concat(q(c,b,a,e,f+o/2,g,d,j))):go/2+1.0E-4?(k=k.concat(q(c,b,a,e,f,f-o/2,d,j)),k=k.concat(q(c,b,a,e,f-o/2,g,d,j))):(k=g-f,k=["C",c+a*m(f)-a*F*k*p(f)+d,b+e*p(f)+e*F*k*m(f)+j,c+a*m(g)+a*F*k*p(g)+d,b+e*p(g)-e*F*k*m(g)+j,c+a*m(g)+d,b+e*p(g)+j]);return k}function J(c){if(this.chart.is3d()){var b=this.chart.options.plotOptions.column.grouping;if(b!==void 0&&!b&&this.group.zIndex!==void 0&&!this.zIndexSet)this.group.attr({zIndex:this.group.zIndex*10}),this.zIndexSet=!0;var a= 11 | this.options,e=this.options.states;this.borderWidth=a.borderWidth=D(a.edgeWidth)?a.edgeWidth:1;d.each(this.data,function(b){if(b.y!==null)b=b.pointAttr,this.borderColor=d.pick(a.edgeColor,b[""].fill),b[""].stroke=this.borderColor,b.hover.stroke=d.pick(e.hover.edgeColor,this.borderColor),b.select.stroke=d.pick(e.select.edgeColor,this.borderColor)})}c.apply(this,[].slice.call(arguments,1))}var B=d.each,M=d.extend,N=d.inArray,G=d.merge,u=d.pick,K=d.wrap,o=Math.PI,A=o/180,p=Math.sin,m=Math.cos,L=Math.round; 12 | d.perspective=r;var F=4*(Math.sqrt(2)-1)/3/(o/2);d.SVGRenderer.prototype.toLinePath=function(c,b){var a=[];d.each(c,function(b){a.push("L",b.x,b.y)});c.length&&(a[0]="M",b&&a.push("Z"));return a};d.SVGRenderer.prototype.cuboid=function(c){var b=this.g(),c=this.cuboidPath(c);b.front=this.path(c[0]).attr({zIndex:c[3],"stroke-linejoin":"round"}).add(b);b.top=this.path(c[1]).attr({zIndex:c[4],"stroke-linejoin":"round"}).add(b);b.side=this.path(c[2]).attr({zIndex:c[5],"stroke-linejoin":"round"}).add(b); 13 | b.fillSetter=function(a){var b=d.Color(a).brighten(0.1).get(),c=d.Color(a).brighten(-0.1).get();this.front.attr({fill:a});this.top.attr({fill:b});this.side.attr({fill:c});this.color=a;return this};b.opacitySetter=function(a){this.front.attr({opacity:a});this.top.attr({opacity:a});this.side.attr({opacity:a});return this};b.attr=function(a){if(a.shapeArgs||D(a.x))a=this.renderer.cuboidPath(a.shapeArgs||a),this.front.attr({d:a[0],zIndex:a[3]}),this.top.attr({d:a[1],zIndex:a[4]}),this.side.attr({d:a[2], 14 | zIndex:a[5]});else return d.SVGElement.prototype.attr.call(this,a);return this};b.animate=function(a,b,c){D(a.x)&&D(a.y)?(a=this.renderer.cuboidPath(a),this.front.attr({zIndex:a[3]}).animate({d:a[0]},b,c),this.top.attr({zIndex:a[4]}).animate({d:a[1]},b,c),this.side.attr({zIndex:a[5]}).animate({d:a[2]},b,c),this.attr({zIndex:-a[6]})):a.opacity?(this.front.animate(a,b,c),this.top.animate(a,b,c),this.side.animate(a,b,c)):d.SVGElement.prototype.animate.call(this,a,b,c);return this};b.destroy=function(){this.front.destroy(); 15 | this.top.destroy();this.side.destroy();return null};b.attr({zIndex:-c[6]});return b};d.SVGRenderer.prototype.cuboidPath=function(c){function b(a){return i[a]}var a=c.x,e=c.y,f=c.z,g=c.height,h=c.width,j=c.depth,k=d.map,i=[{x:a,y:e,z:f},{x:a+h,y:e,z:f},{x:a+h,y:e+g,z:f},{x:a,y:e+g,z:f},{x:a,y:e+g,z:f+j},{x:a+h,y:e+g,z:f+j},{x:a+h,y:e,z:f+j},{x:a,y:e,z:f+j}],i=r(i,d.charts[this.chartIndex],c.insidePlotArea),f=function(a,c){var e=[],a=k(a,b),c=k(c,b);I(a)<0?e=a:I(c)<0&&(e=c);return e},c=f([3,2,1,0], 16 | [7,6,5,4]),a=[4,5,2,3],e=f([1,6,7,0],a),f=f([1,2,5,6],[0,7,4,3]);return[this.toLinePath(c,!0),this.toLinePath(e,!0),this.toLinePath(f,!0),E(c),E(e),E(f),E(k(a,b))*9E9]};d.SVGRenderer.prototype.arc3d=function(c){function b(a){var b=!1,c={},e;for(e in a)N(e,f)!==-1&&(c[e]=a[e],delete a[e],b=!0);return b?c:!1}var a=this.g(),e=a.renderer,f="x,y,r,innerR,start,end".split(","),c=G(c);c.alpha*=A;c.beta*=A;a.top=e.path();a.side1=e.path();a.side2=e.path();a.inn=e.path();a.out=e.path();a.onAdd=function(){var b= 17 | a.parentGroup;a.top.add(a);a.out.add(b);a.inn.add(b);a.side1.add(b);a.side2.add(b)};a.setPaths=function(b){var c=a.renderer.arc3dPath(b),e=c.zTop*100;a.attribs=b;a.top.attr({d:c.top,zIndex:c.zTop});a.inn.attr({d:c.inn,zIndex:c.zInn});a.out.attr({d:c.out,zIndex:c.zOut});a.side1.attr({d:c.side1,zIndex:c.zSide1});a.side2.attr({d:c.side2,zIndex:c.zSide2});a.zIndex=e;a.attr({zIndex:e});b.center&&(a.top.setRadialReference(b.center),delete b.center)};a.setPaths(c);a.fillSetter=function(a){var b=d.Color(a).brighten(-0.1).get(); 18 | this.fill=a;this.side1.attr({fill:b});this.side2.attr({fill:b});this.inn.attr({fill:b});this.out.attr({fill:b});this.top.attr({fill:a});return this};B(["opacity","translateX","translateY","visibility"],function(b){a[b+"Setter"]=function(b,c){a[c]=b;B(["out","inn","side1","side2","top"],function(e){a[e].attr(c,b)})}});K(a,"attr",function(c,e,d){var f;if(typeof e==="object"&&(f=b(e)))M(a.attribs,f),a.setPaths(a.attribs);return c.call(this,e,d)});K(a,"animate",function(a,c,e,d){var f,l=this.attribs, 19 | m;delete c.center;delete c.z;delete c.depth;delete c.alpha;delete c.beta;if(e=u(e,this.renderer.globalAnimation))if(typeof e!=="object"&&(e={}),c=G(c),f=b(c))m=f,e.step=function(a,b){function c(a){return l[a]+(u(m[a],l[a])-l[a])*b.pos}b.elem.setPaths(G(l,{x:c("x"),y:c("y"),r:c("r"),innerR:c("innerR"),start:c("start"),end:c("end")}))};return a.call(this,c,e,d)});a.destroy=function(){this.top.destroy();this.out.destroy();this.inn.destroy();this.side1.destroy();this.side2.destroy();d.SVGElement.prototype.destroy.call(this)}; 20 | a.hide=function(){this.top.hide();this.out.hide();this.inn.hide();this.side1.hide();this.side2.hide()};a.show=function(){this.top.show();this.out.show();this.inn.show();this.side1.show();this.side2.show()};return a};d.SVGRenderer.prototype.arc3dPath=function(c){function b(a){a%=2*o;a>o&&(a=2*o-a);return a}var a=c.x,e=c.y,d=c.start,g=c.end-1.0E-5,h=c.r,j=c.innerR,k=c.depth,i=c.alpha,l=c.beta,w=m(d),u=p(d),c=m(g),r=p(g),n=h*m(l);h*=m(i);var y=j*m(l),x=j*m(i),j=k*p(l),s=k*p(i),k=["M",a+n*w,e+h*u],k= 21 | k.concat(q(a,e,n,h,d,g,0,0)),k=k.concat(["L",a+y*c,e+x*r]),k=k.concat(q(a,e,y,x,g,d,0,0)),k=k.concat(["Z"]),z=l>0?o/2:0,l=i>0?0:o/2,z=d>-z?d:g>-z?-z:d,t=gv&&do-l&&d0?4:-1}).css({stroke:g.color}).add()):(e={x:l+(b.yAxis[0].opposite?0:-d.size),y:m+(b.xAxis[0].opposite?-g.size:0),z:j,width:i+d.size,height:k+g.size,depth:h.size,insidePlotArea:!1},this.backFrame?this.backFrame.animate(e):this.backFrame=a.cuboid(e).attr({fill:h.color,zIndex:-3}).css({stroke:h.color}).add(),b={x:l+(b.yAxis[0].opposite?i:-d.size),y:m+(b.xAxis[0].opposite?-g.size:0),z:0,width:d.size,height:k+g.size,depth:j, 29 | insidePlotArea:!1},this.sideFrame?this.sideFrame.animate(b):this.sideFrame=a.cuboid(b).attr({fill:d.color,zIndex:-2}).css({stroke:d.color}).add())}});d.wrap(d.Axis.prototype,"getPlotLinePath",function(c){var b=c.apply(this,[].slice.call(arguments,1));if(!this.chart.is3d())return b;if(b===null)return b;var a=this.chart,d=a.options.chart.options3d,a=this.isZAxis?a.plotWidth:d.depth,d=this.opposite;this.horiz&&(d=!d);b=[this.swapZ({x:b[1],y:b[2],z:d?a:0}),this.swapZ({x:b[1],y:b[2],z:a}),this.swapZ({x:b[4], 30 | y:b[5],z:a}),this.swapZ({x:b[4],y:b[5],z:d?0:a})];b=r(b,this.chart,!1);return b=this.chart.renderer.toLinePath(b,!1)});d.wrap(d.Axis.prototype,"getLinePath",function(c){return this.chart.is3d()?[]:c.apply(this,[].slice.call(arguments,1))});d.wrap(d.Axis.prototype,"getPlotBandPath",function(c){if(!this.chart.is3d())return c.apply(this,[].slice.call(arguments,1));var b=arguments,a=b[1],b=this.getPlotLinePath(b[2]);(a=this.getPlotLinePath(a))&&b?a.push("L",b[10],b[11],"L",b[7],b[8],"L",b[4],b[5],"L", 31 | b[1],b[2]):a=null;return a});d.wrap(d.Tick.prototype,"getMarkPath",function(c){var b=c.apply(this,[].slice.call(arguments,1));if(!this.axis.chart.is3d())return b;b=[this.axis.swapZ({x:b[1],y:b[2],z:0}),this.axis.swapZ({x:b[4],y:b[5],z:0})];b=r(b,this.axis.chart,!1);return b=["M",b[0].x,b[0].y,"L",b[1].x,b[1].y]});d.wrap(d.Tick.prototype,"getLabelPosition",function(c){var b=c.apply(this,[].slice.call(arguments,1));if(!this.axis.chart.is3d())return b;var a=r([this.axis.swapZ({x:b.x,y:b.y,z:0})],this.axis.chart, 32 | !1)[0];a.x-=!this.axis.horiz&&this.axis.opposite?this.axis.transA:0;a.old=b;return a});d.wrap(d.Tick.prototype,"handleOverflow",function(c,b){if(this.axis.chart.is3d())b=b.old;return c.call(this,b)});d.wrap(d.Axis.prototype,"getTitlePosition",function(c){var b=this.chart.is3d(),a,d;if(b)d=this.axisTitleMargin,this.axisTitleMargin=0;a=c.apply(this,[].slice.call(arguments,1));if(b)a=r([this.swapZ({x:a.x,y:a.y,z:0})],this.chart,!1)[0],a[this.horiz?"y":"x"]+=(this.horiz?1:-1)*(this.opposite?-1:1)*d,this.axisTitleMargin= 33 | d;return a});d.wrap(d.Axis.prototype,"drawCrosshair",function(c){var b=arguments;this.chart.is3d()&&b[2]&&(b[2]={plotX:b[2].plotXold||b[2].plotX,plotY:b[2].plotYold||b[2].plotY});c.apply(this,[].slice.call(b,1))});d.Axis.prototype.swapZ=function(c,b){if(this.isZAxis){var a=b?0:this.chart.plotLeft,d=this.chart;return{x:a+(d.yAxis[0].opposite?c.z:d.xAxis[0].width-c.z),y:c.y,z:c.x-a}}return c};var H=d.ZAxis=function(){this.isZAxis=!0;this.init.apply(this,arguments)};d.extend(H.prototype,d.Axis.prototype); 34 | d.extend(H.prototype,{setOptions:function(c){c=d.merge({offset:0,lineWidth:0},c);d.Axis.prototype.setOptions.call(this,c);this.coll="zAxis"},setAxisSize:function(){d.Axis.prototype.setAxisSize.call(this);this.width=this.len=this.chart.options.chart.options3d.depth;this.right=this.chart.chartWidth-this.width-this.left},getSeriesExtremes:function(){var c=this,b=c.chart;c.hasVisibleSeries=!1;c.dataMin=c.dataMax=c.ignoreMinPadding=c.ignoreMaxPadding=null;c.buildStacks&&c.buildStacks();d.each(c.series, 35 | function(a){if(a.visible||!b.options.chart.ignoreHiddenSeries)if(c.hasVisibleSeries=!0,a=a.zData,a.length)c.dataMin=Math.min(u(c.dataMin,a[0]),Math.min.apply(null,a)),c.dataMax=Math.max(u(c.dataMax,a[0]),Math.max.apply(null,a))})}});d.wrap(d.Chart.prototype,"getAxes",function(c){var b=this,a=this.options,a=a.zAxis=d.splat(a.zAxis||{});c.call(this);if(b.is3d())this.zAxis=[],d.each(a,function(a,c){a.index=c;a.isX=!0;(new H(b,a)).setScale()})});d.wrap(d.seriesTypes.column.prototype,"translate",function(c){c.apply(this, 36 | [].slice.call(arguments,1));if(this.chart.is3d()){var b=this.chart,a=this.options,e=a.depth||25,f=(a.stacking?a.stack||0:this._i)*(e+(a.groupZPadding||1));a.grouping!==!1&&(f=0);f+=a.groupZPadding||1;d.each(this.data,function(a){if(a.y!==null){var c=a.shapeArgs,d=a.tooltipPos;a.shapeType="cuboid";c.z=f;c.depth=e;c.insidePlotArea=!0;d=r([{x:d[0],y:d[1],z:f}],b,!1)[0];a.tooltipPos=[d.x,d.y]}});this.z=f}});d.wrap(d.seriesTypes.column.prototype,"animate",function(c){if(this.chart.is3d()){var b=arguments[1], 37 | a=this.yAxis,e=this,f=this.yAxis.reversed;if(d.svg)b?d.each(e.data,function(b){if(b.y!==null&&(b.height=b.shapeArgs.height,b.shapey=b.shapeArgs.y,b.shapeArgs.height=1,!f))b.shapeArgs.y=b.stackY?b.plotY+a.translate(b.stackY):b.plotY+(b.negative?-b.height:b.height)}):(d.each(e.data,function(a){if(a.y!==null)a.shapeArgs.height=a.height,a.shapeArgs.y=a.shapey,a.graphic&&a.graphic.animate(a.shapeArgs,e.options.animation)}),this.drawDataLabels(),e.animate=null)}else c.apply(this,[].slice.call(arguments, 38 | 1))});d.wrap(d.seriesTypes.column.prototype,"init",function(c){c.apply(this,[].slice.call(arguments,1));if(this.chart.is3d()){var b=this.options,a=b.grouping,d=b.stacking,f=u(this.yAxis.options.reversedStacks,!0),g=0;if(a===void 0||a){a=this.chart.retrieveStacks(d);g=b.stack||0;for(d=0;d=a.min&&g<=a.max:!1,e.push({x:f.plotX,y:f.plotY,z:f.plotZ});b=r(e,b,!0);for(h=0;h{point.x}
                  y: {point.y}
                  z: {point.z}
                  ":"x: {point.x}
                  y: {point.y}
                  z: {point.z}
                  ";return c});if(d.VMLRenderer)d.setOptions({animate:!1}),d.VMLRenderer.prototype.cuboid=d.SVGRenderer.prototype.cuboid, 47 | d.VMLRenderer.prototype.cuboidPath=d.SVGRenderer.prototype.cuboidPath,d.VMLRenderer.prototype.toLinePath=d.SVGRenderer.prototype.toLinePath,d.VMLRenderer.prototype.createElement3D=d.SVGRenderer.prototype.createElement3D,d.VMLRenderer.prototype.arc3d=function(c){c=d.SVGRenderer.prototype.arc3d.call(this,c);c.css({zIndex:c.zIndex});return c},d.VMLRenderer.prototype.arc3dPath=d.SVGRenderer.prototype.arc3dPath,d.wrap(d.Axis.prototype,"render",function(c){c.apply(this,[].slice.call(arguments,1));this.sideFrame&& 48 | (this.sideFrame.css({zIndex:0}),this.sideFrame.front.attr({fill:this.sideFrame.color}));this.bottomFrame&&(this.bottomFrame.css({zIndex:1}),this.bottomFrame.front.attr({fill:this.bottomFrame.color}));this.backFrame&&(this.backFrame.css({zIndex:0}),this.backFrame.front.attr({fill:this.backFrame.color}))})}); 49 | --------------------------------------------------------------------------------