123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813 |
- <%@ page language="java" contentType="text/html;charset=utf-8"%>
- <%@include file="/pages/includes/taglibs.jsp"%>
- <head>
- <script type="text/javascript"
- src="<%=request.getContextPath()%>/resource/js/jquery-1.8.3.js">
- </script>
- <link rel="stylesheet"
- href="<%=request.getContextPath()%>/resource/css/ztree/zTreeStyle.css"
- type="text/css">
- <script
- src="<%=request.getContextPath()%>/resource/js/ztree/jquery.ztree.all.min.js"
- type="text/javascript">
- </script>
- <script
- src="<%=request.getContextPath()%>/resource/js/datePicker/WdatePicker.js"
- type="text/javascript">
- </script>
- <script type="text/ecmascript"
- src="<%=request.getContextPath()%>/resource/plugin/jqgrid/js/jquery.jqGrid.min.js">
- </script>
- <script type="text/ecmascript"
- src="<%=request.getContextPath()%>/resource/plugin/jqgrid/js/i18n/grid.locale-cn.js">
- </script>
- <script type="text/ecmascript"
- src="<%=request.getContextPath()%>/resource/js/system/jqdatagrid.js">
- </script>
- <link rel="stylesheet" type="text/css"
- href="<%=request.getContextPath()%>/resource/plugin/jqueryui/css/custom-theme/jquery-ui-1.9.2.custom.css" />
- <link rel="stylesheet" type="text/css" media="screen"
- href="<%=request.getContextPath()%>/resource/plugin/jqgrid/css/ui.jqgrid.css" />
- <script
- src="<%=request.getContextPath()%>/resource/js/highcharts/highcharts.src.js"
- type="text/javascript">
- </script>
- <script
- src="<%=request.getContextPath()%>/resource/js/highcharts/highcharts-more.js">
- </script>
- <script type="text/javascript"
- src="<%=request.getContextPath()%>/resource/plugin/highslide/highslide-with-html.js">
- </script>
- <link rel="stylesheet" type="text/css"
- href="<%=request.getContextPath()%>/resource/plugin/highslide/highslide.css" />
- <style type="text/css">
- .normal {
- border-right-style: solid;
- border-bottom-style: solid;
- border-left-style: solid;
- border-top-style: solid;
- border-top-color: #ffffff;
- border-left-color: #f1f1f1;
- border-right-color: #f1f1f1;
- border-bottom-color: #f1f1f1;
- border-width: 1px;
- width: 100px;
- height: 28px;
- float: left;
- margin-top: -1px;
- cursor: pointer;
- text-align: center;
- line-height: 28px;
- overflow: hidden;
- font-weight: bold;
- font-size: 12px;
- font-family: tahoma, arial, verdana, sans-serif;
- }
- .disable {
- border-right-style: solid;
- border-bottom-style: solid;
- border-left-style: solid;
- border-top-style: solid;
- border-top-color: #f1f1f1;
- border-left-color: #f1f1f1;
- border-right-color: #f1f1f1;
- border-bottom-color: #f1f1f1;
- border-width: 1px;
- width: 100px;
- height: 25px;
- float: left;
- margin-top: -1px;
- cursor: pointer;
- text-align: center;
- background-color: #e1e1e1;
- line-height: 25px;
- overflow: hidden;
- font-weight: bold;
- font-size: 12px;
- font-family: tahoma, arial, verdana, sans-serif;
- }
- .panelcontainer {
- width: 100%;
- height: 70px;
- border-style: solid;
- border-color: #f1f1f1;
- border-width: 1px;
- }
- .panelquery {
- width: 100%;
- height: 25px;
- background-color: #f1f1f1;
- line-height: 25px;
- }
- .panelquerytext {
- margin-left: 3px;
- font-weight: bold;
- font-size: 12px;
- font-family: tahoma, arial, verdana, sans-serif;
- }
- .querycondcontainer {
- line-height: 39px;
- padding: 3px;
- float: left;
- font-size: 12px;
- }
- a { /* 统一设置所以样式 */
- font-family: Arial;
- font-size: 12px;
- text-align: center;
- margin: 3px;
- }
- a:link,a:visited { /* 超链接正常状态、被访问过的样式 */
- color: #000000;
- padding: 4px 10px 4px 10px;
- background-color: #f1f1f1;
- text-decoration: none;
- border-top: 1px solid #EEEEEE; /* 边框实现阴影效果 */
- border-left: 1px solid #EEEEEE;
- border-bottom: 1px solid #717171;
- border-right: 1px solid #717171;
- }
- a:hover { /* 鼠标指针经过时的超链接 */
- color: #821818; /* 改变文字颜色 */
- padding: 5px 8px 3px 12px; /* 改变文字位置 */
- background-color: #e2c4c9; /* 改变背景色 */
- border-top: 1px solid #717171; /* 边框变换,实现“按下去”的效果 */
- border-left: 1px solid #717171;
- border-bottom: 1px solid #EEEEEE;
- border-right: 1px solid #EEEEEE;
- }
- </style>
- <script type="text/javascript">
- hs.graphicsDir = '<%=request.getContextPath()%>/resource/plugin/highslide/graphics/';
- hs.outlineType = 'rounded-white';
- hs.wrapperClassName = 'draggable-header';
- var options2;
- var chart2;
- function showDiv() {
- var hc = $("#container");
- return hs.htmlExpand(hc[0], {
- contentId : "showDiv",
- width : 640,
- height : 480,
- align : 'center',
- headingText : '年单机等级信息对比'
- });
- }
- function getCheatName(gaid1, gaid2) {
- var year = $("#year").val();
- var tid = $("#tid").val();
- var url = 'chartqName.action?pid=' + gaid1;
- $.ajax( {
- type : "post",
- url : url,
- dataType : "json",
- success : function(data) {
- if (data.length != 0) {
- options2.xAxis.categories = eval(data);
- createPolarChat(gaid1, gaid2);
- }
- }
- });
- }
- function createPolarChat(gaid1, gaid2) {
- var url = "/gradeassessyear/chartqData.action?pid=" + gaid1;
- $.ajax( {
- url : url,
- type : "post",
- cache : false,
- dataType : "json",
- data : {},
- ifModified : false,
- success : function(result) {
- var value1 = [];
- if (result != null) {
- $.each(result, function(m, obj) {
- if (obj.value != null) {
-
- value1.push(parseFloat(obj.value));
- }
- });
- if (null != options2.series[0]) {
- options2.series[0].data = value1;
- url = "/gradeassessyear/chartqData.action?pid=" + gaid2;
- $.ajax( {
- url : url,
- type : "post",
- cache : false,
- dataType : "json",
- data : {},
- ifModified : false,
- success : function(result) {
- var value1 = [];
- if (result != null) {
- $.each(result, function(m, obj) {
- if (obj.value != null) {
- value1.push(parseFloat(obj.value));
- }
- });
- if (null != options2.series[1]) {
- options2.series[1].data = value1;
- chart2 = new Highcharts.Chart(options2);
- }
- }
- }
- });
- }
- }
- }
- });
- }
- function contrast() {
- var arr = $("#gridTable").jqGrid('getGridParam', 'selarrrow');
- var i = 0;
- var gaid1, gaid2;
- $.each(arr, function(n, value) {
- var temp = $("#gridTable").jqGrid('getCell', value, 'wtid');
- var tempgaid = $("#gridTable").jqGrid('getCell', value, 'id');
- if (i == 0) {
- wt1 = temp;
- gaid1 = tempgaid;
- options2.series[0].name = wt1;
- } else if (i == 1) {
- gaid2 = tempgaid;
- wt2 = temp;
- options2.series[1].name = wt2;
- }
- i++;
- })
- if (i > 2) {
- alert("一次最多能选择两台风机!");
- return false;
- } else if (i < 2) {
- alert("请选择两台风机!");
- return false;
- }
- getCheatName(gaid1, gaid2);
- showDiv();
- }
- var queryType = "fc";
- var setting = {
- check : {
- enable : true,
- chkStyle : "radio"
- },
- view : {
- dblClickExpand : false
- },
- data : {
- simpleData : {
- enable : true
- }
- },
- callback : {
- beforeClick : beforeClickWindfarm,
- onCheck : selectWindfarm
- },
- async : {
- enable : true,
- url : "/power/windfarmAjax.action",
- dataType : "json"
- }
- };
- function beforeClickWindfarm(treeId, treeNode) {
- var zTree = $.fn.zTree.getZTreeObj(treeId);
- zTree.checkNode(treeNode, !treeNode.checked, null, true);
- return false;
- }
- function showWindfarm() {
- var cityObj = $("#windfarm");
- var cityOffset = $("#windfarm").offset();
- $("#menuWindfarm").css( {
- left : cityOffset.left + "px",
- top : cityOffset.top + cityObj.outerHeight() + "px"
- }).slideDown("fast");
- $("body").bind("mousedown", onBodyDown);
- changeFc();
- }
- function showLine() {
- if (wpids == "") {
- alert("请选择风场!");
- return;
- }
- var setting1 = {
- check : {
- enable : true,
- chkStyle : "radio"
- },
- view : {
- dblClickExpand : false
- },
- data : {
- simpleData : {
- enable : true
- }
- },
- callback : {
- beforeClick : beforeClickWindfarm,
- onCheck : selectXl
- },
- async : {
- enable : true,
- url : "/power/lineAjax.action?wpIds=" + wpids,
- dataType : "json"
- }
- };
- $.fn.zTree.init($("#treeXl"), setting1);
- var cityObj = $("#line");
- var cityOffset = $("#line").offset();
- $("#menuXl").css( {
- left : cityOffset.left + "px",
- top : cityOffset.top + cityObj.outerHeight() + "px"
- }).slideDown("fast");
- $("body").bind("mousedown", onBodyDown);
- lines = '';
- $("#line").val("");
- changeFc();
- //$("#menuWindfarm").fadeOut("fas
- }
- function showProject() {
- if (wpids == "") {
- alert("请选择风场!");
- return;
- }
- var setting3 = {
- check : {
- enable : true,
- chkStyle : "radio"
- },
- view : {
- dblClickExpand : false
- },
- data : {
- simpleData : {
- enable : true
- }
- },
- callback : {
- beforeClick : beforeClickWindfarm,
- onCheck : selectPj
- },
- async : {
- enable : true,
- url : "/power/projectAjax.action?wpIds=" + wpids,
- dataType : "json"
- }
- };
- $.fn.zTree.init($("#treePj"), setting3);
- var cityObj = $("#project");
- var cityOffset = $("#project").offset();
- $("#menuPj").css( {
- left : cityOffset.left + "px",
- top : cityOffset.top + cityObj.outerHeight() + "px"
- }).slideDown("fast");
- $("body").bind("mousedown", onBodyDown);
- pjIds = '';
- $("#project").val("");
- changeFc();
- }
- function hideMenuWindfarm() {
- $("#menuWindfarm").fadeOut("fast");
- }
- var wpids = "";
- function selectWindfarm(e, treeId, treeNode) {
- var zTree = $.fn.zTree.getZTreeObj("treeWindfarm"), nodes = zTree
- .getCheckedNodes(true);
- v = "";
- d = "";
- for ( var i = 0, l = nodes.length; i < l; i++) {
- v += nodes[i].name + ",";
- d += nodes[i].id + ",";
- }
- if (v.length > 0)
- v = v.substring(0, v.length - 1);
- if (d.length > 0)
- d = d.substring(0, d.length - 1);
- wpids = d;
- var cityObj = $("#windfarm");
- cityObj.attr("value", v);
- lines = '';
- pjIds = '';
- $("#project").val("");
- $("#line").val("");
- changeFc();
- //$("#menuWindfarm").fadeOut("fast");
- }
- var lines = "";
- function selectXl(e, treeId, treeNode) {
- var zTree = $.fn.zTree.getZTreeObj("treeXl"), nodes = zTree
- .getCheckedNodes(true);
- v = "";
- d = "";
- for ( var i = 0, l = nodes.length; i < l; i++) {
- v += nodes[i].name + ",";
- d += nodes[i].id + ",";
- }
- if (v.length > 0)
- v = v.substring(0, v.length - 1);
- if (d.length > 0)
- d = d.substring(0, d.length - 1);
- lines = d;
- var cityObj = $("#line");
- cityObj.attr("value", v);
- changeFc();
- //$("#menuXl").fadeOut("fast");
- }
- var pjIds = "";
- function selectPj(e, treeId, treeNode) {
- var zTree = $.fn.zTree.getZTreeObj("treePj"), nodes = zTree
- .getCheckedNodes(true);
- v = "";
- d = "";
- for ( var i = 0, l = nodes.length; i < l; i++) {
- v += nodes[i].name + ",";
- d += nodes[i].id + ",";
- }
- if (v.length > 0)
- v = v.substring(0, v.length - 1);
- if (d.length > 0)
- d = d.substring(0, d.length - 1);
- pjIds = d;
- var cityObj = $("#project");
- cityObj.attr("value", v);
- changeFc();
- //$("#menuXl").fadeOut("fast");
- }
- function hideMenuPj() {
- $("#menuPj").fadeOut("fast");
- }
- function hideMenuXl() {
- $("#menuXl").fadeOut("fast");
- }
- $(document).ready(
- function() {
- $.fn.zTree.init($("#treeWindfarm"), setting);
- initial();
- var year = $("#year").val();
-
- var tid = $("#tid").val();
- var url = 'yearbacklist.action?tid=' + tid + '&wpid=' + wpids
- + '&pjid=' + pjIds + '&lnid=' + lines + '&year=' + year;
- getCol(url);
- });
- function getCol(url) {
- getColNames(url);
- }
- function getColNames(url1) {
- var year = $("#year").val();
- var tid = $("#tid").val();
- var url = 'yearColNames.action?tid=' + tid + '&wpid=' + wpids + '&pjid='
- + pjIds + '&lnid=' + lines + '&year=' + year ;
- $.ajax( {
- type : "post",
- url : url,
- dataType : "json",
- success : function(data) {
- if (data.length != 0) {
- getColModel(eval(data), url1)
- }
- }
- });
- }
- function getColModel(name, url1) {
- var year = $("#year").val();
- var tid = $("#tid").val();
- var url = 'yearColModel.action?tid=' + tid + '&wpid=' + wpids + '&pjid='
- + pjIds + '&lnid=' + lines + '&year=' + year ;
- $.ajax( {
- type : "post",
- url : url,
- dataType : "json",
- success : function(data) {
- if (data.length != 0) {
- eval(data);
- showJqGrid(url1, name, eval(data));
- }
- }
- });
- }
- function onBodyDown(event) {
- if ((event.target.id != "windfarm" && event.target.id != "menuWindfarm" && $(
- event.target).parents("#menuWindfarm").length <= 0)) {
- hideMenuWindfarm();
- }
- if (!(event.target.id == "line" || event.target.id == "menuXl" || $(
- event.target).parents("#menuXl").length > 0)) {
- hideMenuXl();
- }
- if (!(event.target.id == "project" || event.target.id == "menuPj" || $(
- event.target).parents("#menuPj").length > 0)) {
- hideMenuPj();
- }
- }
- function queryApData() {
- $("#gridTable").jqGrid('GridUnload');
- var year = $("#year").val();
-
- var tid = $("#tid").val();
- if (wpids == "") {
- alert("请选择风场!");
- return;
- }
- if (tid == "") {
- alert("请选择指标体系!");
- return;
- }
- if (year == "") {
- alert("请选择年份!");
- return;
- }
- var url = 'yearlist.action?tid=' + tid + '&wpid=' + wpids + '&pjid='
- + pjIds + '&lnid=' + lines + '&year=' + year ;
- getCol(url);
- }
- function showJqGrid(url, name, model) {
- var id = 'gridTable';
- var datatype = 'json';
- var colNames = name;
- var colModel = model;
- var caption = '年单机等级评估列表';
- var sortname = 'wtid';
- var gridPagerID = 'gridPager';
- var sortorder = 'desc';
- var height = 'auto';
- var width = 'auto';
- var rownumbers = true;
- var multiselect = true;
- myJqGrid(id, url, datatype, colNames, colModel, caption, sortname,
- gridPagerID, sortorder, height, width, multiselect, rownumbers);
- }
- function initial() {
- $("#year").val("<s:property value='year'/>");
-
-
- $("#windfarm").val("${wpname}");
- wpids='<s:property value='wpid'/>';
- $("#project").val("${pjname}");
- pjIds='<s:property value='pjid'/>';
- $("#line").val("${lnname}");
- lines='<s:property value='lnid'/>';
- changeFc();
- $("#tid").val("<s:property value='tid'/>");
- /******************************************玫瑰图1***********************************************/
- options2 = {
-
- chart: {
- renderTo : 'fzy1',
- polar: true,
- type: 'area'
- },
-
- title: {
- text: '',
- x: 0
- },
-
- pane: {
- size: '80%'
- },
-
- xAxis: {
- categories: [],
- tickmarkPlacement: 'on',
- lineWidth: 0
- },
-
- yAxis: {
- gridLineInterpolation: 'polygon',
- lineWidth: 0,
- min: 0
- },
-
- tooltip: {
- shared: true,
- pointFormat: '<span style="color:{series.color}"> <b>{point.y:,.0f}</b><br/>'
- },
-
-
- series: [{
- name: '',
- data: [],
- pointPlacement: 'on'
- },{
- name: '',
- data: [],
- pointPlacement: 'on'
- }]
- }
- /******************************************玫瑰图1***********************************************/
- }
- function changeFc(){
- var url1 = '/gradeassessyear/tsAjax.action?wpid=' + wpids+ '&pjid=' + pjIds+ '&lnid=' + lines;
- $.ajax({
- type:"post",
- url:url1,
- dataType:"json",
- success: function(data){
- if(data.length != 0){
- eval(data);
- $("#tid").empty();
- //$("#tid").append("<option value=''>请选择</option>");
-
- for(var i=0; i<data.length; i++){
- $("#tid").append("<option value='"+data[i].id+"'>"+data[i].name+"</option>");
- }
-
- }else{
- $("#tid").empty();
- //$("#tid").append("<option value=''>请选择</option>");
- }
- }
- });
-
-
- }
-
- function displaybuttons(cellvalue, options, rawObject) {
- var mr = "<input type='button' value='定量指标' onclick=mr('"
- + rawObject.id + "')>";
-
-
- var nr = "<input type='button' value='定性指标' onclick=nr('"
- + rawObject.id + "')>";
-
-
- return " \t" + mr + " \t"
- + nr;
- };
- function mr(pid) {
- $("#f1").attr("action", "/gradeassessyear/gayearmrindex.action?pid="+pid+'&wpid=' + wpids+ '&pjid=' + pjIds+ '&lnid=' + lines
- ).submit();
- }
- function nr(pid) {
- $("#f1").attr("action", "/gradeassessyear/gayearnrindex.action?pid="+pid+'&wpid=' + wpids+ '&pjid=' + pjIds+ '&lnid=' + lines
- ).submit();
- }
- </script>
- </head>
- <body>
- <form action="" method="post" id="f1" style="width: 1620px;">
- <div class="panelcontainer" style="width: 1620px;">
- <div class="panelquery">
- <span class="panelquerytext">年单机等级评估</span>
- </div>
- <div class="querycondcontainer">
- 风场:
- <input id="windfarm" type="text" readonly value=""
- style="width: 150px;" onclick="showWindfarm();" />
- </div>
- <div id="pjpanel" class="querycondcontainer">
- 项目:
- <input id="project" type="text" readonly value=""
- style="width: 150px;" onclick="showProject();" />
- </div>
- <div id="xlpanel" class="querycondcontainer">
- 线路:
- <input id="line" type="text" readonly value="" style="width: 150px;"
- onclick="showLine();" />
- </div>
- <div id="targetpanel" class="querycondcontainer">
- 指标模型:
- <s:select list="tsls" listKey="id" listValue="name" id="tid"
- name="tid"></s:select>
- </div>
- <div class="querycondcontainer">
- 年份:
- <input type="text" style="width: 150px;" class="Wdate"
- onFocus="WdatePicker({dateFmt:'yyyy',isShowWeek:true,readOnly:true})"
- id="year" name="year" />
- </div>
-
- <div
- style="float: left; line-height: 39px; margin-left: 20px; width: 80px;">
- </div>
- <div
- style="float: left; line-height: 39px; margin-left: 20px; width: 80px;">
- <input type="button" value="评估" onClick="queryApData()" />
- </div>
- <div
- style="float: left; line-height: 39px; margin-left: 20px; width: 80px;">
- <input type="button" value="对比" onClick="contrast()" />
- </div>
- </div>
- <div id="menuWindfarm" class="menuContent"
- style="overflow-y: scroll; overflow-x: auto; z-index: 9999; border: 1px solid #617775; background: #f0f6e4; display: none; position: absolute;">
- <ul id="treeWindfarm" class="ztree"
- style="margin-top: 0; width: 180px; height: 300px;"></ul>
- </div>
- <div id="menuPj" class="menuContent"
- style="overflow-y: scroll; overflow-x: auto; z-index: 9999; border: 1px solid #617775; background: #f0f6e4; display: none; position: absolute;">
- <ul id="treePj" class="ztree"
- style="margin-top: 0; width: 180px; height: 300px;"></ul>
- </div>
- <div id="menuXl" class="menuContent"
- style="overflow-y: scroll; overflow-x: auto; z-index: 9999; border: 1px solid #617775; background: #f0f6e4; display: none; position: absolute;">
- <ul id="treeXl" class="ztree"
- style="margin-top: 0; width: 180px; height: 300px;"></ul>
- </div>
- <table id='gridTable'>
- </table>
- <div class="highslide-html-content" id="showDiv" style="width: 640;height: 480">
- <div class="highslide-header">
- <ul>
- <li class="highslide-move">
- <a href="#" onclick="return false">Move</a>
- </li>
- <li class="highslide-close" style="width: 18px;height: 0px;">
- <a href="#" onclick="return hs.close(this)" style="width: 0px;height: 5px;"></a>
- </li>
- </ul>
- </div>
- <div class="highslide-body" id="container" style="width: 600px;height: 480">
- <div id="fzy1" ></div>
- </div>
- </div>
-
- </form>
- </body>
|