Merge branch 'develop' of http://192.168.10.125/k18_web/NFS.git into
develop Conflicts: src/main/webapp/WEB-INF/include/excel/importModal.jsp src/main/webapp/WEB-INF/views/cfg/ipaddr/ipList.jsp 增加region和service导入属性,动态控制导入业务 优化导入界面
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
<%@ include file="/WEB-INF/include/taglib.jsp"%>
|
||||
<script src="${pageContext.request.contextPath}/static/pages/scripts/importExcel.js" type="text/javascript"></script>
|
||||
<div class="modal fade" id="import_modal" tabindex="-1" role="dialog" aria-labelledby="mo" aria-hidden="true">
|
||||
<<<<<<< HEAD
|
||||
<form id="importForm1" action="${ctx}/ntc/iplist/import?importPath=${importPath}" method="post" enctype="multipart/form-data" class="form-horizontal"
|
||||
onsubmit="loading('<spring:message code='loading'/>');">
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
<c:if test="${_cfg.district==_district}">selected</c:if>>${_district }</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
<input type="hidden" name="districtShowName" placeholder="<spring:message code='please_input'/> <spring:message code='custom_region'/>" class="otherValue form-control" value="${_cfg.district}"/>
|
||||
<input type="hidden" name="districtShowName" maxlength="64" placeholder="<spring:message code='please_input'/> <spring:message code='custom_region'/>" class="otherValue form-control" value="${_cfg.district}"/>
|
||||
</div>
|
||||
<div for="district"></div>
|
||||
</div>
|
||||
|
||||
@@ -92,8 +92,6 @@
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/jquery-validation/1.11.0/localization/messages_en.js"></script>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<script src="${pageContext.request.contextPath}/static/pages/scripts/importExcel.js" type="text/javascript"></script>
|
||||
|
||||
<script src="${pageContext.request.contextPath}/static/global/scripts/common.js" type="text/javascript"></script>
|
||||
<script src="${pageContext.request.contextPath}/static/global/scripts/jquery.tagsinput.js" type="text/javascript"></script>
|
||||
<script src="${pageContext.request.contextPath}/static/global/scripts/app.js" type="text/javascript"></script>
|
||||
|
||||
@@ -165,7 +165,7 @@ $(function(){
|
||||
<c:if test="${_cfg.district==_district}">selected</c:if>>${_district }</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
<input type="hidden" name="districtShowName" placeholder="<spring:message code='please_input'/> <spring:message code='custom_region'/>" class="otherValue form-control" value="${_cfg.district}"/>
|
||||
<input type="hidden" name="districtShowName" maxlength="64" placeholder="<spring:message code='please_input'/> <spring:message code='custom_region'/>" class="otherValue form-control" value="${_cfg.district}"/>
|
||||
</div>
|
||||
<div for="district"></div>
|
||||
</div>
|
||||
|
||||
@@ -165,7 +165,7 @@ $(function(){
|
||||
<c:if test="${_cfg.district==_district}">selected</c:if>>${_district }</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
<input type="hidden" name="districtShowName" placeholder="<spring:message code='please_input'/> <spring:message code='custom_region'/>" class="otherValue form-control" value="${_cfg.district}"/>
|
||||
<input type="hidden" name="districtShowName" maxlength="64" placeholder="<spring:message code='please_input'/> <spring:message code='custom_region'/>" class="otherValue form-control" value="${_cfg.district}"/>
|
||||
</div>
|
||||
<div for="district"></div>
|
||||
</div>
|
||||
|
||||
@@ -164,7 +164,7 @@ $(function(){
|
||||
<c:if test="${_cfg.district eq dict.itemValue}">selected</c:if>>${dict.itemValue }</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
<input type="hidden" name="districtShowName" placeholder="<spring:message code='please_input'/> <spring:message code='custom_region'/>" class="otherValue form-control" value="${_cfg.district}"/>
|
||||
<input type="hidden" name="districtShowName" maxlength="64" placeholder="<spring:message code='please_input'/> <spring:message code='custom_region'/>" class="otherValue form-control" value="${_cfg.district}"/>
|
||||
</div>
|
||||
<div for="district"></div>
|
||||
</div>
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
<c:if test="${cfg.district==_district}">selected</c:if>>${_district }</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
<input type="hidden" name="${cfgName}.districtShowName" placeholder="<spring:message code='please_input'/> <spring:message code='custom_region'/>" class="otherValue form-control invisibleChar" value="${cfg.district}"/>
|
||||
<input type="hidden" name="${cfgName}.districtShowName" maxlength="64" placeholder="<spring:message code='please_input'/> <spring:message code='custom_region'/>" class="otherValue form-control invisibleChar" value="${cfg.district}"/>
|
||||
</div>
|
||||
<div for="${cfgName}.districtShowName"></div>
|
||||
<div for="${cfgName}.district"></div>
|
||||
|
||||
@@ -99,6 +99,11 @@
|
||||
onClick="javascript:window.location='${ctx}/proxy/intercept/intercept${interceptType}Form?functionId=${cfg.functionId}'">
|
||||
<i class="fa fa-plus"></i>
|
||||
<spring:message code="add"></spring:message></button>
|
||||
<c:if test="${cfg.functionId eq 212}">
|
||||
<button type="button" class="btn btn-primary import" >
|
||||
<i class="fa fa-plus"></i>
|
||||
<spring:message code="import"></spring:message></button>
|
||||
</c:if>
|
||||
</customTag:hasAnyPermissions>
|
||||
</div>
|
||||
|
||||
@@ -531,6 +536,9 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<c:set var="importPath" value="/proxy/intercept/${fn:toLowerCase(interceptType)}/list"/>
|
||||
<c:set var="functionId" value="${cfg.functionId}"/>
|
||||
<!-- 模板导入,start -->
|
||||
<%@include file="/WEB-INF/include/excel/importModal.jsp" %>
|
||||
</body>
|
||||
</html>
|
||||
@@ -471,8 +471,9 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<c:set var="importPath" value="${ctx}/ntc/iplist/list?functionId=${cfg.functionId}"/>
|
||||
<<<<<<< HEAD
|
||||
<c:set var="importPath" value="/ntc/iplist/list?functionId=${cfg.functionId}"/>
|
||||
<!-- 模板导入,start -->
|
||||
<%@include file="/WEB-INF/include/excel/importModal.jsp" %>
|
||||
<%@include file="/WEB-INF/include/excel/importModal.jsp" %>
|
||||
</body>
|
||||
</html>
|
||||
@@ -2,6 +2,7 @@ $(function(){
|
||||
//增加描述新增时的文字长度限制
|
||||
$("form input[name='cfgDesc']").attr("maxlength","128");
|
||||
$("form input[name$='cfgKeywords']").attr("maxlength","1024");
|
||||
$("form input[class~='domainCheck']").attr("maxlength","1024");
|
||||
//截取过长的文字 使用id选择器;例如:tab对象->tr->td对象. 排除日志table .logTb
|
||||
$("#contentTable").not(".logTb").find("td").each(function(i){
|
||||
//获取td当前对象的文本,如果长度大于25;
|
||||
|
||||
@@ -7,12 +7,30 @@ $(function(){
|
||||
show:true
|
||||
});
|
||||
});
|
||||
$("#appIdId").on("change",function(){
|
||||
ajaxBehaviour($(this).val());
|
||||
});
|
||||
switchService();
|
||||
$("input[name='serviceDictId']").click(function(){
|
||||
switchService();
|
||||
});
|
||||
$("input[name='regionDictIds']").click(function(){
|
||||
});
|
||||
});
|
||||
|
||||
/**
|
||||
* action动作切换
|
||||
*/
|
||||
function switchService(){
|
||||
var functionId=$("#functionId").val();
|
||||
if(functionId==5){//IP配置特殊处理
|
||||
var cfgRegionCodeS=$("input[name='serviceDictId']:checked").attr("cfgRegionCodeS");
|
||||
var cfgRegionCode=cfgRegionCodeS.split(",")[0];
|
||||
$("input[name='regionDictIds'][cfgregioncoder!='"+cfgRegionCode+"']").prop("checked",false);
|
||||
$("input[name='regionDictIds'][cfgRegionCodeR!='"+cfgRegionCode+"']").parents(".radio-inline").addClass("hidden");
|
||||
$("input[name='regionDictIds'][cfgRegionCodeR='"+cfgRegionCode+"']").prop("checked",true);
|
||||
$("input[name='regionDictIds'][cfgRegionCodeR='"+cfgRegionCode+"']").parents(".radio-inline").removeClass("hidden");
|
||||
}
|
||||
}
|
||||
/**
|
||||
* 模板下载
|
||||
* TODO 后期修改为传入regionDictId
|
||||
@@ -27,3 +45,46 @@ function downLoadTemplate(path){
|
||||
document.location.href = path+'/ntc/iplist/import/template?' + params;
|
||||
|
||||
}
|
||||
|
||||
|
||||
var ajaxBehaviour=function(val){
|
||||
var pathName=window.document.location.pathname.substring(0,window.document.location.pathname.indexOf("/nis")+4);
|
||||
var request=$.ajax({
|
||||
type:'post',
|
||||
url:pathName+'/specific/specificServiceCfg/childrenList',
|
||||
data:{"parent":val},
|
||||
dataType:'json',
|
||||
async:true,
|
||||
success:function(data,textStatus){//处理返回结果
|
||||
if(textStatus=="success"){
|
||||
var html='<select name="behaviorId" data-live-search="true" class="selectpicker form-control">'
|
||||
+'<option value=""><spring:message code="select"/></option>';
|
||||
if(data.length>0){
|
||||
for(i=0;i<data.length;i++){
|
||||
html+='<option value="'+data[i].code+'"';
|
||||
html+='>'+data[i].name+'</option>';
|
||||
}
|
||||
html+='</select>';
|
||||
$("#behaviorId").html(html);
|
||||
$("[name='behaviorId']").selectpicker("refresh");
|
||||
$("[name='behaviorId']").selectpicker("render");
|
||||
}else{
|
||||
html+='</select>';
|
||||
$("#behaviorId").html(html);
|
||||
$("[name='behaviorId']").selectpicker("refresh");
|
||||
$("[name='behaviorId']").selectpicker("render");
|
||||
}
|
||||
|
||||
}
|
||||
},
|
||||
complete:function(XMLHttpRequest,status){//超时设置
|
||||
if(status=="timeout"){
|
||||
var html='<select name="behaviorId" data-live-search="true" class="selectpicker form-control">'
|
||||
+'<option value=""><spring:message code="select"/></option></select>';
|
||||
$("#behaviorId").html(html);
|
||||
$("[name='behaviorId']").selectpicker("refresh");
|
||||
$("[name='behaviorId']").selectpicker("render");
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user