(1)function_service_dict增加一列config_do_log,用于控制各个业务类型的doLog值的选择范围。
(2)WhiteList,PacketStream下的form表单加入doLog的控制
This commit is contained in:
@@ -17,9 +17,16 @@ public class FunctionServiceDict extends BaseCfg<FunctionServiceDict> {
|
|||||||
private String serviceDesc;
|
private String serviceDesc;
|
||||||
private String actionCode;
|
private String actionCode;
|
||||||
private String regionCode;
|
private String regionCode;
|
||||||
|
private String configDoLog;
|
||||||
|
|
||||||
private Integer isImport;
|
private Integer isImport;
|
||||||
|
|
||||||
|
public String getConfigDoLog() {
|
||||||
|
return configDoLog;
|
||||||
|
}
|
||||||
|
public void setConfigDoLog(String configDoLog) {
|
||||||
|
this.configDoLog = configDoLog;
|
||||||
|
}
|
||||||
public Integer getIsImport() {
|
public Integer getIsImport() {
|
||||||
return isImport;
|
return isImport;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -12,11 +12,12 @@
|
|||||||
<result column="service_desc" property="serviceDesc" jdbcType="VARCHAR" />
|
<result column="service_desc" property="serviceDesc" jdbcType="VARCHAR" />
|
||||||
<result column="is_valid" property="isValid" jdbcType="INTEGER" />
|
<result column="is_valid" property="isValid" jdbcType="INTEGER" />
|
||||||
<result column="region_code" property="regionCode" jdbcType="VARCHAR" />
|
<result column="region_code" property="regionCode" jdbcType="VARCHAR" />
|
||||||
|
<result column="config_do_log" property="configDoLog" jdbcType="VARCHAR" />
|
||||||
<result column="is_import" property="isImport" jdbcType="INTEGER" />
|
<result column="is_import" property="isImport" jdbcType="INTEGER" />
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="Base_Column_List" >
|
<sql id="Base_Column_List" >
|
||||||
dict_id, function_id, protocol_id, action,action_code, service_id, service_name,service_desc,is_valid,region_code,is_import
|
dict_id, function_id, protocol_id, action,action_code, service_id, service_name,service_desc,is_valid,region_code,is_import,config_do_log
|
||||||
</sql>
|
</sql>
|
||||||
<select id="getList" resultMap="BaseResultMap" >
|
<select id="getList" resultMap="BaseResultMap" >
|
||||||
select
|
select
|
||||||
|
|||||||
@@ -0,0 +1,141 @@
|
|||||||
|
ALTER TABLE function_service_dict ADD COLUMN `config_do_log` VARCHAR(10) DEFAULT NULL;
|
||||||
|
#IP White List
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=1 AND function_id=3;
|
||||||
|
#IP Address Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=128 AND function_id=5;
|
||||||
|
#IP Address Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=16 AND function_id=5;
|
||||||
|
#IP Address Drop
|
||||||
|
UPDATE function_service_dict SET config_do_log='0;2' WHERE service_id=3 AND function_id=5;
|
||||||
|
#IP Address Ratelimit
|
||||||
|
UPDATE function_service_dict SET config_do_log='0;2' WHERE service_id=514 AND function_id=5;
|
||||||
|
#IP Payload Replace
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=517 AND function_id=212;
|
||||||
|
#IP Spoofing Spoofing
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=518 AND function_id=214;
|
||||||
|
#Protocol Identify Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=147 AND function_id=407;
|
||||||
|
#Protocol Identify Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=35 AND function_id=407;
|
||||||
|
#Protocol Identify Rate Limit
|
||||||
|
UPDATE function_service_dict SET config_do_log='0;2' WHERE service_id=1059 AND function_id=407;
|
||||||
|
#App Identify Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=145 and function_id=63;
|
||||||
|
#App Identify Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=33 AND function_id=63;
|
||||||
|
#App Identify Rate Limit
|
||||||
|
UPDATE function_service_dict SET config_do_log='0;2' WHERE service_id=1056 AND function_id=63;
|
||||||
|
#Behavior Identify Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=148 AND function_id=408;
|
||||||
|
#Behavior Identify Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=36 AND function_id=408;
|
||||||
|
#Behavior Identify Rate Limit
|
||||||
|
UPDATE function_service_dict SET config_do_log='0;2' WHERE service_id=1060 AND function_id=408;
|
||||||
|
#BGP Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=143 and function_id=61;
|
||||||
|
#BGP Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=31 AND function_id=61;
|
||||||
|
#DNS Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=130 and function_id=7;
|
||||||
|
#DNS Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=18 AND function_id=7;
|
||||||
|
#SSL Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=131 and function_id=34;
|
||||||
|
#SSL Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=19 AND function_id=34;
|
||||||
|
#HTTP url Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1,2' WHERE service_id=129 AND function_id=6;
|
||||||
|
#HTTP url Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=17 and function_id=6;
|
||||||
|
#HTTP url WhiteList
|
||||||
|
UPDATE function_service_dict SET config_do_log='0;0' WHERE service_id=2 AND function_id=6;
|
||||||
|
#HTTP Website Keyword Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1,2' WHERE service_id=152 AND function_id=635;
|
||||||
|
#HTTP Website Keyword Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=40 AND function_id=635;
|
||||||
|
#HTTP Advanced Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1,2' WHERE service_id=129 AND function_id=8;
|
||||||
|
#HTTP Advanced Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=17 AND function_id=8;
|
||||||
|
#Mail Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1,2' WHERE service_id=132 AND function_id=37;
|
||||||
|
#Mail Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=20 AND function_id=37;
|
||||||
|
#Mail WhiteList
|
||||||
|
UPDATE function_service_dict SET config_do_log='0;0' WHERE service_id=66 AND function_id=37;
|
||||||
|
#FTP Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1,2' WHERE service_id=133 AND function_id=51;
|
||||||
|
#FTP Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=21 AND function_id=51;
|
||||||
|
#P2P Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=146 AND function_id=510;
|
||||||
|
#P2P Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=34 AND function_id=510;
|
||||||
|
#Streaming Media Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=151 AND function_id=22;
|
||||||
|
#Streaming Media Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=39 AND function_id=22;
|
||||||
|
#VoIP Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=150 AND function_id=24;
|
||||||
|
#VoIP Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,2' WHERE service_id=38 AND function_id=24;
|
||||||
|
#File Digest Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=399 AND function_id=52;
|
||||||
|
#File Digest Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=273 AND function_id=52;
|
||||||
|
#Audio Sample Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=389 AND function_id=28;
|
||||||
|
#Audio Sample Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=261 AND function_id=28;
|
||||||
|
#Video Sample Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=390 AND function_id=29;
|
||||||
|
#Video Sample Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=262 AND function_id=29;
|
||||||
|
#Picture Sample Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=391 AND function_id=30;
|
||||||
|
#Picture Sample Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=263 AND function_id=30;
|
||||||
|
#VoIP Voice Sample Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=392 AND function_id=31;
|
||||||
|
#VoIP Voice Sample Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=264 AND function_id=31;
|
||||||
|
#Speaker Recognization Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=396 AND function_id=630;
|
||||||
|
#Speaker Recognization Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=268 AND function_id=630;
|
||||||
|
#Logo Detection Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=269 AND function_id=631;
|
||||||
|
#Logo Detection Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=397 AND function_id=631;
|
||||||
|
#Face Recognization Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=270 AND function_id=632;
|
||||||
|
#Face Recognization Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=398 AND function_id=632;
|
||||||
|
#Porn Detection Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=394 AND function_id=33;
|
||||||
|
#Porn Detection Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1' WHERE service_id=266 AND function_id=33;
|
||||||
|
#Anti DDOS Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=6 AND function_id=301;
|
||||||
|
#Anti DDOS Loop
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;2' WHERE service_id=5 AND function_id=301;
|
||||||
|
#Intercept Policy Bypass
|
||||||
|
UPDATE function_service_dict SET config_do_log='0;0' WHERE service_id=521 AND function_id=200;
|
||||||
|
#Intercept Policy Intercept
|
||||||
|
UPDATE function_service_dict SET config_do_log='0;2' WHERE service_id=512 AND function_id=200;
|
||||||
|
#Intercept Policy Rate Limit
|
||||||
|
UPDATE function_service_dict SET config_do_log='0;0' WHERE service_id=514 AND function_id=200;
|
||||||
|
#Control Policy Monitor
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;1,2' WHERE service_id=592 AND function_id=210;
|
||||||
|
#Control Policy Block
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,1,2' WHERE service_id=576 AND function_id=207;
|
||||||
|
#Control Policy Redirect
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,1,2' WHERE service_id=528 AND function_id=208;
|
||||||
|
#Control Policy Replace
|
||||||
|
UPDATE function_service_dict SET config_do_log='1;0,1,2' WHERE service_id=560 AND function_id=209;
|
||||||
|
#Control Policy White List
|
||||||
|
UPDATE function_service_dict SET config_do_log='0;2' WHERE service_id=750 AND function_id=211;
|
||||||
|
#Cache Policy Bypass
|
||||||
|
UPDATE function_service_dict SET config_do_log='0;2' WHERE service_id=624 AND function_id=213;
|
||||||
|
#Cache Policy Cache
|
||||||
|
UPDATE function_service_dict SET config_do_log='0;2' WHERE service_id=625 AND function_id=213;
|
||||||
@@ -98,6 +98,7 @@
|
|||||||
<script src="${pageContext.request.contextPath}/static/global/scripts/app.js" type="text/javascript"></script>
|
<script src="${pageContext.request.contextPath}/static/global/scripts/app.js" type="text/javascript"></script>
|
||||||
<script src="${pageContext.request.contextPath}/static/global/scripts/ipRegion.js" type="text/javascript"></script>
|
<script src="${pageContext.request.contextPath}/static/global/scripts/ipRegion.js" type="text/javascript"></script>
|
||||||
<script src="${pageContext.request.contextPath}/static/global/scripts/pzLog.js" type="text/javascript"></script>
|
<script src="${pageContext.request.contextPath}/static/global/scripts/pzLog.js" type="text/javascript"></script>
|
||||||
|
<script src="${pageContext.request.contextPath}/static/global/scripts/doLog.js" type="text/javascript"></script>
|
||||||
<!-- 文件导入 -->
|
<!-- 文件导入 -->
|
||||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-fileupload/js/bootstrap-fileupload.js" type="text/javascript"></script>
|
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-fileupload/js/bootstrap-fileupload.js" type="text/javascript"></script>
|
||||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-fileupload/js/jquery.cookie.min.js" type="text/javascript"></script>
|
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-fileupload/js/jquery.cookie.min.js" type="text/javascript"></script>
|
||||||
|
|||||||
@@ -309,9 +309,10 @@ var delContent = function(contentClassName, addBtnClassName) {
|
|||||||
varStatus="satus">
|
varStatus="satus">
|
||||||
<label class="radio-inline"> <c:if
|
<label class="radio-inline"> <c:if
|
||||||
test="${_cfg.functionId eq service.functionId}">
|
test="${_cfg.functionId eq service.functionId}">
|
||||||
<input type="radio" name="action"
|
<input type="radio" name="action" class="action"
|
||||||
serviceId="${service.serviceId }"
|
serviceId="${service.serviceId }"
|
||||||
protocolId="${service.protocolId }"
|
protocolId="${service.protocolId }"
|
||||||
|
configDoLog="${service.configDoLog }"
|
||||||
value="${service.action }" class="required action"
|
value="${service.action }" class="required action"
|
||||||
<c:if test="${_cfg.action==service.action || (_cfg.action==null && satus.index==0)}">checked</c:if>>
|
<c:if test="${_cfg.action==service.action || (_cfg.action==null && satus.index==0)}">checked</c:if>>
|
||||||
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict">
|
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict">
|
||||||
|
|||||||
@@ -241,10 +241,11 @@ var switchRateLimitType=function(){
|
|||||||
varStatus="satus">
|
varStatus="satus">
|
||||||
<label class="radio-inline"> <c:if
|
<label class="radio-inline"> <c:if
|
||||||
test="${_cfg.functionId eq service.functionId}">
|
test="${_cfg.functionId eq service.functionId}">
|
||||||
<input type="radio" name="action"
|
<input type="radio" name="action" class="action"
|
||||||
serviceId="${service.serviceId }"
|
serviceId="${service.serviceId }"
|
||||||
protocolId="${service.protocolId }"
|
protocolId="${service.protocolId }"
|
||||||
regionCode="${service.regionCode }"
|
regionCode="${service.regionCode }"
|
||||||
|
configDoLog="${service.configDoLog }"
|
||||||
value="${service.action }" class="required action"
|
value="${service.action }" class="required action"
|
||||||
<c:if test="${_cfg.action==service.action || (_cfg.action==null && satus.index==0)}">checked</c:if>>
|
<c:if test="${_cfg.action==service.action || (_cfg.action==null && satus.index==0)}">checked</c:if>>
|
||||||
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict">
|
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict">
|
||||||
|
|||||||
@@ -240,6 +240,7 @@ var switchRateLimitType=function(){
|
|||||||
serviceId="${service.serviceId }"
|
serviceId="${service.serviceId }"
|
||||||
protocolId="${service.protocolId }"
|
protocolId="${service.protocolId }"
|
||||||
regionCode="${service.regionCode }"
|
regionCode="${service.regionCode }"
|
||||||
|
configDoLog="${service.configDoLog }"
|
||||||
value="${service.action }" class="required action"
|
value="${service.action }" class="required action"
|
||||||
<c:if test="${_cfg.action==service.action || (_cfg.action==null && satus.index==0)}">checked</c:if>>
|
<c:if test="${_cfg.action==service.action || (_cfg.action==null && satus.index==0)}">checked</c:if>>
|
||||||
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict">
|
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict">
|
||||||
|
|||||||
@@ -483,7 +483,7 @@
|
|||||||
<input type="hidden" name="functionId" value="${_cfg.functionId}">
|
<input type="hidden" name="functionId" value="${_cfg.functionId}">
|
||||||
<input type="hidden" id="serviceId" name="serviceId" value="${_cfg.serviceId}">
|
<input type="hidden" id="serviceId" name="serviceId" value="${_cfg.serviceId}">
|
||||||
<input type="hidden" id="regionSize" name="regionSize" value="${fn:length(regionList)}">
|
<input type="hidden" id="regionSize" name="regionSize" value="${fn:length(regionList)}">
|
||||||
<input type="hidden" id="doLog" name="doLog" value="2">
|
<!-- <input type="hidden" id="doLog" name="doLog" value="2"> -->
|
||||||
|
|
||||||
<div class="form-body">
|
<div class="form-body">
|
||||||
|
|
||||||
@@ -510,6 +510,7 @@
|
|||||||
<input type="radio" name="action"
|
<input type="radio" name="action"
|
||||||
serviceId="${service.serviceId }"
|
serviceId="${service.serviceId }"
|
||||||
protocolId="${service.protocolId }"
|
protocolId="${service.protocolId }"
|
||||||
|
configDoLog="${service.configDoLog }"
|
||||||
value="${service.action }" class="required action"
|
value="${service.action }" class="required action"
|
||||||
<c:if test="${_cfg.action==service.action || (_cfg.action==null && satus.index==0)}">checked</c:if>>
|
<c:if test="${_cfg.action==service.action || (_cfg.action==null && satus.index==0)}">checked</c:if>>
|
||||||
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict">
|
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict">
|
||||||
@@ -535,7 +536,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- dolog begin-->
|
<!-- dolog begin-->
|
||||||
<%-- <div class="row interceptDoLog">
|
<div class="row interceptDoLog doLog">
|
||||||
<div class="col-md-6">
|
<div class="col-md-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="control-label col-md-3"><spring:message code="do_log" /></label>
|
<label class="control-label col-md-3"><spring:message code="do_log" /></label>
|
||||||
@@ -556,7 +557,7 @@
|
|||||||
</c:forEach>
|
</c:forEach>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div> --%>
|
</div>
|
||||||
<!-- dolog end-->
|
<!-- dolog end-->
|
||||||
|
|
||||||
<%-- action 为1 监测时 可以选择证书--%>
|
<%-- action 为1 监测时 可以选择证书--%>
|
||||||
|
|||||||
@@ -498,6 +498,7 @@ var showHideIPSECProtocol=function(obj){
|
|||||||
serviceId="${service.serviceId }"
|
serviceId="${service.serviceId }"
|
||||||
protocolId="${service.protocolId }"
|
protocolId="${service.protocolId }"
|
||||||
regionCode="${service.regionCode }"
|
regionCode="${service.regionCode }"
|
||||||
|
configDoLog="${service.configDoLog }"
|
||||||
value="${service.action }" class="required action"
|
value="${service.action }" class="required action"
|
||||||
<c:if test="${_cfg.serviceId==service.serviceId || (_cfg.serviceId==null && satus.index==0)}">checked</c:if>>
|
<c:if test="${_cfg.serviceId==service.serviceId || (_cfg.serviceId==null && satus.index==0)}">checked</c:if>>
|
||||||
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict">
|
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict">
|
||||||
|
|||||||
@@ -171,7 +171,6 @@
|
|||||||
<input type="hidden" name="functionId" value="${_cfg.functionId}">
|
<input type="hidden" name="functionId" value="${_cfg.functionId}">
|
||||||
<!-- <input type="hidden" name="protocol" value="0">
|
<!-- <input type="hidden" name="protocol" value="0">
|
||||||
<input type="hidden" name="direction" value="0"> -->
|
<input type="hidden" name="direction" value="0"> -->
|
||||||
<input type="hidden" name="doLog" value="0" >
|
|
||||||
<input type="hidden" name="isAreaEffective" value="0" >
|
<input type="hidden" name="isAreaEffective" value="0" >
|
||||||
<input type="hidden" id="serviceId" name="serviceId"
|
<input type="hidden" id="serviceId" name="serviceId"
|
||||||
value="${_cfg.serviceId}">
|
value="${_cfg.serviceId}">
|
||||||
@@ -199,10 +198,11 @@
|
|||||||
varStatus="satus">
|
varStatus="satus">
|
||||||
<label class="radio-inline"> <c:if
|
<label class="radio-inline"> <c:if
|
||||||
test="${_cfg.functionId eq service.functionId}">
|
test="${_cfg.functionId eq service.functionId}">
|
||||||
<input type="radio" name="action"
|
<input type="radio" name="action" class="action"
|
||||||
serviceId="${service.serviceId }"
|
serviceId="${service.serviceId }"
|
||||||
protocolId="${service.protocolId }"
|
protocolId="${service.protocolId }"
|
||||||
regionCode="${service.regionCode }"
|
regionCode="${service.regionCode }"
|
||||||
|
configDoLog="${service.configDoLog }"
|
||||||
value="${service.action }" class="required action"
|
value="${service.action }" class="required action"
|
||||||
<c:if test="${_cfg.action==service.action || (_cfg.action==null && satus.index==0)}">checked</c:if>>
|
<c:if test="${_cfg.action==service.action || (_cfg.action==null && satus.index==0)}">checked</c:if>>
|
||||||
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict">
|
<c:forEach items="${fns:getDictList('SERVICE_ACTION') }" var="dict">
|
||||||
@@ -219,30 +219,29 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- dolog begin-->
|
<!-- dolog begin-->
|
||||||
<%--
|
|
||||||
<div class="row doLog">
|
<div class="row doLog">
|
||||||
<div class="col-md-6">
|
<div class="col-md-6">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="control-label col-md-3"><spring:message code="do_log" /></label>
|
<label class="control-label col-md-3"><spring:message code="do_log" /></label>
|
||||||
<c:forEach items="${fns:getDictList('DO_LOG') }" var="dict">
|
<c:forEach items="${fns:getDictList('DO_LOG') }" var="dict">
|
||||||
<c:choose>
|
<c:choose>
|
||||||
<c:when test="${dict.itemCode eq _cfg.doLog}">
|
<c:when test="${dict.itemCode eq _cfg.doLog}">
|
||||||
<label class="radio-inline">
|
<label class="radio-inline">
|
||||||
<input type="radio" name="doLog" checked value="${dict.itemCode}" ><spring:message code="${dict.itemValue}"/>
|
<input type="radio" name="doLog" checked value="${dict.itemCode}" ><spring:message code="${dict.itemValue}"/>
|
||||||
</label>
|
</label>
|
||||||
</c:when>
|
</c:when>
|
||||||
<c:otherwise>
|
<c:otherwise>
|
||||||
<label class="radio-inline">
|
<label class="radio-inline">
|
||||||
<input type="radio" name="doLog" value="${dict.itemCode}" ><spring:message code="${dict.itemValue}"/>
|
<input type="radio" name="doLog" value="${dict.itemCode}" ><spring:message code="${dict.itemValue}"/>
|
||||||
</label>
|
</label>
|
||||||
</c:otherwise>
|
</c:otherwise>
|
||||||
</c:choose>
|
</c:choose>
|
||||||
|
|
||||||
</c:forEach>
|
</c:forEach>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
--%>
|
|
||||||
<!-- dolog end-->
|
<!-- dolog end-->
|
||||||
<c:set var="ipCfgIndex" value="0"></c:set>
|
<c:set var="ipCfgIndex" value="0"></c:set>
|
||||||
<c:set var="strCfgIndex" value="0"></c:set>
|
<c:set var="strCfgIndex" value="0"></c:set>
|
||||||
|
|||||||
67
src/main/webapp/static/global/scripts/doLog.js
Normal file
67
src/main/webapp/static/global/scripts/doLog.js
Normal file
@@ -0,0 +1,67 @@
|
|||||||
|
/**
|
||||||
|
* 处理doLog
|
||||||
|
*/
|
||||||
|
$(function(){
|
||||||
|
var doLog=$("[name$=action]:checked").attr("configDoLog");
|
||||||
|
if(!doLog){
|
||||||
|
$("[name$=action]").attr("configDoLog");
|
||||||
|
}
|
||||||
|
if(doLog&&doLog!=""){
|
||||||
|
processDoLog(doLog);
|
||||||
|
}
|
||||||
|
$(".action").on("change",function(){
|
||||||
|
var _doLog=$(this).attr("configDoLog");
|
||||||
|
if(_doLog&&_doLog!=""){
|
||||||
|
processDoLog(_doLog);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
var processDoLog=function(doLog){
|
||||||
|
var doLogValue=$("[name$='doLog']:checked").val();
|
||||||
|
var dologObj=doLogOpt(doLog);
|
||||||
|
if(dologObj.isShown==0){
|
||||||
|
$(".doLog").addClass("hidden");
|
||||||
|
}else{
|
||||||
|
$(".doLog").removeClass("hidden");
|
||||||
|
}
|
||||||
|
var dologOptionValues=dologObj.options.split(",");
|
||||||
|
if(dologOptionValues.length==1){
|
||||||
|
$(".doLog").find("[name='doLog']").each(function(){
|
||||||
|
if($(this).val()==dologObj.options){
|
||||||
|
$(this).attr("checked",true);
|
||||||
|
$(this).parents(".radio-inline").removeClass("hidden");
|
||||||
|
}else{
|
||||||
|
$(this).removeAttr("checked");
|
||||||
|
$(this).parents(".radio-inline").addClass("hidden");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}else{
|
||||||
|
$(".doLog").find("[name$='doLog']").each(function(){
|
||||||
|
var has=false;
|
||||||
|
for(var j in dologOptionValues){
|
||||||
|
if($(this).val()==dologOptionValues[j]){
|
||||||
|
has=true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(has){
|
||||||
|
$(this).parents(".radio-inline").removeClass("hidden");
|
||||||
|
}else{
|
||||||
|
$(this).parents(".radio-inline").addClass("hidden");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
if($(".doLog").find("[name$='doLog'] [value='"+doLogValue+"']:visible")){
|
||||||
|
$(".doLog").find("[name$='doLog'] [value='"+doLogValue+"']:visible").attr("checked",true);
|
||||||
|
}else if($(".doLog").find("[name$='doLog'] [value='2']:visible")){//默认值为2
|
||||||
|
$(".doLog").find("[name$='doLog'] [value='2']:visible").attr("checked",true);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
var doLogOpt=function(doLog){
|
||||||
|
var doLogObj={};
|
||||||
|
var doArr=doLog.split(';');
|
||||||
|
doLogObj.isShown=doArr[0];
|
||||||
|
doLogObj.options=doArr[1];
|
||||||
|
return doLogObj;
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user