Merge branch 'develop' of http://192.168.10.125/k18_web/NFS.git into develop

This commit is contained in:
zhanghongqing
2018-10-17 10:06:26 +08:00
36 changed files with 1118 additions and 183 deletions

View File

@@ -32,29 +32,58 @@ $(function(){
<div class="col-md-6">
<c:forEach items="${serviceList}" var="service"
varStatus="satus">
<label class="radio-inline">
<c:if test="${cfg.functionId eq service.functionId}">
<c:forEach items="${fns:getDictList('MAAT_SERVICE')}" var="serviceC">
<c:if test="${service.serviceId==serviceC.itemCode}">
<span class="${serviceC.itemValue}">
<input type="radio" name="serviceDictId" <c:if test="${serviceList.size() eq 1}">checked</c:if>
<c:if test="${(37 ne service.functionId)&& (149 ne service.functionId)}">
<label class="radio-inline">
<c:if test="${cfg.functionId eq service.functionId}">
<c:forEach items="${fns:getDictList('MAAT_SERVICE')}" var="serviceC" >
<c:if test="${service.serviceId==serviceC.itemCode }">
<span class="${serviceC.itemValue}">
<input type="radio" name="serviceDictId" <c:if test="${serviceList.size() eq 1}">checked</c:if>
serviceId="${service.serviceId }"
functionId="${service.functionId }"
cfgRegionCodeS="${service.regionCode }"
protocolId="${service.protocolId }"
action="${service.action }"
value="${service.dictId }"
class="required action"
<c:if test="${status.index eq 0 }">checked='true'</c:if>
>
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict" >
<c:if test="${dict.itemCode eq service.action }">
<spring:message code="${dict.itemValue }"/>
</c:if>
</c:forEach>
</span>
</c:if>
</c:forEach>
</c:if>
</label>
</c:if>
</c:forEach>
<c:forEach items="${serviceList}" var="service"
varStatus="satus">
<c:if test="${(service.serviceId ne 37) || (service.serviceId ne 149)}">
<label class="radio-inline"> <c:if
test="${cfg.functionId eq service.functionId}">
<input type="radio" name="serviceDictId"
serviceId="${service.serviceId }"
functionId="${service.functionId }"
cfgRegionCodeS="${service.regionCode }"
protocolId="${service.protocolId }"
action="${service.action }"
value="${service.dictId }" class="required action">
value="${service.dictId }"
class="required action"
<c:if test="${satus.index eq 0}">checked</c:if>>
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict">
<c:if test="${dict.itemCode eq service.action}">
<c:if test="${dict.itemCode eq service.action }">
<spring:message code="${dict.itemValue }"/>
</c:if>
</c:forEach>
</span>
</c:if>
</c:forEach>
</c:if>
</label>
</c:forEach>
</label>
</c:if>
</c:forEach>
</div>
<div for="action"></div>
</div>

View File

@@ -198,7 +198,7 @@
<select name="userRegion1"
class="selectpicker show-tick form-control required">
<c:forEach items="${fns:getDictList('CONTROL_REPLACE_ZONE')}" var="replaceZoneC">
<option value="${replaceZoneC.itemCode}" <c:if test="${_cfg.userRegion1==replaceZoneC.itemCode || _cfg.userRegion1==null}">selected</c:if>><spring:message code="${replaceZoneC.itemValue}"/></option>
<option value="${replaceZoneC.itemCode}" <c:if test="${_cfg.userRegion1==replaceZoneC.itemCode || (_cfg.userRegion1==null && replaceZoneC.itemCode eq 'http_resp_body')}">selected</c:if>><spring:message code="${replaceZoneC.itemValue}"/></option>
</c:forEach>
</select>
</div>

View File

@@ -88,10 +88,10 @@ function hiddenlevel(){
var action=$("input[name='action']:checked").val();
if(action==16){
$(".leveL").addClass("hidden");
$("input[name='level']").val(0);
$("select[name='level']").val(0);
}else {
$(".leveL").removeClass("hidden");
$("input[name='level']").val(0);
$("select[name='level']").val(0);
}
}
</script>
@@ -215,7 +215,12 @@ function hiddenlevel(){
<div class="form-group ">
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="harm_level"/></label>
<div class="col-md-6">
<input class="form-control required number" range="[75,99]" type="text" name="level" value="${_cfg.level }">
<select name="level" data-live-search="true" class="selectpicker form-control required">
<option value="0" ><spring:message code="selected"/></option>
<c:forEach items="${fns:getDictList('CONFIDENCE_INTERVAL')}" var="configdenceC">
<option value="${configdenceC.itemCode}" <c:if test="${_cfg.level==configdenceC.itemCode || (_cfg.level==null && configdenceC.itemCode eq 100)}">selected</c:if>><spring:message code="${configdenceC.itemValue}"/></option>
</c:forEach>
</select>
</div>
<div for="level"></div>
</div>

View File

@@ -76,7 +76,7 @@
$(".bandwith").find("input[name='userRegion3']").attr("disabled",true);
}
if(rateLimitType == 1){//带宽
$(".droprate").find("input[name='userRegion2']").attr("disabled",true);
$(".droprate").find("select[name='userRegion2']").attr("disabled",true);
}
}else if(action==80){//替换
$(".monitAction").find("input[name^='userRegion'],select[name^='userRegion']").attr("disabled",true);
@@ -317,7 +317,12 @@
<div class="form-group ">
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ratelimit"/></label>
<div class="col-md-6">
<input class="form-control required number" range="[0,1]" type="text" placeholder="0.001" name="userRegion2" value="${_cfg.userRegion2 }">
<select name="userRegion2" data-live-search="true" class="selectpicker form-control required">
<option value="" ><spring:message code="selected"/></option>
<c:forEach items="${fns:getDictList('RATE_LIMIT')}" var="ratelimitC">
<option value="${ratelimitC.itemCode}" <c:if test="${_cfg.userRegion2==ratelimitC.itemCode || (_cfg.userRegion2==null && ratelimitC.itemCode eq '0.001')}">selected</c:if>><spring:message code="${ratelimitC.itemValue}"/></option>
</c:forEach>
</select>
</div>
<div for="userRegion2"></div>
</div>

View File

@@ -375,7 +375,11 @@
<c:if test="${cfg.functionId ne 212 }">
<td>
<c:if test="${indexCfg.action eq 64}">
${indexCfg.userRegion2 }
<c:forEach items="${fns:getDictList('RATE_LIMIT')}" var="ratelimitC">
<c:if test="${indexCfg.userRegion2==ratelimitC.itemCode}">
<spring:message code="${ratelimitC.itemValue}"/>
</c:if>
</c:forEach>
</c:if>
</td>
<%-- <td>

View File

@@ -337,11 +337,13 @@ var processAction=function(configType,obj){
var rateLimitType=$("input[name='userRegion1']:checked").val();
if(rateLimitType == 0){//丢包率
$(".bandwith").find("input[name='userRegion3']").attr("disabled",true);
$(".droprate").find("input[name='userRegion2']").removeAttr("disabled");
$(".droprate").find("select[name='userRegion2']").removeAttr("disabled");
$(".droprate").find("select[name='userRegion2']").selectpicker("refresh");
}
if(rateLimitType == 1){//带宽
$(".bandwith").find("input[name='userRegion3']").removeAttr("disabled");
$(".droprate").find("input[name='userRegion2']").attr("disabled",true);
$(".droprate").find("select[name='userRegion2']").attr("disabled",true);
$(".droprate").find("select[name='userRegion2']").selectpicker("refresh");
}
}else if(action==1){
//先清空,再添加
@@ -545,7 +547,12 @@ var showHideIPSECProtocol=function(obj){
<div class="form-group ">
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ratelimit"/></label>
<div class="col-md-6">
<input class="form-control required number" range="[0,1]" type="text" placeholder="0.001" name="userRegion2" value="${_cfg.userRegion2 }">
<select name="userRegion2" data-live-search="true" class="selectpicker form-control required">
<option value="" ><spring:message code="selected"/></option>
<c:forEach items="${fns:getDictList('RATE_LIMIT')}" var="ratelimitC">
<option value="${ratelimitC.itemCode}" <c:if test="${_cfg.userRegion2==ratelimitC.itemCode || (_cfg.userRegion2==null && ratelimitC.itemCode eq '0.001')}">selected</c:if>><spring:message code="${ratelimitC.itemValue}"/></option>
</c:forEach>
</select>
</div>
<div for="userRegion2"></div>
</div>

View File

@@ -85,12 +85,17 @@
<body>
<div class="page-content">
<!-- 模板导入start -->
<%@include file="/WEB-INF/include/excel/importModal.jsp" %>
<div class="theme-panel hidden-xs hidden-sm">
<shiro:hasPermission name="iplist:config">
<button type="button" class="btn btn-primary"
onClick="javascript:window.location='${ctx}/ntc/iplist/form?functionId=${cfg.functionId}'">
<i class="fa fa-plus"></i>
<spring:message code="add"></spring:message></button>
<spring:message code="add"></spring:message></button>
<button type="button" class="btn btn-primary import" >
<i class="fa fa-plus"></i>
<spring:message code="import"></spring:message></button>
</shiro:hasPermission>
</div>
@@ -166,7 +171,7 @@
<shiro:hasPermission name="iplist:config">
<sys:delRow url="${ctx}/ntc/iplist/form" id="contentTable" label="update"></sys:delRow>
<sys:delRow url="${ctx}/ntc/iplist/updateValid?isValid=-1&functionId=${cfg.functionId }" id="contentTable" label="delete"></sys:delRow>
<%-- <sys:delRow url="${ctx}/ntc/iplist/exportIpAddr?functionId=${cfg.functionId }" searchUrl="${ctx}/ntc/iplist/list?functionId=${cfg.functionId}" id="contentTable" maxRow="10000" label="export"></sys:delRow> --%>
<sys:delRow url="${ctx}/ntc/iplist/exportIpAddr?functionId=${cfg.functionId }" searchUrl="${ctx}/ntc/iplist/list?functionId=${cfg.functionId}" id="contentTable" maxRow="10000" label="export"></sys:delRow>
</shiro:hasPermission>
<shiro:hasPermission name="iplist:confirm">
<div class="btn-group">
@@ -357,7 +362,13 @@
</c:if>
</c:forEach>
</td>
<td>${indexCfg.userRegion2 }</td>
<td>
<c:forEach items="${fns:getDictList('RATE_LIMIT')}" var="ratelimitC">
<c:if test="${indexCfg.userRegion2==ratelimitC.itemCode}">
<spring:message code="${ratelimitC.itemValue}"/>
</c:if>
</c:forEach>
</td>
<td>
<c:forEach items="${fns:getDictList('DO_LOG') }" var="dict">
<c:if test="${dict.itemCode eq indexCfg.doLog }">

View File

@@ -0,0 +1,102 @@
<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/include/taglib.jsp"%>
<html>
<head>
<title><spring:message code="${cfgName}"></spring:message></title>
<script type="text/javascript">
$(function(){
$("#cfgFrom").validate({
errorPlacement: function(error,element){
if($(element).parents().hasClass("tagsinput")){
$(element).parents(".col-md-6").next("div").append(error);
}else{
$(element).parents(".form-group").find("div[for='"+element.attr("name")+"']").append(error);
}
},
submitHandler: function(form){
loading('onloading...');
form.submit();
},
errorContainer: "#messageBox",
});
});
</script>
</head>
<body>
<div class="page-content">
<h3 class="page-title">
<spring:message code="area_group_manage"></spring:message>
</h3>
<div class="row">
<div class="col-md-12">
<div class="portlet box blue">
<div class="portlet-title">
<div class="caption">
<i class="fa fa-gift"></i>
<c:if test="${empty _cfg.id}"><spring:message code="add"></spring:message></c:if>
<c:if test="${not empty _cfg.id}"><spring:message code="edit"></spring:message></c:if>
</div>
</div>
<div class="portlet-body form">
<!-- BEGIN FORM-->
<form id="cfgFrom" action="${ctx}/cfg/groupArea/saveOrUpdate" method="post" class="form-horizontal">
<input type="hidden" name="id" value="${_cfg.id}">
<div class="form-body">
<div class="row">
<div class="col-md-6">
<div class="form-group">
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="group_name"/></label>
<div class="col-md-6">
<select name="groupId" class="selectpicker show-tick form-control required" data-live-search="true" data-live-search-placeholder="search" >
<option value="" <c:if test="${empty _cfg.groupId }">selected</c:if>><spring:message code="select"/></option>
<c:forEach items="${policyGroups }" var="policyGroup">
<option value="${policyGroup.groupId}" <c:if test="${_cfg.groupId==policyGroup.groupId }">selected</c:if>><spring:message code="${policyGroup.groupName}"/></option>
</c:forEach>
</select>
</div>
<div for="groupId"></div>
</div>
</div>
<div class="col-md-6">
<div class="form-group">
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="area"/></label>
<div class="col-md-6">
<select name="areaCode" class="selectpicker show-tick form-control required" data-live-search="true" data-live-search-placeholder="search" >
<option value="" ><spring:message code="select"/></option>
<c:forEach items="${areas}" var="area">
<option value="${area.itemCode}" <c:if test="${_cfg.areaCode == area.itemCode }">selected</c:if> >${area.itemValue}</option>
</c:forEach>
</select>
</div>
<div for="areaCode"></div>
</div>
</div>
</div>
</div>
<div class="form-actions">
<div class="row">
<div class="col-md-6">
<div class="row">
<div class="col-md-offset-3 col-md-8">
<button id="save" type="submit" class="btn green"><spring:message code="submit"/></button>
<button id="cancel" type="button" class="btn default"><spring:message code="cancel"/></button>
</div>
</div>
</div>
<div class="col-md-6"> </div>
</div>
</div>
</form>
<!-- END FORM-->
</div>
</div>
</div>
</div>
</div>
</body>
</html>

View File

@@ -0,0 +1,193 @@
<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/include/taglib.jsp"%>
<html>
<head>
<title><spring:message code="${cfgName}"></spring:message></title>
<script>
$(document).ready(function() {
//搜索框提示语初始化
if("${cfg.groupId}"){
$("#intype").val("${cfg.groupId}");
}else{
$("#intype").attr("placeholder","<spring:message code='input'/> "+$("#seltype").find("option:selected").text());
}
$("#seltype").change(function(){
$("#intype").attr("placeholder","<spring:message code='input'/> "+$(this).find("option:selected").text());
});
//筛选功能初始化
filterActionInit();
//reset
$("#resetBtn").on("click",function(){
$("select.selectpicker").each(function(){
$(this).selectpicker('val',$(this).find('option:first').val());
$(this).find("option").attr("selected",false);
$(this).find("option:first").attr("selected",true);
});
$(".Wdate").attr("value",'');
$("#searchForm")[0].reset();
});
});
</script>
</head>
<body>
<div class="page-content">
<div class="theme-panel hidden-xs hidden-sm">
<%-- <shiro:hasPermission name="avContUrl:config"> --%>
<button type="button" class="btn btn-primary"
onClick="javascript:window.location='${ctx}/cfg/groupArea/groupAreaForm'">
<i class="fa fa-plus"></i>
<spring:message code="add"></spring:message>
</button>
<%--</shiro:hasPermission>--%>
</div>
<h3 class="page-title">
<spring:message code="area_group_manage"/>
</h3>
<h5 class="page-header"></h5>
<div class="col-md-12">
<div class="portlet">
<div class="portlet-body">
<div class="row" >
<form:form id="searchForm" modelAttribute="cfg" action="${ctx}/cfg/groupArea/groupAreaList" method="post" class="form-search">
<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
<sys:tableSort id="orderBy" name="orderBy" value="${page.orderBy}"
callback="page();" />
<!-- 筛选按钮展开状态-->
<input id="isFilterAction" name="isFilterAction" type="hidden" value="${cfg.isFilterAction }"/>
<!-- 搜索内容与操作按钮栏 -->
<div class="col-md-12">
<div class="pull-left">
<div class="input-group">
<div class="input-group-btn">
<form:select path="seltype" class="selectpicker select2 input-small" >
<form:option value="areaCode"><spring:message code="area"></spring:message></form:option>
</form:select>
</div>
<input id="intype" class="form-control input-medium" type="hidden" value="">
<div class="input-group-btn">
<form:select id="" path="areaCode" class="selectpicker select2 input-medium" data-live-search="true" data-live-search-placeholder="search">
<form:option value=""><spring:message code="select"/></form:option>
<c:forEach items="${areas}" var="area">
<form:option value="${area.itemCode }"><spring:message code="${area.itemValue }"/></form:option>
</c:forEach>
</form:select>
</div>
</div>
</div>
<div class="pull-left">
<button type="button" class="btn blue" onClick="return page()"> <i class="fa fa-search"></i> <spring:message code="search"/> </button>
<button type="button" class="btn btn-default" id="resetBtn"> <i class="fa fa-refresh"></i> <spring:message code="reset"/> </button>
<button type="button" class="btn btn-default" id="filter-btn"> <spring:message code="filter"/> <i class="fa fa-angle-double-down"></i></button>
</div>
<div class="pull-right">
<%-- <shiro:hasPermission name="avContUrl:config"> --%>
<sys:delRow url="${ctx}/cfg/groupArea/groupAreaForm" id="contentTable" label="update"></sys:delRow>
<sys:delRow url="${ctx}/cfg/groupArea/delete?isValid=-1" id="contentTable" label="delete"></sys:delRow>
<%-- </shiro:hasPermission> --%>
<a class="btn btn-icon-only btn-default setfields tooltips"
data-container="body" data-placement="top" data-original-title=<spring:message code="custom_columns"/> href="javascript:;">
<i class="icon-wrench"></i>
</a>
</div>
</div>
<!-- /搜索内容与操作按钮栏 -->
<!-- 筛选搜索内容栏默认隐藏-->
<div class="col-md-12 filter-action-select-panle hide" >
<div class="row">
<div class="col-md-2">
<div class="form-group">
<label><spring:message code="config_time"/></label>
<input name="search_create_time_start" type="text" readonly="readonly" maxlength="20" class="form-control Wdate"
value="<fmt:formatDate value='${cfg.search_create_time_start}' pattern='yyyy-MM-dd HH:mm:ss'/>" onClick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
</div>
</div>
<div class="col-md-2">
<div class="form-group">
<label>&nbsp;</label>
<input name="search_create_time_end" type="text" readonly="readonly" maxlength="20" class="form-control Wdate"
value="<fmt:formatDate value="${cfg.search_create_time_end}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
</div>
</div>
<div class="col-md-2">
<div class="form-group">
<label><spring:message code="edit_time"/></label>
<input name="search_edit_time_start" type="text" readonly="readonly" maxlength="20" class="form-control Wdate"
value="<fmt:formatDate value="${cfg.search_edit_time_start}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
</div>
</div>
<div class="col-md-2">
<div class="form-group">
<label>&nbsp;</label>
<input name="search_edit_time_end" type="text" readonly="readonly" maxlength="20" class="form-control Wdate"
value="<fmt:formatDate value="${cfg.search_edit_time_end}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
</div>
</div>
</div>
</div>
<!-- /筛选搜索内容栏 结束-->
</form:form>
</div>
<sys:message content="${message}" />
<div class="table-responsive">
<table id="contentTable" class="table table-striped table-bordered table-condensed text-nowrap">
<thead>
<tr>
<th><input type="checkbox" class="i-checks" id="checkAll"></th>
<th><spring:message code="group_name"/></th>
<th><spring:message code="area"/></th>
<th><spring:message code="creator"/></th>
<th class="sort-column r.create_time"><spring:message code="config_time"/></th>
<th><spring:message code="editor"/></th>
<th class="sort-column r.edit_time"><spring:message code="edit_time"/></th>
</tr>
</thead>
<tbody>
<c:forEach items="${page.list }" var="cfg" varStatus="status" step="1">
<tr>
<td><input type="checkbox" class="i-checks" id="${cfg.id}" value="0" "></td>
<td>
<%-- <a href="javascript:;" data-original-title="${cfg.groupName}"
class="tooltips" data-flag="false" data-html="true" data-placement="top">
${fns:abbr(cfg.groupName,20)}
</a> --%>
<c:forEach items="${policyGroups }" var="policyGroup">
<c:if test="${cfg.groupId==policyGroup.groupId }"><spring:message code="${policyGroup.groupName}"/></c:if>
</c:forEach>
</td>
<td>
<c:forEach items="${areas}" var="area">
<c:if test="${cfg.areaCode==area.itemCode }"><spring:message code="${area.itemValue}"/></c:if>
</c:forEach>
</td>
<td>${cfg.creatorName }</td>
<td><fmt:formatDate value="${cfg.createTime }" pattern="yyyy-MM-dd HH:mm:ss"/></td>
<td>${cfg.editorName }</td>
<td><fmt:formatDate value="${cfg.editTime }" pattern="yyyy-MM-dd HH:mm:ss"/></td>
</tr>
</c:forEach>
</tbody>
</table>
<div class="page">${page}</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>