多域表单替换配置说明,替换为servic_config_info的table_desc字段,该字段需要修改为I18N的code

This commit is contained in:
wangxin
2018-04-03 16:33:25 +08:00
parent f5a7708fa9
commit 85ef87ec6e
10 changed files with 132 additions and 25 deletions

View File

@@ -13,7 +13,17 @@ $(function(){
}
})
</script>
<h3 class="form-section">增强字符串<spring:message code="block_config"/><!-- <small><span class="glyphicon glyphicon-chevron-down" data-toggle="collapse" data-target=".complexCfg" title="add"></span></small> --></h3>
<h3 class="form-section">
<c:choose>
<c:when test="${mainTableType eq '4' and otherTable==null}">
<spring:message code="${mainTableDesc}"/>
</c:when>
<c:when test="${otherTable!=null and otherTable.tableType eq '4'}">
<spring:message code="${otherTable.tableDesc}"/>
</c:when>
<c:otherwise>增强字符串<spring:message code="block_config"/></c:otherwise>
</c:choose>
<!-- <small><span class="glyphicon glyphicon-chevron-down" data-toggle="collapse" data-target=".complexCfg" title="add"></span></small> --></h3>
<div class="row complexCfg">
<div class="col-md-6">
<div class="form-group">

View File

@@ -3,7 +3,17 @@
<style>
</style>
<h3 class="form-section">IP<spring:message code="block_config"/><small><span style="margin-left:10px"><input type="checkbox" id="ipSelect"/> 可选</span><!-- <span class="glyphicon glyphicon-plus" data-toggle="collapse" data-target=".ipCfg" title="add"></span> --></small></h3>
<h3 class="form-section">
<c:choose>
<c:when test="${mainTableType eq '1' and otherTable==null}">
<spring:message code="${mainTableDesc}"/>
</c:when>
<c:when test="${otherTable!=null and otherTable.tableType eq '1'}">
<spring:message code="${otherTable.tableDesc}"/>
</c:when>
<c:otherwise>IP<spring:message code="block_config"/></c:otherwise>
</c:choose>
<small><span style="margin-left:10px"><input type="checkbox" id="ipSelect"/> 可选</span><!-- <span class="glyphicon glyphicon-plus" data-toggle="collapse" data-target=".ipCfg" title="add"></span> --></small></h3>
<div class="row ipCfg collapse">
<div class="col-md-6">
<div class="form-group">

View File

@@ -1,6 +1,16 @@
<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/include/taglib.jsp"%>
<h3 class="form-section">数值<spring:message code="block_config"/><small><span class="glyphicon glyphicon-chevron-down" data-toggle="collapse" data-target=".numCfg" title="add"></span></small></h3>
<h3 class="form-section">
<c:choose>
<c:when test="${mainTableType eq '3' and otherTable==null}">
<spring:message code="${mainTableDesc}"/>
</c:when>
<c:when test="${otherTable!=null and otherTable.tableType eq '3'}">
<spring:message code="${otherTable.tableDesc}"/>
</c:when>
<c:otherwise>数值<spring:message code="block_config"/></c:otherwise>
</c:choose>
<small><span class="glyphicon glyphicon-chevron-down" data-toggle="collapse" data-target=".numCfg" title="add"></span></small></h3>
<div class="row numCfg collapse">
<div class="col-md-6">
<div class="form-group">

View File

@@ -1,6 +1,16 @@
<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/include/taglib.jsp"%>
<h3 class="form-section">字符串<spring:message code="block_config"/><!-- <small><span class="glyphicon glyphicon-chevron-down" data-toggle="collapse" data-target=".stringCfg" title="add"></span></small> --></h3>
<h3 class="form-section">
<c:choose>
<c:when test="${mainTableType eq '2' and otherTable==null}">
<spring:message code="${mainTableDesc}"/>
</c:when>
<c:when test="${otherTable!=null and otherTable.tableType eq '2'}">
<spring:message code="${otherTable.tableDesc}"/>
</c:when>
<c:otherwise>字符串<spring:message code="block_config"/></c:otherwise>
</c:choose>
<!-- <small><span class="glyphicon glyphicon-chevron-down" data-toggle="collapse" data-target=".stringCfg" title="add"></span></small> --></h3>
<div class="row stringCfg">
<div class="col-md-6">
<div class="form-group">

