123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023 |
- <%@ page language="java" contentType="text/html;charset=utf-8" pageEncoding="UTF-8"%>
- <%@include file="/pages/includes/taglibs.jsp"%>
- <head>
- <script src="/resource/js/blockUI.js" type="text/javascript"></script>
- <script src="/resource/js/ks/ks-core.js" type="text/javascript"></script>
- <script src="/resource/js/ks/ks-validation.js" type="text/javascript"></script>
- <script src="<%=request.getContextPath()%>/resource/js/datePicker/WdatePicker.js" type="text/javascript"></script>
- <%-- <script type="text/javascript" src="<%=request.getContextPath() %>/resource/js/jquery-1.8.3.js"></script> --%>
- <style type="text/css">
- .overlay {
- position:absolute;
- opacity:0.07 !important;
- filter:alpha(opacity=7);
- cursor:wait;
- }
- div.field{ margin: 2px; padding-left: 10px; display: inline; float: left; min-width: 85px; }
- div.field input[type='radio'], div.field input[type='checkbox'], select, div.field label{ cursor: pointer; vertical-align:middle; }
- div.field input[type='radio']{ margin-top: 0px; }
- #f2 th{ text-align: center; width: 100px; }
- .clear{ clear: both; }
- #showInvlPanel th, showInvlPanel td{ text-align: center; }
- </style>
- <script type="text/javascript">
- var msgDialog, msg;
- // function thisPage(){
- // msgDialog.blockUI();
- // $("#f1").attr("action", "index.action").attr("validate", false).submit();
- // }
- // //全选
- // function selectAll(t) {
- // $("input[name='ids']").prop("checked", t.checked);
- // }
- /* -------------列表用 -----------*/
- // 更新停机原因
- function updateStopReason(){
- $.ajax({
- type: 'POST',
- url: "updateStopReason.action",
- data: $("#stopReasonDIv").serialize(),
- success: function(data){
- $("#f1").attr("action", "index.action").attr("validate", false).submit();
- },
- dataType: "json"
- });
- }
- //编辑受累原因
- function showStopReason(id,stopReason){
- $("#u_id").val(id);
- $("#u_stopReason").val(stopReason);
- $("#stopReasonPanel").blockUI();
- }
- // 查询
- function doQuery() {
- // $("#showMsg").blockUI();
- $("#f1").attr("action", "index.action").submit();
- }
- function selGoPage(dp) {
- $("#showMsg").blockUI();
- var selDate = dp.cal.getNewDateStr();
- $("#repDate").val(selDate);
- $("#f1").attr("action", "index.action").attr("validate", false).submit();
- }
- function goPage(days) {
- $("#showMsg").blockUI();
- var d = $("#repDate").val();
- $("#repDate").val(addDate(d, days));
- $("#f1").attr("action", "index.action").attr("validate", false).submit();
- }
- function addDate(date, days) {
- var d = new Date(date);
- d.setDate(d.getDate() + days);
- var month = d.getMonth() + 1;
- if(month < 10) {
- month = "0" + month;
- }
- var day = d.getDate();
- if(day < 10) {
- day = "0" + day;
- }
- return d.getFullYear() + '-' + month + '-' + day;
- }
- //添加受累
- function addInvl() {
- var station = $("#qStationId option:selected");
- if(station.val() != null && station.val() != "" && station.val().length > 0) {
-
- $("#addSpeed").hide();
- $("#addText").hide();
- $("#lossGenStation_tr").hide();
- $("#saveBtn").show();
- $("#editBtn").hide();
-
- $("#editDate").val($("#nowDate").val());
- $("#editDateLast").val($("#nowDateLast").val());
-
- $("#powerStationName").val(station.text());
- $("#powerStationId").val(station.val());
- $("#addInvlForm").blockUI();
- $("#addInvlForm .query-panel-header-text").html("新增受累");
- } else {
- alert("请选择风场!");
- }
- }
- // 导出数据
- function doExport(){
- $("#f1").attr("action", "./invl_export.action").submit();
- }
-
- //删除受累
- function delInvl(id) {
- msg.html("删除受累......");
- msgDialog.blockUI();
- if(confirm("删除受累?")) {
- $.post("./del.action", {id: id}, function(data){
- data = $.parseJSON(data);
- if(data.code == 111) {
- $("#f1").attr("action", "index.action").submit();
- } else {
- alert("删除受累失败!");
- msgDialog.unblockUI();
- return false;
- }
- });
- } else {
- msgDialog.unblockUI();
- }
- }
- //编辑受累
- function editInvl(invlId,lossGen,avgSpeed){
- $("#addInvlForm").blockUI();
- $("#addSpeed").show();
- $("#addText").show();
- $("#lossGenStation_tr").show();
- $("#saveBtn").hide();
- $("#editBtn").show();
-
- var station = $("#qStationId option:selected");
- $("#powerStationName").val(station.text());
- $("#powerStationId").val(station.val());
- $("#editInvlId").val(invlId);
- $("#lossGenStation").val(lossGen);
- $("#lossAvgSpeed").val(avgSpeed);
- $("#addInvlForm .query-panel-header-text").html("编辑受累");
-
- $.getJSON("getInvlEq.action", {id: invlId}, function(data) {
- if(data.code == "111") {
- var map = data.data;
- $.each(map.eqs, function(i, eq) {
- //期次
- $("#f2 input[name='repInvl.projectIds'][data_pid='"+ eq.projectId +"']").prop("checked", true);
- //线路
- $("#f2 input[name='repInvl.lineIds'][data_lid='"+ eq.lineId +"']").prop("checked", true);
- //风机
- $("#f2 input[name='repInvl.eqIds'][data_eid='"+ eq.equipmentId +"']").prop("checked", true);
- });
-
- //开始时间 beginTime
- $("#beginInvl").val(map.invl.beginTime);
- //结束时间 endTime
- $("#endInvl").val(map.invl.endTime);
-
- $("#editDate").val($("#nowDate").val());
- $("#editDateLast").val($("#nowDateLast").val());
-
- //停机类型 stopType
- if(map.invl.stopType=="计划"){
- $("#stopTypeJH").prop("checked",true);
- }else if(map.invl.stopType=="非计划"){
- $("#stopTypeFJH").prop("checked",true);
- }
- //停机原因 stopReason
- $("#stopReason").val(map.invl.stopReason);
-
- var type ;
- if(map.invl.type=="场外"){
- type="invl_out";
- }else if(map.invl.type=="场内"){
- type="invl_in";
- }
-
- $("#f2 input[name='repInvl.type'][data_type='"+type +"']").prop("checked",true);
-
- //var xb = $("#reasonType_xb");
- if(type == "invl_in") {
- $.getJSON("dic.action", {dicTypeId: "invl_in"}, function(data) {
- if(data.code == 111) {
- var rt = $("#reasonType");
- rt.html("");
- var html;
- $.each(data.data, function(i, e) {
- html = "";
- html += "<div class=\"field\">";
- html += "<label for=\"reasonType_"+ i +"\">";
- html += "<input type=\"radio\" class=\"required\" id=\"reasonType_"+ i +"\" name=\"repInvl.reasonType\" value=\""+ e +"\" />"+ e;
- html += "</label></div>";
- rt.append(html);
- });
- }
- //xb.show();
- $("#f2 input[name='repInvl.reasonType'][value='"+map.invl.reasonType +"']").prop("checked",true);
- });
- } else if(type == "invl_out") {
- $.getJSON("dic.action", {dicTypeId: "invl_out"}, function(data) {
- if(data.code == 111) {
- var rt = $("#reasonType");
- rt.html("");
- var html;
- $.each(data.data, function(i, e) {
- html = "";
- html += "<div class=\"field\">";
- html += "<label for=\"reasonType_"+ i +"\">";
- html += "<input type=\"radio\" class=\"required\" id=\"reasonType_"+ i +"\" name=\"repInvl.reasonType\" value=\""+ e +"\" />"+ e;
- html += "</label></div>";
- rt.append(html);
- });
- }
-
- $("#reasonType input[type='radio']").prop("checked", false);
- // $("#reasonType_xb input[type='radio']").prop("checked", false);
- // xb.hide();
- $("#f2 input[name='repInvl.reasonType'][value='"+map.invl.reasonType +"']").prop("checked",true);
- });
- } else {
- alert("无法获取受累类型");
- return false;
- }
-
-
- } else {
- alert(data.msg);
- }
- });
- }
- //完成受累
- function completeInvl(invlId, type, begin,staId,staName) {
- $("#completePanel").blockUI();
- $("#cpPSName").val(staName);
- $("#cpPSId").val(staId);
- $("#cpInvlId").val(invlId);
- $("#cpReasonType").val(type);
- $("#cpBegin").val(begin);
-
- if(type=="场内"){
- $("#domLoss").hide();
- $("#textLoss").hide();
- }else if(type="场外"){
- $("#domLoss").show();
- $("#textLoss").show();
- }
- }
- //显示受累风机
- function showInvlEq(invlId,staId,staName) {
- $("#showInvlPanel").blockUI();
-
- $("#showBegin").empty();
- $("#showEnd").empty();
- $("#showEqCount").empty();
- $("#showEqList").empty();
-
- //var station = $("#qStationId option:selected");
- $("#showPSName").val(staName);
-
- $.getJSON("getInvlEq.action", {id: invlId}, function(data) {
- if(data.code == "111") {
- var map = data.data;
- $("#showBegin").html(map.begin);
- $("#showEnd").html(map.end);
- $("#showEqCount").html(map.eqCount + " 台");
-
- var box = $("#showEqList");
- var lossGen = 0;
- $.each(map.eqs, function(i, eq) {
- var html = "<div class='field'><label title='风机【"+ eq.equipmentCode +"】损失电量【"+ eq.lossGen.toFixed(2) +" kWh】'>"+
- eq.equipmentCode + "【<font style='color: red;'>"+ eq.lossGen.toFixed(2) +"</font> kWh】</label></div>";
- box.append(html);
- lossGen += eq.lossGen;
- });
- $("#showLossGen").html("<font style='color: red;'>" + lossGen.toFixed(2) + "</font> kWh ");
- } else {
- alert(data.msg);
- }
- });
- }
- /*---------新增受累------- */
- $(function(){
- //消息框
- msgDialog = $("#showMsg");
- msg = $("#showMsgContent");
-
- //点选期次
- $("#f2 input[name='repInvl.projectIds']").click(function() {
- var pid = $(this).attr("data_pid");
- var ck = $(this).prop("checked");
- //线路
- $("#f2 input[name='repInvl.lineIds'][data_pid='"+ pid +"']").prop("checked", ck);
- //风机
- $("#f2 input[name='repInvl.eqIds'][data_pid='"+ pid +"']").prop("checked", ck);
- });
- //点选线路
- $("#f2 input[name='repInvl.lineIds']").click(function() {
- var t = $(this);
- var lid = t.attr("data_lid");
- //风机
- $("#f2 input[name='repInvl.eqIds'][data_lid='"+ lid +"']").prop("checked", t.prop("checked"));
- //期次
- var pid = t.attr("data_pid");
- var pids = $("#f2 input[name='repInvl.lineIds'][data_pid='"+ pid +"']:checked");
- if(pids.length > 0) {
- $("#proj_" + pid).prop("checked", true);
- } else {
- $("#proj_" + pid).prop("checked", false);
- }
- });
- //点选风机
- $("#f2 input[name='repInvl.eqIds']").click(function() {
- var t = $(this);
- var lid = t.attr("data_lid");
- var pid = t.attr("data_pid");
- //线路
- var lids = $("#f2 input[name='repInvl.eqIds'][data_pid='"+ pid +"'][data_lid='"+ lid +"']:checked");
- if(lids.length > 0) {
- $("#line_" + lid).prop("checked", true);
- $("#proj_" + pid).prop("checked", true);
- } else {
- $("#line_" + lid).prop("checked", false);
- //判断line的数量
- $("#proj_" + pid).prop("checked", false);
- }
- });
- //受累类型
- $("#typeIn, #typeOut").click(function() {
- var type = $(this).attr("data_type");
- //var xb = $("#reasonType_xb");
- if(type == "invl_in") {
- $.getJSON("dic.action", {dicTypeId: "invl_in"}, function(data) {
- invlReason(data);
- // xb.show();
- });
- $("#lossGenStation_tr").hide();
- } else if(type == "invl_out") {
- $.getJSON("dic.action", {dicTypeId: "invl_out"}, function(data) {
- invlReason(data);
-
- $("#reasonType input[type='radio']").prop("checked", false);
- //$("#reasonType_xb input[type='radio']").prop("checked", false);
- //xb.hide();
- });
- } else {
- alert("无法获取受累类型");
- return false;
- }
- });
-
- //受累原因
- function invlReason(data) {
- if(data.code == 111) {
- var rt = $("#reasonType");
- rt.html("");
- var html;
- $.each(data.data, function(i, e) {
- html = "";
- html += "<div class=\"field\">";
- html += "<input type=\"radio\" class=\"required\" id=\"reasonType_"+ i +"\" name=\"repInvl.reasonType\" value=\""+ i +"\" />";
- html += "<label for=\"reasonType_"+ i +"\">"+ e +"</label>";
- html += "</div>";
- rt.append(html);
- });
- }
- }
- });
- //确认1
- function btnEdit() {
- if(editValid() == true) {
- $("#f2").attr("action", "./edit.action").submit();
- }
- }
- //确认2
- function btnSave() {
- if(addValid() == true) {
- $("#saveBtn").attr('disabled',"true");
- $("#f2").attr("action", "./save.action").submit();
- }
- }
- /*--------受累完成--------------*/
- // 保存
- function completeSave() {
- if(completeValid() == true) {
- $("#invlCompleteForm").attr("action", "./completeSave.action").submit();
- }
- }
- //取消
- function btnCancel(){
- clearForm("f2");
- $("#addInvlForm").unblockUI();
- }
- //清空表单
- function clearForm(formId) {
- $(":input", "#"+ formId).not(":button, :submit, :reset, :hidden").val("").removeAttr('checked').removeAttr('selected');
- }
- function checkTime(){
- if($("#endInvl").val()!=null){
- $().blockUI();
- }
- }
- //表单验证
- function addValid() {
- if(checkEq() && begin() && type() && reasonType() && stopType() && stopReason()) {
- return true;
- }
- return false;
- }
- //表单验证
- function editValid() {
- if(checkEq() && begin() &&lossGenStation() && type() && reasonType() && stopType() && stopReason() && speed()) {
- return true;
- }
- return false;
- }
- function completeValid(){
- if(stop()) {
- return true;
- }
- return false;
- }
- //========= 受累完成验证 begin ============
- // 开始时间 cpBegin
- // 结束时间 cpEnd
- // 平均风速 cpSpeed
- // 损失电量 cpLossGen
- //========= 受累完成验证 end ============
- //========= 受累添加验证 begin ============
- //风机
- function checkEq() {
- if($("input[name='repInvl.eqIds']:checked").length > 0) {
- return true;
- }
- showValidMsg("请选择受累风机", $("input[name='repInvl.eqIds']")[0]);
- return false;
- }
- //开始时间
- function begin() {
- if($("#beginInvl").val() != "") {
- return true;
- }
- showValidMsg("请填写开始时间",$("#beginInvl"));
- return false;
- }
- //受累类型
- function type() {
- if($("input[name='repInvl.type']:checked").length == 1) {
- return true;
- }
- showValidMsg("请填选择受累类型", $("input[name='repInvl.type']")[0]);
- return false;
- }
- //损失电量
- function lossGenStation() {
-
- if($("#typeOut").prop("checked") == true && $("#lossGenStation").val() != "") {
- return true;
- } else if($("#typeIn").prop("checked") == true) {
- return true;
- }else if($("#lossGenStation").val() != ""){
- return true;
- }
-
- return false;
- }
- //受累原因
- function reasonType() {
- if($("input[name='repInvl.reasonType']:checked").length == 1) {
- return true;
- }
- showValidMsg("请填选择受累原因", $("input[name='repInvl.reasonType']")[0]);
- return false;
- }
- //停机类型
- function stopType() {
- if($("input[name='repInvl.stopType']:checked").length == 1) {
- return true;
- }
- showValidMsg("请填选择停机类型", $("input[name='repInvl.stopType']")[0]);
- return false;
- }
- //停机原因
- function stopReason() {
- if($("#stopReason").val() != "") {
- return true;
- }
- showValidMsg("请填写停机原因", $("#stopReason"));
- return false;
- }
- //平均风速
- function speed(msg, focus) {
- if($("#lossAvgSpeed").val() != "") {
- return true;
- }
- showValidMsg("请填写平均风速", $("#cpSpeed"));
- return false;
- }
- //显示错误信息
- function showValidMsg(msg, focus) {
- if(focus != null && focus != undefined && focus != "undefined" && focus != "" ) {
- focus.focus();
- }
- msg = "验证失败:" + msg;
- $("#err_container").text(msg).show().delay(3000).fadeOut(300);
- }
- /* ----------------- */
- //结束时间
- function stop() {
- if($("#cpEnd").val() != ""){
- return true;
- }
-
- showOverValidMsg("请填写结束时间",$("#cpEnd"));
- return false;
- }
- //显示错误信息2
- function showOverValidMsg(msg, focus) {
- if(focus != null && focus != undefined && focus != "undefined" && focus != "" ) {
- focus.focus();
- }
- msg = "验证失败:" + msg;
- $("#cp_err_container").text(msg).show().delay(3000).fadeOut(300);
- }
- </script>
- </head>
- <body>
- <s:form method="post" id="f1" >
- <fieldset id="fst" style="width: 1980px" >
- <legend class="item_Name">查询条件</legend>
- <table class="dataform" >
- <tr>
- <td align="left" >
- <span style="margin-right: 15px;">
- 选择风场:
- <s:select id="qStationId" list="stations" listKey="id" name="powerStationId" listValue="name" headerKey="" headerValue="请选择" onchange="doQuery()"></s:select>
- </span>
- <span>
- <input id="nowDate" name="nowDate" type="hidden" value='<s:date name="nowDate" format="yyyy-MM-dd HH:mm:ss"/>'/>
- <input id="nowDateLast" name="nowDateLast" type="hidden" value='<s:date name="nowDateLast" format="yyyy-MM-dd HH:mm:ss"/>'/>
- 选择日期:
- <a href="#" onclick="javascript:goPage(-1);">前一天</a>
-
- <input type="text" class="Wdate" id="repDate" name="repDate" value='<s:date name="repDate" format="yyyy-MM-dd"/>'
- onFocus="WdatePicker({dateFmt:'yyyy-MM-dd',isShowWeek:true,readOnly:true,onpicked:selGoPage})" title="选择时间" style="width: 100px;" />
-
- <a href="#" onclick="javascript:goPage(1);">后一天</a>
- </span>
- <span style="margin-right: 15px;">
-
- 选择类型:
- <s:select id="type" list="#{'':'请选择', '场内':'场内','场外':'场外'}" name="type" onchange="doQuery()"/>
- </span>
- <span style="margin-right: 15px;">
-
- 选择停机类型:
- <s:select id="stopType" list="#{'':'请选择', '计划':'计划','非计划':'非计划'}" name="stopType" onchange="doQuery()"/>
- </span>
-
- <a href="#" onclick="javascript:addInvl();">新增受累</a>
- </td>
- <!-- <td width="10%"></td> -->
- <!-- <td width="23%"></td> -->
- </tr>
- </table>
- </fieldset>
- <br/>
- <div id="tb1" style="height: 80px;width: 2008px" style="overflow-x:scroll;overflow-y:scroll">
- <table border="1" cellspacing="0" cellpadding="0" style="border-collapse: collapse; border-color:graytext;width: 100%">
- <thead>
- <tr>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:30px;">序号</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">操作</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">状态</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">风场</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">受累期次</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">受累线路</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">风机</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">类型</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">受累原因</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">停机类型</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">停机原因</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">实际开始时间<br>(h)</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">当天开始时间<br>(h)</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">当天结束时间<br>(h)</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">持续时间<br>(h)</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">平均风速<br>(m/s)</th>
- <th style="text-align: center; font-weight: bolder; font-size: 14px; width:80px;">损失电量<br>(kWh)</th>
- </tr>
- </thead>
- <tbody>
- <s:iterator value="listInvl" var="var" status="index">
- <tr>
- <td style="text-align: center; width:40px;">${index.index+1}</td>
- <%-- <td class="ui-state-default ui-th-column ui-th-ltr" style="text-align: center; width:300px;">${index.index+1}</td> --%>
-
- <td style="text-align: center; width:80px;">
- <s:if test="%{!isFengChang}">
- <a href="javascript:void(0);" onclick="javascript:delInvl('${id}');">删除</a>
- </s:if>
- <%-- <s:if test="endTime == null"> --%>
- <%-- <a href="javascript:void(0);" onclick="javascript:completeInvl('${id}', '${type}', '<s:date name="beginTime" format="yyyy-MM-dd HH:mm:ss"/>','${powerStationId}','${var.powerStationName}');">受累完成</a> --%>
- <%-- </s:if> --%>
- </td>
- <td style="text-align: center; width:80px;">
- <s:if test="endTime != null"><span style="font-size: 12px;">已完结</span></s:if>
- <s:else>
- <a href="javascript:void(0);" onclick="javascript:completeInvl('${id}', '${type}', '<s:date name="beginTime" format="yyyy-MM-dd HH:mm:ss"/>','${powerStationId}','${var.powerStationName}');">受累完成</a>
- </s:else>
- </td>
- <td style="text-align: center; width:120px;">${var.powerStationName}</td>
- <td style="text-align: center; width:120px;">${var.showProjectName}</td>
- <td style="text-align: center; width:120px;">${var.showLineName}</td>
- <td style="text-align: center; width:80px;">
- <a href="javascript:void(0);" onclick="javascript:showInvlEq('${var.id}','${powerStationId}','${var.powerStationName}');">受累风机</a>
- </td>
- <td style="text-align: center; width:120px;">${var.type}</td>
- <td style="text-align: center; width:120px;">
- <label title="受累编号:${id}">${var.reasonType}</label>
- </td>
- <td style="text-align: center; width:120px;">${var.stopType}</td>
- <td style="text-align: center; width:120px;">${var.stopReason}
- <%-- <a href="javascript:void(0);" onclick="javascript:showStopReason('${var.id}', '${var.stopReason}');">${var.stopReason}</a> --%>
- </td>
- <td style="text-align: center; width:120px;"><s:date name="startBeginTime" format="yyyy-MM-dd HH:mm:ss"/></td>
- <td style="text-align: center; width:120px;"><s:date name="beginTime" format="yyyy-MM-dd HH:mm:ss"/></td>
- <td style="text-align: center; width:120px;"><s:date name="endTime" format="yyyy-MM-dd HH:mm:ss"/></td>
- <td style="text-align: center; width:120px;">${var.duration}</td>
- <td style="text-align: center; width:120px;">${var.avgSpeed}</td>
- <td style="text-align: center; width:120px;">${var.lossGen}</td>
- </tr>
- </s:iterator>
- </tbody>
- </table>
- </div>
- </s:form>
- <s:form method="post" id="f2" action="">
- <div id="addInvlForm" class="blockCss" style="display:none" >
- <legend class="item_Name">新增受累</legend>
- <table border="1" cellspacing="0" cellpadding="0">
- <tr>
- <th>
- 风电场:
- </th>
- <td colspan="3">
- <input id="editDate" type="hidden" name="editDate" value='<s:date name="editDate" format="yyyy-MM-dd HH:mm:ss"/>'/>
- <input id="editDateLast" type="hidden" name="editDateLast" value='<s:date name="editDateLast" format="yyyy-MM-dd HH:mm:ss"/>'/>
- <input type="text" id="powerStationName" name="repInvl.powerStationName" readonly="readonly" style="border: 0px;" />
- <input type="hidden" id="editInvlId" name="repInvl.id" />
- <input type="hidden" id="powerStationId" name="repInvl.powerStationId" />
- </td>
- </tr>
- <tr>
- <th>
- 期 次:
- </th>
- <td colspan="3">
- <s:iterator value="projects" var="proj">
- <div class="field">
- <label for="proj_${proj.id}">
- <input type="checkbox" class="required" id="proj_${proj.id}" name="repInvl.projectIds"
- data_pid="${proj.id}" value="${proj.id}|${proj.name}" />${proj.name}
- </label>
- </div>
- </s:iterator>
- </td>
- </tr>
- <tr>
- <th>
- 线 路:
- </th>
- <td colspan="3">
- <s:iterator value="lines" var="l">
- <div class="field">
- <label for="line_${l.id}">
- <input type="checkbox" class="required" id="line_${l.id}" name="repInvl.lineIds"
- data_pid="${l.projectid}" data_lid="${l.id}" value="${l.id}|${l.name}" />${l.name}
- </label>
- </div>
- </s:iterator>
- </td>
- </tr>
- <tr>
- <th>
- 风 机:
- </th>
- <td colspan="3">
- <s:iterator value="equipments" var="e">
- <div class="field">
- <label for="e_${e.id}" title="${e.id}">
- <input type="checkbox" class="required" id="e_${e.id}" name="repInvl.eqIds"
- data_pid="${e.projectid}" data_lid="${e.lineid}" data_eid="${e.id}" value="${e.id}" />${e.code}
- </label>
- </div>
- </s:iterator>
- </td>
- </tr>
- <tr>
- <th>
- 开始时间:
- </th>
- <td>
- <input type="text" class="Wdate" id="beginInvl" name="repInvl.beginTime" value=""
- onFocus="WdatePicker({startDate:'%y-%M-%d 00:00:00',alwaysUseStartDate:true,dateFmt:'yyyy-MM-dd HH:mm:ss',readOnly:true,minDate:'#F{$dp.$D(\'editDate\')}',maxDate:'#F{$dp.$D(\'editDateLast\'||\'endInvl\')}'})"
- title="选择时间" />
- </td>
- <th>
- 结束时间:
- </th>
- <td>
- <input type="text" class="Wdate" id="endInvl" name="repInvl.endTime" value=""
- onFocus="WdatePicker({startDate:'%y-%M-%d 00:00:00',alwaysUseStartDate:true,dateFmt:'yyyy-MM-dd HH:mm:ss',readOnly:true,minDate:'#F{$dp.$D(\'editDate\'||\'beginInvl\')}',maxDate:'#F{$dp.$D(\'editDateLast\')}'})"
- title="选择时间"/>
- </td>
- </tr>
- <tr>
- <th>
- 类 型:
- </th>
- <td>
- <div class="field">
- <label for="typeIn"><input type="radio" id="typeIn" name="repInvl.type" value="场内" data_type="invl_in" />场内</label>
- </div>
- <div class="field">
- <label for="typeOut"><input type="radio" id="typeOut" name="repInvl.type" value="场外" data_type="invl_out" />场外</label>
- </div>
- </td>
- <th id="addSpeed">
- 平均风速(m/s):
- </th>
- <td id="addText">
- <input type="text" id="lossAvgSpeed" name="repInvl.avgSpeed" value="${stationSpeed}" title="平均风速" style="height: 20px;" />
- </td>
- </tr>
- <tr id="lossGenStation_tr" style="display: none;">
- <th>
- 损失电量(kWh):
- </th>
- <td colspan="3">
- <input type="text" id="lossGenStation" name="repInvl.lossGenStation" value="" title="损失电量" style="height: 20px;" />
- </td>
- </tr>
- <tr>
- <th>
- 受累原因:
- </th>
- <td colspan="3">
- <div id="reasonType"></div>
- <div class="clear" ></div>
- <!-- <div id="reasonType_xb" style="display: none;"> -->
- <!-- 场内受累箱变 -->
- <%-- <s:iterator value="powerStation.equipments" var="e"> --%>
- <!-- <div class="field"> -->
- <%-- <label for="xb_${e.id}" title="${e.id}"> --%>
- <%-- <input type="radio" class="required" id="xb_${e.id}" name="repInvl.reasonType" value="xb${e.id}" />${e.code} 箱变 --%>
- <!-- </label> -->
- <!-- </div> -->
- <%-- </s:iterator> --%>
- <!-- </div> -->
- </td>
- </tr>
- <tr>
- <th>
- 停机类型:
- </th>
- <td colspan="3">
- <div class="field">
- <label for="stopTypeJH"><input type="radio" id="stopTypeJH" name="repInvl.stopType" value="计划" />计划</label>
- </div>
- <div class="field">
- <label for="stopTypeFJH"><input type="radio" id="stopTypeFJH" name="repInvl.stopType" value="非计划" />非计划</label>
- </div>
- </td>
- </tr>
- <tr>
- <th>
- 停机原因:
- </th>
- <td colspan="3">
- <textarea rows="3" cols="30" style="width:99%;" id="stopReason" name="repInvl.stopReason"></textarea>
- </td>
- </tr>
- <tr>
- <td colspan="4" style="text-align: center; height: 50px;">
- <div id="err_container" style="color: red; display: none;"></div>
- </td>
- </tr>
- <tr>
- <td colspan="4" style="text-align: center;">
- <button type="button" id="saveBtn" class="x-btn-text" onclick="btnSave();">确 认</button>
- <button type="button" id="editBtn" class="x-btn-text" onclick="btnEdit();">确 认</button>
- <button type="button" class="x-btn-text" onclick="btnCancel();">取 消</button>
- </td>
- </tr>
- </table>
- </div>
- </s:form>
- <s:form method="post" id="invlEqForm" action="">
- <div id="showInvlPanel" class="blockCss" style="display:none">
- <legend class="item_Name">受累风机</legend>
- <table class="dataform" border="1" cellspacing="0" cellpadding="0" >
- <thead>
- <tr>
- <th>
- 风电场:
- </th>
- <td colspan="3">
- <input type="text" id="showPSName" name="showPSName" readonly="readonly" style="border: 0px;" />
- </td>
- </tr>
- </thead>
- <tbody>
- <tr>
- <th>开始时间:</th>
- <td id="showBegin"></td>
- <th>结束时间:</th>
- <td id="showEnd"></td>
- </tr>
- <tr>
- <th width="20%">受累风机(台):</th>
- <td width="30%" id="showEqCount"></td>
- <th width="20%">损失电量(kWh):</th>
- <td width="30%" id="showLossGen"></td>
- </tr>
- <tr>
- <th>受累风机列表:</th>
- <td colspan="3" id="showEqList"></td>
- </tr>
- </tbody>
- <tfoot>
- <tr>
- <td colspan="4" style="text-align: center;">
- <button type="button" class="x-btn-text" onclick="javascript:$('#showInvlPanel').unblockUI();">关 闭</button>
- </td>
- </tr>
- </tfoot>
- </table>
- </div>
- </s:form>
- <s:form method="post" id="invlCompleteForm" action="">
- <div id="completePanel" class="blockCss" style="display:none" >
- <legend class="item_Name">受累完成</legend>
- <table class="dataform" border="1" cellspacing="0" cellpadding="0">
- <thead>
- <tr>
- <th width="20%">
- 风电场:
- </th>
- <td width="30%">
- <input type="text" id="cpPSName" name="repInvlDto.cpPSName" readonly="readonly" style="border: 0px;" />
- <input type="hidden" id="cpPSId" name="repInvlDto.cpPSId" readonly="readonly" style="border: 0px;" value="${repInvl.powerStationId }"/>
- <input type="hidden" id="cpInvlId" name="repInvlDto.cpInvlId" readonly="readonly" style="border: 0px;" value="${id}"/>
- </td>
- <th width="20%">
- 受累类型:
- </th>
- <td width="30%">
- <input type="text" id="cpReasonType" name="repInvlDto.cpReasonType" readonly="readonly" style="border: 0px;" />
- </td>
- </tr>
- </thead>
- <tbody>
- <tr>
- <th>开始时间:</th>
- <td>
- <input type="text" id="cpBegin" name="repInvlDto.begin" value="" readonly="readonly" style="border: 0px;" />
- </td>
- <th>结束时间:</th>
- <td>
- <input type="text" class="Wdate" id="cpEnd" name="repInvlDto.end" value=""
- onFocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowWeek:true,readOnly:true,minDate:'#F{$dp.$D(\'cpBegin\')}',maxDate:'%y-%M-%d'})"
- title="选择时间" />
- </td>
- </tr>
- <tr>
- <td colspan="4" style="text-align: center; height: 50px;">
- <div id="cp_err_container" style="color: red; display: none;"></div>
- </td>
- </tr>
- </tbody>
- <tfoot>
- <tr>
- <td colspan="4" style="text-align: center;">
- <button type="button" class="x-btn-text" onclick="completeSave();">保 存</button>
- <button type="button" class="x-btn-text" onclick="javascript:clearForm('invlCompleteForm'); $('#completePanel').unblockUI();">关 闭</button>
- </td>
- </tr>
- </tfoot>
- </table>
- </div>
- <!-- </gyee:panel> -->
- </s:form>
- <s:form method="post" id="stopReasonDIv" action="">
- <div id="stopReasonPanel" class="blockCss" style="display:none" >
- <legend class="item_Name">停机原因</legend>
- <table class="dataform" border="1" cellspacing="0" cellpadding="0" >
- <tbody>
- <tr>
- <td>
- <input type="hidden" id="u_id" name="repInvl.id">
- <textarea rows="5" cols="" style="width:100%;" id="u_stopReason" name="repInvl.stopReason"></textarea>
- </td>
- </tr>
- </tbody>
- <tfoot>
- <tr>
- <td colspan="4" style="text-align: center;">
- <button type="button" class="x-btn-text" onclick="updateStopReason();">保 存</button>
- <button type="button" class="x-btn-text" onclick="javascript:$('#stopReasonPanel').unblockUI();">关 闭</button>
- </td>
- </tr>
- </tfoot>
- </table>
- </div>
- </s:form>
- <div id='showMsg' class="warp wait_box" style="display:none"><div class="wait_img"><img src="../../resource/images/panel/wait.gif" /></div>
- <div id="showMsgContent" class="wait_word">数据正在处理,请稍后......</div>
- </div>
- <style type="text/css">
- div.blockCss {
- padding: 20px;
- }
- .blockCss table{
- background-color: white;
- border-collapse: collapse;
- border-color:graytext;
- width: 100%;
- }
- .blockCss legend{
- background-color: white;
- padding-bottom: 10px;
- }
- 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;
- }
- fieldset legend {
- color:#302A2A;
- font: bold 16px/2 Verdana, Geneva, sans-serif;
- font-weight: bold;
- text-align: left;
- text-shadow: 2px 2px 2px rgb(88, 126, 156);
- }
- fieldset legend {
- color:#302A2A;
- font: bold 16px/2 Verdana, Geneva, sans-serif;
- font-weight: bold;
- text-align: left;
- text-shadow: 2px 2px 2px rgb(88, 126, 156);
- }
- </style>
- </body>
|