同步界面增加业务的回传,业同步业务从xml中获取
This commit is contained in:
@@ -5,6 +5,7 @@ import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.dom4j.Node;
|
||||
|
||||
import com.google.common.collect.Lists;
|
||||
import com.google.common.collect.Maps;
|
||||
@@ -246,6 +247,24 @@ public class DictUtils {
|
||||
|
||||
return allDictList;
|
||||
}
|
||||
|
||||
/**
|
||||
* 功能业务字典,获取相应功能菜单对应的业务信息
|
||||
* @param functionId
|
||||
* @return
|
||||
*/
|
||||
public static List<FunctionServiceDict> getAllServiceList(){
|
||||
List<FunctionServiceDict> serviceList = new ArrayList();
|
||||
ServiceConfigTemplateUtil serviceTemplate = new ServiceConfigTemplateUtil();
|
||||
List<Node> serviceNodeList= serviceTemplate.getServiceNodeList();
|
||||
for (Node node : serviceNodeList) {
|
||||
FunctionServiceDict service=new FunctionServiceDict();
|
||||
service.setServiceId(Integer.valueOf(node.valueOf("@id")));
|
||||
service.setServiceName(node.valueOf("@desc"));
|
||||
serviceList.add(service);
|
||||
}
|
||||
return serviceList;
|
||||
}
|
||||
/**
|
||||
* 功能配置域字典,获取相应功能菜单对应的配置域信息
|
||||
* @param functionId
|
||||
|
||||
@@ -79,6 +79,7 @@ public class ConfigSynchronizationController extends BaseController {
|
||||
|
||||
}
|
||||
}
|
||||
model.addAttribute("serviceId", serviceId);
|
||||
return "/sys/configSyncInfo";
|
||||
}
|
||||
|
||||
|
||||
@@ -138,12 +138,6 @@
|
||||
<service id="67" functionId="6" serviceType="1" tableName="cfg_index_info" className="CfgIndexInfo" desc="URL白名单">
|
||||
<serviceCfg cfgType="2" tableName="http_url_cfg" ></serviceCfg>
|
||||
</service>
|
||||
<service id="129" functionId="6" serviceType="1" tableName="cfg_index_info" className="CfgIndexInfo" desc="URL监测">
|
||||
<serviceCfg cfgType="2" tableName="http_url_cfg" ></serviceCfg>
|
||||
</service>
|
||||
<service id="17" functionId="6" serviceType="1" tableName="cfg_index_info" className="CfgIndexInfo" desc="URL阻断">
|
||||
<serviceCfg cfgType="2" tableName="http_url_cfg" ></serviceCfg>
|
||||
</service>
|
||||
<!-- <service id="129" functionId="6" serviceType="1" tableName="cfg_index_info" className="CfgIndexInfo">
|
||||
<serviceCfg cfgType="2" tableName="http_url_cfg" ></serviceCfg>
|
||||
</service>
|
||||
|
||||
@@ -229,7 +229,7 @@
|
||||
<description>获取service列表</description>
|
||||
<name>getAllFunctionServiceDictList</name>
|
||||
<function-class>com.nis.util.DictUtils</function-class>
|
||||
<function-signature>java.util.List getFunctionServiceDictList()</function-signature>
|
||||
<function-signature>java.util.List getAllServiceList()</function-signature>
|
||||
<example>${fns:getAllFunctionServiceDictList()}</example>
|
||||
</function>
|
||||
<function>
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
<title></title>
|
||||
<script type="text/javascript">
|
||||
$(document) .ready(function() {
|
||||
changeService();
|
||||
top.$.jBox.closeTip();
|
||||
$("#cfgFrom").validate({
|
||||
submitHandler : function(form) {
|
||||
@@ -46,11 +47,13 @@
|
||||
</h2>
|
||||
<div class="col-md-2">
|
||||
<div class="col-md-12">
|
||||
<select name="service" id="service" data-live-search="true" class="selectpicker show-tick form-control required " onchange="changeService()">
|
||||
<option value="" ><spring:message code="all" /></option>
|
||||
<select name="service" id="service" data-live-search="true" class="selectpicker show-tick form-control " onchange="changeService()">
|
||||
<option value="" <c:if test="${empty serviceId }">selected</c:if>><spring:message code="all" /></option>
|
||||
<c:forEach items="${fns:getAllFunctionServiceDictList()}"
|
||||
var="_service">
|
||||
<option value="${_service.serviceId }" ><spring:message code="${_service.serviceName }" /></option>
|
||||
<option value="${_service.serviceId }" <c:if test="${_service.serviceId eq serviceId }">selected</c:if>>
|
||||
<spring:message code="${_service.serviceName }" />
|
||||
</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user