123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195 |
- <%@ 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>
- <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>
- <script src="<%=request.getContextPath()%>/resource/js/datePicker/WdatePicker.js" type="text/javascript"></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 language="javascript">
- $(function(){
- showJqGrid();
- });
-
- function editData(){
- $("#f1").attr("action","editData.action").submit();
- }
-
- function delDetail(id){
- if(confirm("您确认删除吗?")){
- $("#f1").attr("action","delDetail.action?brownoutsevent.id="+id).submit();
- }
- }
-
-
- function returnIndex(){
- $("#f1").attr("action", "index.action").attr("validate", false).submit();
- }
-
- function returnEdit(){
- $("#f1").attr("action", "detail.action").attr("validate", false).submit();
- }
-
- function save(){
- $("#f1").attr("action", "saveData.action").submit();
- }
-
- function saveDetail(){
- $("#f1").attr("action", "saveDetail.action").submit();
- }
-
- function showJqGrid() {
-
- var id = '<s:property value="mainBrownouts.id"/>';
- var temp="detaillist.action?mainBrownouts.id="+id;
- var url= encodeURI(encodeURI(temp));
- var id = 'gridTable';
- var datatype = 'json';
- var colNames = ['风机', '限电时刻','恢复时刻','停机小时数','损失电量(KWh)'];
- var colModel = [
- { name: 'wtName', index: 'wtName', width: 250, align: 'center'},
- { name: 'stopTime', index: 'stopTime', width: 250, align: 'center'},
- { name: 'startTime', index: 'startTime', width: 250, align: 'center'},
- { name: 'stopHours', index: 'stopHours', width: 250, align: 'center'},
- { name: 'lossPower', index: 'lossPower', width: 250, align: 'center'}
- ];
- var caption = '限电事件记录';
- var sortname = 'stopTime';
- var gridPagerID ='gridPager';
- var sortorder='desc';
- var height='auto';
- var width='auto';
- var rownumbers=true;
- var multiselect=false;
- myJqGrid(id, url, datatype, colNames, colModel, caption, sortname, gridPagerID,sortorder,height,width,
- multiselect,rownumbers);
- }
- </script>
- <style type="text/css">
- .mycss {
- font-family: "宋体";
- font-size: 12px;
- color: #000;
- text-decoration: none;
-
- }
- </style>
- </head>
- <body>
- <s:form action="" method="post" id="f1">
- <lt:token/>
-
- <s:hidden name="page"></s:hidden>
- <s:hidden name="pageSize"></s:hidden>
- <s:hidden name="mainBrownouts.id"></s:hidden>
- <s:hidden name="beginDate"></s:hidden>
- <s:hidden name="endDate"></s:hidden>
- <s:hidden name="wfId"></s:hidden>
- <table width="100%">
- <tr>
- <td align="left" class="mycss">
- ${mainBrownouts.id==null?"新增限电事件":"修改限电事件" }
- </td>
- <td align="right">
-
- <s:if test="mainBrownouts.id != null">
- <input type="button" class="button" value='修改' onclick="javascript:editData()"/>
- <input type="button" class="button" value='返回' onclick="javascript:returnIndex()"/>
- </s:if>
- <s:else>
- <input type="button" class="button" value='返回' onclick="javascript:returnIndex()"/>
- </s:else>
-
- </td>
- </tr>
- </table>
- <hr />
- <s:fielderror/>
- <s:actionerror />
- <s:actionmessage />
- <!-- 修改的页面风格 开始 -->
- <table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#C1C1C1">
- <tr>
- <td width="10%" height="26" bgcolor="#efefef"><span class="mycss">限电原因:</span></td>
- <td width="40%" bgcolor="#efefef"><span class="mycss"><s:property value="mainBrownouts.description"/></span></td>
-
-
- <td width="10%" height="26" bgcolor="#efefef"><span class="mycss">限电类型:</span></td>
- <td width="40%" bgcolor="#efefef"><span class="mycss"><s:property value="mainBrownouts.stopTypeId" /></span></td>
- </tr>
- <tr>
- <td width="10%" height="26" bgcolor="#ffffff"><span class="mycss">限电指令:</span></td>
- <td width="40%" bgcolor="#ffffff"><span class="mycss"><s:property value="mainBrownouts.brownoutsDirective"/></span></td>
-
-
- <td width="10%" height="26" bgcolor="#ffffff"><span class="mycss">当时风速(m/s):</span></td>
- <td width="40%" bgcolor="#ffffff"><span class="mycss"><s:property value="mainBrownouts.windspeed" /></span></td>
- </tr>
-
- <tr>
- <td width="10%" height="26" bgcolor="#efefef"><span class="mycss">限电负荷(MW):</span></td>
- <td width="40%" bgcolor="#efefef"><span class="mycss"><s:property value="mainBrownouts.limitload"/></span></td>
-
-
- <td width="10%" height="26" bgcolor="#efefef"><span class="mycss">当时负荷(MW):</span></td>
- <td width="40%" bgcolor="#efefef"><span class="mycss"><s:property value="mainBrownouts.thisload" /></span></td>
- </tr>
- <tr>
- <td width="10%" height="26" bgcolor="#ffffff"><span class="mycss">限电时刻:</span></td>
- <td width="40%" bgcolor="#ffffff"><span class="mycss"><s:date name="mainBrownouts.stopTime" format="yyyy-MM-dd HH:mm:ss"/></span></td>
-
-
- <td width="10%" height="26" bgcolor="#ffffff"><span class="mycss">恢复时刻:</span></td>
- <td width="40%" bgcolor="#ffffff"><span class="mycss"><s:date name="mainBrownouts.startTime" format="yyyy-MM-dd HH:mm:ss"/></span></td>
- </tr>
- <tr>
- <td width="10%" height="26" bgcolor="#efefef"><span class="mycss">限电损失电量(KWh):</span></td>
- <td width="40%" bgcolor="#efefef"><span class="mycss"><s:property value="mainBrownouts.lossPower" /></span></td>
-
-
- <td width="10%" height="26" bgcolor="#efefef"></td>
- <td width="40%" bgcolor="#efefef"></td>
- </tr>
- </table>
- <!-- 修改的页面风格 结束 -->
-
-
-
- <br/>
- <!-- <table width="100%">
- <tr>
- <td align="right" >
- <input type="button" class="button" value='保存' onclick="javascript:saveDetail()"/>
- </td>
- </tr>
- </table> -->
- <table id='gridTable' height="100%">
- </table>
-
- <div id='gridPager'></div>
- </s:form>
- </body>
|