View File

@@ -72,6 +72,7 @@
<form:form id="searchForm" modelAttribute="cfg" action="${ctx}/cfg/multiple/list" method="post" class="form-search">
<input id="mainTable" name="mainTable" type="hidden" value="${mainTable}"/>
<input id="mainTableType" name="mainTableType" type="hidden" value="${mainTableType}"/>
<input id="mainTableDesc" name="mainTableDesc" type="hidden" value="${mainTableDesc}"/>
<input id="cfgType" name="cfgType" type="hidden" value="${cfgType}"/>
<input id="cfgName" name="cfgName" type="hidden" value="${cfgName}"/>
<input id="action" name="action" type="hidden" value="${action}"/>
@@ -269,24 +270,24 @@
<c:choose>
<%--增强字符串 --%>
<c:when test="${mainTableType eq '4'}">
<th>增强字符串<spring:message code="config_describe"/></th>
<th><spring:message code="${mainTableDesc}"/><spring:message code="config_describe"/></th>
<th><spring:message code="match_area"/></th>
<th><spring:message code="key_word"/></th>
</c:when>
<%--数值 --%>
<c:when test="${mainTableType eq '3'}">
<th><spring:message code="${mainTable}"/><spring:message code="config_describe"/></th>
<th><spring:message code="${mainTableDesc}"/><spring:message code="config_describe"/></th>
<th><spring:message code="数值下界"/></th>
<th><spring:message code="数值上界"/></th>
</c:when>
<%--字符串 --%>
<c:when test="${mainTableType eq '2'}">
<th>字符串<spring:message code="config_describe"/></th>
<th><spring:message code="${mainTableDesc}"/><spring:message code="config_describe"/></th>
<th><spring:message code="key_word"/></th>
</c:when>
<%--IP --%>
<c:when test="${mainTableType eq '1'}">
<th>ip<spring:message code="config_describe"/></th>
<th><spring:message code="${mainTableDesc}"/><spring:message code="config_describe"/></th>
<th>ip<spring:message code="type"/></th>
<th><spring:message code="client_ip"/></th>
<th><spring:message code="client_address_mask"/></th>
@@ -304,21 +305,21 @@
<%--遍历子表属性 --%>
<c:forEach items="${cfg.otherTables}" var="other" varStatus="status">
<c:if test="${other.tableType eq '4'}">
<th>增强字符串<spring:message code="config_describe"/></th>
<th><spring:message code="${other.tableDesc}"/><spring:message code="config_describe"/></th>
<th><spring:message code="match_area"/></th>
<th><spring:message code="key_word"/></th>
</c:if>
<c:if test="${other.tableType eq '3'}">
<th><spring:message code="${other.tableName}"/><spring:message code="config_describe"/></th>
<th><spring:message code="${other.tableDesc}"/><spring:message code="config_describe"/></th>
<th><spring:message code="数值下界"/></th>
<th><spring:message code="数值上界"/></th>
</c:if>
<c:if test="${other.tableType eq'2'}">
<th>字符串<spring:message code="config_describe"/></th>
<th><spring:message code="${other.tableDesc}"/><spring:message code="config_describe"/></th>
<th><spring:message code="key_word"/></th>
</c:if>
<c:if test="${other.tableType eq '1'}">
<th>ip<spring:message code="config_describe"/></th>
<th><spring:message code="${other.tableDesc}"/><spring:message code="config_describe"/></th>
<th>ip<spring:message code="type"/></th>
<th><spring:message code="client_ip"/></th>
<th><spring:message code="client_address_mask"/></th>
@@ -524,22 +525,22 @@
<c:if test="${audit==0}">
<c:choose>
<c:when test="${bean.isAudit eq '2'}">
<li><a href="${ctx}/cfg/multiple/updateForm?serviceId=${bean.serviceId}&action=${bean.action}&compileId=${bean.compileId}&cfgName=${cfgName}&mainTable=${mainTable}&mainTableType=${mainTableType}" onclick="javascript:return confirm('sure', this.href)"><spring:message code="edit"></spring:message></a></li>
<li><a href="${ctx}/cfg/multiple/updateForm?serviceId=${bean.serviceId}&action=${bean.action}&compileId=${bean.compileId}&cfgName=${cfgName}&mainTable=${mainTable}&mainTableType=${mainTableType}&mainTableDesc=${mainTableDesc}" onclick="javascript:return confirm('sure', this.href)"><spring:message code="edit"></spring:message></a></li>
</c:when>
<c:when test="${bean.isAudit eq '0'}">
<li><a href="${ctx}/cfg/multiple/updateForm?serviceId=${bean.serviceId}&action=${bean.action}&compileId=${bean.compileId}&cfgName=${cfgName}&mainTable=${mainTable}&mainTableType=${mainTableType}" onclick="javascript:return confirm('sure', this.href)"><spring:message code="edit"></spring:message></a></li>
<li><a href="${ctx}/cfg/multiple/deleteCfg?serviceId=${bean.serviceId}&action=${bean.action}&compileId=${bean.compileId}&cfgName=${cfgName}&mainTable=${mainTable}&mainTableType=${mainTableType}" onclick="return confirm('sure', this.href)"><spring:message code="delete"></spring:message></a></li>
<li><a href="${ctx}/cfg/multiple/updateForm?serviceId=${bean.serviceId}&action=${bean.action}&compileId=${bean.compileId}&cfgName=${cfgName}&mainTable=${mainTable}&mainTableType=${mainTableType}&mainTableDesc=${mainTableDesc}" onclick="javascript:return confirm('sure', this.href)"><spring:message code="edit"></spring:message></a></li>
<li><a href="${ctx}/cfg/multiple/deleteCfg?serviceId=${bean.serviceId}&action=${bean.action}&compileId=${bean.compileId}&cfgName=${cfgName}&mainTable=${mainTable}&mainTableType=${mainTableType}&mainTableDesc=${mainTableDesc}" onclick="return confirm('sure', this.href)"><spring:message code="delete"></spring:message></a></li>
</c:when>
</c:choose>
</c:if>
<c:if test="${audit==1}">
<c:choose>
<c:when test="${bean.isAudit eq '1'}">
<li><a href="${ctx}/cfg/multiple/auditCfg?serviceId=${bean.serviceId}&action=${bean.action}&compileId=${bean.compileId}&isAudit=3&cfgName=${cfgName}&mainTable=${mainTable}" onclick="return confirm('sure', this.href)"><spring:message code="cancel"></spring:message></a></li>
<li><a href="${ctx}/cfg/multiple/auditCfg?serviceId=${bean.serviceId}&action=${bean.action}&compileId=${bean.compileId}&isAudit=3&cfgName=${cfgName}&mainTable=${mainTable}&mainTableType=${mainTableType}&mainTableDesc=${mainTableDesc}" onclick="return confirm('sure', this.href)"><spring:message code="cancel"></spring:message></a></li>
</c:when>
<c:when test="${bean.isAudit eq '0'}">
<li><a href="${ctx}/cfg/multiple/auditCfg?serviceId=${bean.serviceId}&action=${bean.action}&compileId=${bean.compileId}&isAudit=1&cfgName=${cfgName}&mainTable=${mainTable}" onclick="return confirm('sure', this.href)"><spring:message code="approved"></spring:message></a></li>
<li><a href="${ctx}/cfg/multiple/auditCfg?serviceId=${bean.serviceId}&action=${bean.action}&compileId=${bean.compileId}&isAudit=2&cfgName=${cfgName}&mainTable=${mainTable}" onclick="return confirm('sure', this.href)"><spring:message code="unapproved"></spring:message></a></li>
<li><a href="${ctx}/cfg/multiple/auditCfg?serviceId=${bean.serviceId}&action=${bean.action}&compileId=${bean.compileId}&isAudit=1&cfgName=${cfgName}&mainTable=${mainTable}&mainTableType=${mainTableType}&mainTableDesc=${mainTableDesc}" onclick="return confirm('sure', this.href)"><spring:message code="approved"></spring:message></a></li>
<li><a href="${ctx}/cfg/multiple/auditCfg?serviceId=${bean.serviceId}&action=${bean.action}&compileId=${bean.compileId}&isAudit=2&cfgName=${cfgName}&mainTable=${mainTable}&mainTableType=${mainTableType}&mainTableDesc=${mainTableDesc}" onclick="return confirm('sure', this.href)"><spring:message code="unapproved"></spring:message></a></li>
</c:when>
</c:choose>
</c:if>