contractConfigInfo.jsp 7.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195
  1. <%@ page contentType="text/html;charset=GBK"%>
  2. <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
  3. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  4. <HEAD>
  5. <TITLE>合同预警配置</TITLE>
  6. <link href="${pageContext.request.contextPath}/main.css" rel="stylesheet" type="text/css" />
  7. <link href="/shares/js/yw/master1/liger/skins/ynet/css/ligerui-all.css" rel="stylesheet" type="text/css" />
  8. <link href="/shares/css/yw/master1/reset.css" rel="stylesheet"
  9. type="text/css" />
  10. <script src="${pageContext.request.contextPath }/liger/lib/jquery/jquery-1.3.2.min.js" type="text/javascript"></script>
  11. <script src="${pageContext.request.contextPath }/liger/lib/ligerUI/js/core/base.js" type="text/javascript"></script>
  12. <script src="${pageContext.request.contextPath }/liger/lib/ligerUI/js/plugins/ligerGrid.js" type="text/javascript"></script>
  13. <script src="${pageContext.request.contextPath}/liger/lib/ligerUI/js/ligerui.all.js"
  14. type="text/javascript"></script>
  15. <script type="text/javascript" src="/shares/js/constant.js"></script>
  16. <script type="text/javascript" src="/shares/js/common.js"></script>
  17. <link rel="stylesheet" type="text/css"
  18. href="/shares/css/yw/master1/${sessionScope.loginFrom}/jquery.jscrollpane.codrops1.css" />
  19. <!-- the mousewheel plugin -->
  20. <script type="text/javascript"
  21. src="/shares/js/yw/master1/jquery.mousewheel.js"></script>
  22. <!-- the jScrollPane script -->
  23. <script type="text/javascript"
  24. src="/shares/js/yw/master1/jquery.jscrollpane.min.js"></script>
  25. <script type="text/javascript"
  26. src="/shares/js/yw/master1/scroll-startstop.events.jquery.js"></script>
  27. <script type="text/javascript" src="/shares/js/yw/master1/scroll.js"></script>
  28. <script type="text/javascript">
  29. $(document).ready(function(){
  30. var warn_way_value=$("#warn_way_value").val();
  31. var warn_target_value=$("#warn_target_value").val();
  32. var warn_target=warn_target_value.split(",");
  33. var warn_ways=warn_way_value.split(",");
  34. $("input[name='warn_target']").each(function(){
  35. var vl=$(this).val();
  36. for(var i=0;i<warn_target.length;i++){
  37. if(vl==warn_target[i]){
  38. $(this).attr("checked",true);
  39. }
  40. }
  41. });
  42. $("input[name='warn_ways']").each(function(){
  43. var vl=$(this).val();
  44. for(var i=0;i<warn_ways.length;i++){
  45. if(vl==warn_ways[i]){
  46. $(this).attr("checked",true);
  47. }
  48. }
  49. });
  50. });
  51. function editContractConfig(){
  52. var rs= $.validate({name:"warn_days",model:[{type:"require",msg:"预警天数不能为空!"},
  53. {type:"isNumber",msg:"预警天数只能为数字!"},
  54. {type:"size",min:1,msg:"预警天数不能小于1!"}]});
  55. if(!rs)return;
  56. var warn_target_value="";
  57. $("input[name='warn_target']:checked").each(function(){
  58. if(warn_target_value==""){
  59. warn_target_value+=$(this).val();
  60. }else{
  61. warn_target_value+=","+$(this).val();
  62. }
  63. });
  64. $("#warn_target_value").val(warn_target_value);
  65. var warn_ways_value="";
  66. $("input[name='warn_ways']:checked").each(function(){
  67. if(warn_ways_value==""){
  68. warn_ways_value+=$(this).val();
  69. }else{
  70. warn_ways_value+=","+$(this).val();
  71. }
  72. });
  73. $("#warn_way_value").val(warn_ways_value);
  74. $("#addContractConfigForm").submit();
  75. }
  76. </script>
  77. <style type="text/css">
  78. /* body { */
  79. /* padding: 5px; */
  80. /* margin: 0; */
  81. /* } */
  82. body {
  83. background: #fff;
  84. overflow: hidden;
  85. }
  86. </style>
  87. </HEAD>
  88. <BODY ontouchmove="event.preventDefault();">
  89. <%@ include file="/include/button.jsp"%>
  90. <%@ include file="/include/message.jsp"%>
  91. <div class="s_title b10 f6">
  92. <img src="/shares/images/master1/gg_ico.png" width="27" height="26" />
  93. 合同预警配置
  94. <div class="article_title">
  95. <input class="art_back" title="返回" name=""
  96. onclick="history.back(-1);" type="button" style="width: 50px;"/>&nbsp;
  97. <input class="art_sub" title="保存" onclick="editContractConfig()"
  98. id="editContractConfigBtn" type="button" />&nbsp;
  99. </div>
  100. </div>
  101. <div id="jp-container" class="jp-container liuyan" style="padding-top: 30px;">
  102. <div class="l-content">
  103. <form id="addContractConfigForm" name="addContractConfigForm" method="post" action="MTContractConfigurationAction.do?task=editContractConfig">
  104. <div id="layout1">
  105. <div position="center" id="center" title="新增转移" class="forum-container">
  106. <input id="tabid" name="tabid" value="${param.tabid }" type="hidden"/>
  107. <input id="serverDate" name="serverDate" value="${serverDate }" type="hidden"/>
  108. <input type="hidden" id="warn_target_value" name="warn_target_value" value="${configInfo.warn_target }"/>
  109. <input type="hidden" id="warn_way_value" name="warn_way_value" value="${configInfo.warn_ways }"/>
  110. <table border="0" cellspacing="1" cellpadding="0" class="l-table-edit line">
  111. <tr>
  112. <td class="l-table-edit-text">预警对象:</td>
  113. <td class="l-table-edit-td">
  114. <c:forEach items="${targetList }" var="item">
  115. <input type="checkbox" id="warn_target" name="warn_target" value="${item.warn_target_value }"/>&nbsp; ${item.warn_target_name }&nbsp;&nbsp;&nbsp;
  116. </c:forEach>
  117. </td>
  118. </tr>
  119. <tr>
  120. <td class="l-table-edit-text">预警方式:</td>
  121. <td class="l-table-edit-td">
  122. <c:forEach items="${waysList }" var="item">
  123. <input type="checkbox" id="warn_ways" name="warn_ways" value="${item.warn_way_value }"/>&nbsp; ${item.warn_way_name }&nbsp;&nbsp;&nbsp;
  124. </c:forEach>
  125. </td>
  126. </tr>
  127. <tr>
  128. <td class="l-table-edit-text">预警天数:</td>
  129. <td class="l-table-edit-td" colspan="3">
  130. <input id="warn_days" name="warn_days" type='text' value="${configInfo.warn_days }" style="width:50px;"/>&nbsp;天
  131. </td>
  132. </tr>
  133. <tr>
  134. <td class="l-table-edit-text">预警时间:</td>
  135. <td class="l-table-edit-td" colspan="3">
  136. <select id="warn_time_hour" name="warn_time_hour" style="width:50px;">
  137. <option value="${configInfo.warn_time_hour }" selected="selected">${configInfo.warn_time_hour }</option>
  138. <c:forEach items="${hourList }" var="item">
  139. <c:if test="${configInfo.warn_time_hour!=item }">
  140. <option value="${item}" >${item}</option>
  141. </c:if>
  142. </c:forEach>
  143. </select>&nbsp;时
  144. <select id="warn_time_minute" name="warn_time_minute" style="width:50px;">
  145. <option value="${configInfo.warn_time_minute }" selected="selected">${configInfo.warn_time_minute }</option>
  146. <c:forEach items="${timeList }" var="item">
  147. <c:if test="${configInfo.warn_time_minute!=item }">
  148. <option value="${item}" >${item}</option>
  149. </c:if>
  150. </c:forEach>
  151. </select>&nbsp;分
  152. <%-- <select id="warn_time_second" name="warn_time_second" style="width:50px;">
  153. <option value="${configInfo.warn_time_second }" selected="selected">${configInfo.warn_time_second }</option>
  154. <c:forEach items="${timeList }" var="item">
  155. <option value="${item}" >${item}</option>
  156. </c:forEach>
  157. </select>&nbsp;秒 --%>
  158. </td>
  159. </tr>
  160. <tr>
  161. <td class="l-table-edit-text">是否预警:</td>
  162. <td class="l-table-edit-td" colspan="3">
  163. <select id="warn_isneed" name="warn_isneed" style="width:50px;">
  164. <c:choose>
  165. <c:when test="${configInfo.warn_isneed=='1' }">
  166. <option value="1" selected="selected">是</option>
  167. </c:when>
  168. <c:otherwise>
  169. <option value="0" selected="selected">否</option>
  170. </c:otherwise>
  171. </c:choose>
  172. <c:if test="${configInfo.warn_isneed=='0' }">
  173. <option value="1" >是</option>
  174. </c:if>
  175. <c:if test="${configInfo.warn_isneed=='1' }">
  176. <option value="0" >否</option>
  177. </c:if>
  178. </select>
  179. </td>
  180. </tr>
  181. </table>
  182. </div>
  183. </div>
  184. </form>
  185. </div>
  186. </div>
  187. </BODY>
  188. </HTML>