|
@@ -0,0 +1,200 @@
|
|
|
+<%@ page contentType="text/html;charset=UTF-8" %>
|
|
|
+<%@ include file="/webpage/include/taglib.jsp"%>
|
|
|
+<html>
|
|
|
+<head>
|
|
|
+ <title>核准阶段管理</title>
|
|
|
+ <meta name="decorator" content="ani"/>
|
|
|
+ <script type="text/javascript">
|
|
|
+
|
|
|
+ $(document).ready(function() {
|
|
|
+ $('#inDate').datetimepicker({
|
|
|
+ format: "YYYY-MM-DD HH:mm:ss"
|
|
|
+ });
|
|
|
+
|
|
|
+ $(".list-tabs li").click(function(){
|
|
|
+ $(".list-tabs li").each(function(){
|
|
|
+ $(this).removeAttr("class","active");
|
|
|
+ var id='#'+$(this).find("span").html();
|
|
|
+ $(id).attr("class","hide");
|
|
|
+ })
|
|
|
+ $(this).attr("class","active");
|
|
|
+ var id='#'+$(this).find("span").html();
|
|
|
+ $(id).removeAttr("class","hide");
|
|
|
+
|
|
|
+ })
|
|
|
+ });
|
|
|
+
|
|
|
+ function save() {
|
|
|
+ var isValidate = jp.validateForm('#inputForm');//校验表单
|
|
|
+ if(!isValidate){
|
|
|
+ return false;
|
|
|
+ }else{
|
|
|
+ jp.loading();
|
|
|
+ jp.post("${ctx}/filing/basicInformation/save",$('#inputForm').serialize(),function(data){
|
|
|
+ if(data.success){
|
|
|
+ jp.getParent().refresh();
|
|
|
+ var dialogIndex = parent.layer.getFrameIndex(window.name); // 获取窗口索引
|
|
|
+ parent.layer.close(dialogIndex);
|
|
|
+ jp.success(data.msg)
|
|
|
+
|
|
|
+ }else{
|
|
|
+ jp.error(data.msg);
|
|
|
+ }
|
|
|
+ })
|
|
|
+ }
|
|
|
+
|
|
|
+ }
|
|
|
+ function addRow(list, idx, tpl, row){
|
|
|
+ $(list).append(Mustache.render(tpl, {
|
|
|
+ idx: idx, delBtn: true, row: row
|
|
|
+ }));
|
|
|
+ $(list+idx).find("select").each(function(){
|
|
|
+ $(this).val($(this).attr("data-value"));
|
|
|
+ });
|
|
|
+ $(list+idx).find("input[type='checkbox'], input[type='radio']").each(function(){
|
|
|
+ var ss = $(this).attr("data-value").split(',');
|
|
|
+ for (var i=0; i<ss.length; i++){
|
|
|
+ if($(this).val() == ss[i]){
|
|
|
+ $(this).attr("checked","checked");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ });
|
|
|
+ $(list+idx).find(".form_datetime").each(function(){
|
|
|
+ $(this).datetimepicker({
|
|
|
+ format: "YYYY-MM-DD HH:mm:ss"
|
|
|
+ });
|
|
|
+ });
|
|
|
+ }
|
|
|
+ function delRow(obj, prefix){
|
|
|
+ var id = $(prefix+"_id");
|
|
|
+ var delFlag = $(prefix+"_delFlag");
|
|
|
+ if (id.val() == ""){
|
|
|
+ $(obj).parent().parent().remove();
|
|
|
+ }else if(delFlag.val() == "0"){
|
|
|
+ delFlag.val("1");
|
|
|
+ $(obj).html("÷").attr("title", "撤销删除");
|
|
|
+ $(obj).parent().parent().addClass("error");
|
|
|
+ }else if(delFlag.val() == "1"){
|
|
|
+ delFlag.val("0");
|
|
|
+ $(obj).html("×").attr("title", "删除");
|
|
|
+ $(obj).parent().parent().removeClass("error");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ </script>
|
|
|
+</head>
|
|
|
+<body class="bg-white">
|
|
|
+<div>
|
|
|
+ <ul class="nav nav-tabs list-tabs">
|
|
|
+ <li class="active" role="presentation" id="click1"><a id="dq" href="javascript:void(0)"><span class="hide">highVoltage</span>10kV部分</a></li>
|
|
|
+ <li role="presentation" id="click2" ><a id="qd" href="javascript:void(0)"><span class="hide">lowVoltage</span>0.4kV部分</a></li>
|
|
|
+ </ul>
|
|
|
+</div>
|
|
|
+ <form:form id="inputForm" modelAttribute="voltageData" action="${ctx}/filing/basicInformation/save" method="post" class="form-horizontal">
|
|
|
+ <div class="tabs-container" id="highVoltage">
|
|
|
+ <div class="tab-content">
|
|
|
+ <div id="tab-1" class="tab-pane fade in active">
|
|
|
+ <table class="table table-striped table-bordered table-condensed">
|
|
|
+ <thead>
|
|
|
+ <tr>
|
|
|
+ <th class="hide"></th>
|
|
|
+ <th>导线型号</th>
|
|
|
+ <th>单回路路径</th>
|
|
|
+ <th>双回路路径</th>
|
|
|
+ <th>单线长</th>
|
|
|
+ </tr>
|
|
|
+ </thead>
|
|
|
+ <tbody id="highVoltageList">
|
|
|
+ </tbody>
|
|
|
+ </table>
|
|
|
+ <script type="text/template" id="basicInformationTpl">//<!--
|
|
|
+ <tr id="highVoltageList{{idx}}">
|
|
|
+ <td class="hide">
|
|
|
+ <input id="highVoltageList{{idx}}_id" name="highVoltageList[{{idx}}].id" type="hidden" value="{{row.id}}"/>
|
|
|
+ <input id="highVoltageList{{idx}}_delFlag" name="highVoltageList[{{idx}}].delFlag" type="hidden" value="0"/>
|
|
|
+ </td>
|
|
|
+
|
|
|
+ <td class="max-width-250">
|
|
|
+ <input type='text' name="highVoltageList[{{idx}}].singleLong" readonly= "true" class="form-control" value="{{row.voltageName}}"/>
|
|
|
+ </td>
|
|
|
+
|
|
|
+ <td class="max-width-250">
|
|
|
+ <input type='text' name="highVoltageList[{{idx}}].singleCircuitPath" class="form-control" value="{{row.singleCircuitPath}}"/>
|
|
|
+ </td>
|
|
|
+ <td class="max-width-250">
|
|
|
+ <input type='text' name="highVoltageList[{{idx}}].doubleCircuitPath" class="form-control" value="{{row.doubleCircuitPath}}"/>
|
|
|
+ </td>
|
|
|
+ <td class="max-width-250">
|
|
|
+ <input type='text' name="highVoltageList[{{idx}}].singleLong" readonly= "true" class="form-control" value="{{row.singleLong}}"/>
|
|
|
+ </td>
|
|
|
+ </tr>//-->
|
|
|
+ </script>
|
|
|
+ <script type="text/javascript">
|
|
|
+ var basicInformationRowIdx = 0, basicInformationTpl = $("#basicInformationTpl").html().replace(/(\/\/\<!\-\-)|(\/\/\-\->)/g,"");
|
|
|
+ $(document).ready(function() {
|
|
|
+ var data = ${fns:toJson(highVoltageList)};
|
|
|
+ for (var i=0; i<data.length; i++){
|
|
|
+ console.log(data[i])
|
|
|
+ addRow('#highVoltageList', basicInformationRowIdx, basicInformationTpl, data[i]);
|
|
|
+ basicInformationRowIdx = basicInformationRowIdx + 1;
|
|
|
+ }
|
|
|
+ });
|
|
|
+ </script>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div class="tabs-container hide" id="lowVoltage">
|
|
|
+ <div class="tab-content">
|
|
|
+ <div id="tab-2" class="tab-pane fade in active">
|
|
|
+ <table class="table table-striped table-bordered table-condensed">
|
|
|
+ <thead>
|
|
|
+ <tr>
|
|
|
+ <th class="hide"></th>
|
|
|
+ <th>导线型号</th>
|
|
|
+ <th>单回路路径</th>
|
|
|
+ <th>双回路路径</th>
|
|
|
+ <th>单线长</th>
|
|
|
+ </tr>
|
|
|
+ </thead>
|
|
|
+ <tbody id="lowVoltageList">
|
|
|
+ </tbody>
|
|
|
+ </table>
|
|
|
+ <script type="text/template" id="lowVoltageTpl">//<!--
|
|
|
+ <tr id="lowVoltageList{{idx}}">
|
|
|
+ <td class="hide">
|
|
|
+ <input id="lowVoltageList{{idx}}_id" name="lowVoltageList[{{idx}}].id" type="hidden" value="{{row.id}}"/>
|
|
|
+ <input id="lowVoltageList{{idx}}_delFlag" name="lowVoltageList[{{idx}}].delFlag" type="hidden" value="0"/>
|
|
|
+ </td>
|
|
|
+
|
|
|
+ <td class="max-width-250">
|
|
|
+ <input type='text' name="lowVoltageList[{{idx}}].singleLong" readonly= "true" class="form-control" value="{{row.voltageName}}"/>
|
|
|
+ </td>
|
|
|
+
|
|
|
+ <td class="max-width-250">
|
|
|
+ <input type='text' name="lowVoltageList[{{idx}}].singleCircuitPath" class="form-control" value="{{row.singleCircuitPath}}"/>
|
|
|
+ </td>
|
|
|
+ <td class="max-width-250">
|
|
|
+ <input type='text' name="lowVoltageList[{{idx}}].doubleCircuitPath" class="form-control" value="{{row.doubleCircuitPath}}"/>
|
|
|
+ </td>
|
|
|
+ <td class="max-width-250">
|
|
|
+ <input type='text' name="lowVoltageList[{{idx}}].singleLong" readonly= "true" class="form-control" value="{{row.singleLong}}"/>
|
|
|
+ </td>
|
|
|
+ </tr>//-->
|
|
|
+ </script>
|
|
|
+ <script type="text/javascript">
|
|
|
+ var basicInformationRowIdx = 0, lowVoltageTpl = $("#lowVoltageTpl").html().replace(/(\/\/\<!\-\-)|(\/\/\-\->)/g,"");
|
|
|
+ $(document).ready(function() {
|
|
|
+ var data = ${fns:toJson(lowVoltageList)};
|
|
|
+ for (var i=0; i<data.length; i++){
|
|
|
+ console.log(data[i])
|
|
|
+ addRow('#lowVoltageList', basicInformationRowIdx, lowVoltageTpl, data[i]);
|
|
|
+ basicInformationRowIdx = basicInformationRowIdx + 1;
|
|
|
+ }
|
|
|
+ });
|
|
|
+ </script>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </form:form>
|
|
|
+</body>
|
|
|
+</html>
|