2018-03-17 17:09:19 +08:00
|
|
|
<%@ page contentType="text/html;charset=UTF-8" %>
|
|
|
|
|
<%@ include file="/WEB-INF/include/taglib.jsp"%>
|
|
|
|
|
<html>
|
|
|
|
|
<head>
|
|
|
|
|
<title></title>
|
|
|
|
|
<script type="text/javascript">
|
2018-04-02 18:33:14 +08:00
|
|
|
var validateForm;
|
2018-03-17 17:09:19 +08:00
|
|
|
$(document).ready(function() {
|
|
|
|
|
//校验叶子节点有下级不得更改为叶子节点
|
|
|
|
|
jQuery.validator.addMethod("leafChange",function(value,element){
|
|
|
|
|
var flagLeafChange=false;
|
|
|
|
|
$.ajax({
|
|
|
|
|
type:'post',
|
|
|
|
|
async:false,
|
|
|
|
|
url:'${ctx}/specific/specificServiceCfg/ajaxLeafChange',
|
|
|
|
|
data:{parent:"${specificServiceCfg.specServiceId}",newIsLeaf:$("#isLeaf option:selected").val()},
|
|
|
|
|
success:function(data){
|
|
|
|
|
flagLeafChange=data;
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
return flagLeafChange;
|
2018-04-08 17:41:55 +08:00
|
|
|
},"<spring:message code='leafChange'/>");
|
2018-03-17 17:09:19 +08:00
|
|
|
|
|
|
|
|
$("#name").focus();
|
2018-04-02 18:33:14 +08:00
|
|
|
validateForm = $("#inputForm").validate({
|
2018-06-21 09:12:25 +08:00
|
|
|
/* rules:{
|
2018-03-21 18:19:03 +08:00
|
|
|
specServiceId:{
|
2018-03-17 17:09:19 +08:00
|
|
|
remote:'${ctx}/specific/specificServiceCfg/isIdRepeat?oldId=${specificServiceCfg.specServiceId}'
|
2018-04-09 17:56:41 +08:00
|
|
|
}
|
2018-03-17 17:09:19 +08:00
|
|
|
},
|
|
|
|
|
messages: {
|
2018-03-21 18:19:03 +08:00
|
|
|
specServiceId:{
|
2018-03-28 18:24:09 +08:00
|
|
|
remote:'<spring:message code="repeat"/>'
|
2018-03-17 17:09:19 +08:00
|
|
|
}
|
2018-06-21 09:12:25 +08:00
|
|
|
}, */
|
2018-03-17 17:09:19 +08:00
|
|
|
|
|
|
|
|
submitHandler: function(form){
|
2018-04-02 18:33:14 +08:00
|
|
|
if(!validateForm.form()) {
|
2018-03-17 17:09:19 +08:00
|
|
|
return false;
|
|
|
|
|
}
|
2018-04-08 17:41:55 +08:00
|
|
|
loading('<spring:message code="submitting"/>');
|
2018-03-17 17:09:19 +08:00
|
|
|
form.submit();
|
|
|
|
|
},
|
|
|
|
|
errorContainer: "#messageBox",
|
|
|
|
|
errorPlacement: function(error, element) {
|
|
|
|
|
$("#messageBox").text("输入有误,请先更正。");
|
|
|
|
|
if (element.is(":checkbox")||element.is(":radio")||element.parent().is(".input-append")){
|
|
|
|
|
error.appendTo(element.parent().parent());
|
|
|
|
|
} else {
|
|
|
|
|
error.insertAfter(element);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
</script>
|
|
|
|
|
</head>
|
|
|
|
|
<body>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="page-content">
|
|
|
|
|
|
|
|
|
|
<div class="theme-panel hidden-xs hidden-sm">
|
|
|
|
|
|
|
|
|
|
<button type="button" class="btn btn-default" onclick="history.go(-1)"><spring:message code="back"/></button>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<h3 class="page-title">
|
2018-03-21 13:43:43 +08:00
|
|
|
<spring:message code="specific_service_cfg"/>
|
2018-03-17 17:09:19 +08:00
|
|
|
</h3>
|
|
|
|
|
|
|
|
|
|
<div class="row">
|
|
|
|
|
<div class="col-md-12">
|
|
|
|
|
<div class="portlet box blue">
|
|
|
|
|
<div class="portlet-title">
|
|
|
|
|
<div class="caption">
|
2018-03-28 18:24:09 +08:00
|
|
|
<i class="fa fa-gift"></i><c:if test="${not empty specificServiceCfg.specServiceId}"><spring:message code='edit'/></c:if><c:if test="${empty specificServiceCfg.specServiceId}"><spring:message code='add'/></c:if></div>
|
2018-03-17 17:09:19 +08:00
|
|
|
<div class="tools">
|
|
|
|
|
<!-- <a href="javascript:;" class="collapse"> </a>
|
|
|
|
|
<a href="#portlet-config" data-toggle="modal" class="config"> </a>
|
|
|
|
|
<a href="javascript:;" class="reload"> </a>
|
|
|
|
|
<a href="javascript:;" class="remove"> </a> -->
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="portlet-body form">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="form-body">
|
|
|
|
|
|
|
|
|
|
<!-- BEGIN FORM-->
|
|
|
|
|
<form:form id="inputForm" modelAttribute="specificServiceCfg" action="${ctx}/specific/specificServiceCfg/saveOrUpdate" method="post" class="form-horizontal">
|
2018-06-21 09:12:25 +08:00
|
|
|
<input name="specServiceId" type="hidden" value="${specificServiceCfg.specServiceId}"/>
|
2018-03-17 17:09:19 +08:00
|
|
|
<form:hidden path="isValid" class="form-control"/>
|
|
|
|
|
<sys:message content="${message}"/>
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
<label class="col-md-3 control-label"><spring:message code="superior_config"/>:</label>
|
|
|
|
|
<div class="col-md-4">
|
2018-03-28 18:24:09 +08:00
|
|
|
<c:set var="fatherName"><spring:message code="root_node"/></c:set>
|
2018-03-29 18:45:37 +08:00
|
|
|
<sys:treeselect id="specificServiceCfg" name="parent.specServiceId" value="${specificServiceCfg.parent.specServiceId}" labelName="parent.specServiceName" labelValue="${specificServiceCfg.parent.specServiceId eq '0'?fatherName:fns:getBySpecServiceId(specificServiceCfg.parent.specServiceId).specServiceName}"
|
2018-06-21 09:12:25 +08:00
|
|
|
title="" url="/specific/specificServiceCfg/treeData" extId="${specificServiceCfg.specServiceId}" cssClass="required form-control"/>
|
2018-03-17 17:09:19 +08:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="form-group">
|
2018-06-21 09:12:25 +08:00
|
|
|
<label class="col-md-3 control-label"><font color="red">*</font><spring:message code="protocol_code"/>:</label>
|
2018-03-17 17:09:19 +08:00
|
|
|
<div class="col-md-4">
|
2018-06-21 09:12:25 +08:00
|
|
|
<input id="specServiceCode" name="specServiceCode" maxlength="50" range="[0,2147483647]" class="form-control required digits" value="${specificServiceCfg.specServiceCode}"/>
|
2018-03-17 17:09:19 +08:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="form-group">
|
2018-03-22 16:27:56 +08:00
|
|
|
<label class="col-md-3 control-label"><font color="red">*</font><spring:message code="protocol_name"/>:</label>
|
2018-03-17 17:09:19 +08:00
|
|
|
<div class="col-md-4">
|
2018-04-08 17:41:55 +08:00
|
|
|
<form:input path="specServiceName" htmlEscape="false" maxlength="64" class="form-control required noBlankSpace"/>
|
2018-03-17 17:09:19 +08:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="form-group">
|
2018-03-22 16:27:56 +08:00
|
|
|
<label class="col-md-3 control-label"><spring:message code="group_id"/>:</label>
|
2018-03-17 17:09:19 +08:00
|
|
|
<div class="col-md-4">
|
2018-04-09 17:56:41 +08:00
|
|
|
<form:input path="groupId" htmlEscape="false" maxlength="50" range="[0,2147483647]" class="form-control digits" placeholder="0"/>
|
2018-03-17 17:09:19 +08:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
<label class="col-md-3 control-label"><font color="red">*</font><spring:message code="is_leaf"/>:</label>
|
|
|
|
|
<div class="col-md-4">
|
2018-04-08 17:41:55 +08:00
|
|
|
<form:select path="isLeaf" class="form-control leafChange">
|
2018-03-28 18:24:09 +08:00
|
|
|
<c:forEach items="${fns:getDictList('INT_YES_NO')}" var="dict">
|
|
|
|
|
<form:option value="${dict.itemCode}"><spring:message code="${dict.itemValue}"/></form:option>
|
|
|
|
|
</c:forEach>
|
|
|
|
|
</form:select>
|
2018-03-17 17:09:19 +08:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="form-group">
|
2018-03-22 16:27:56 +08:00
|
|
|
<label class="col-md-3 control-label"><spring:message code="protocol_desc"/>:</label>
|
2018-03-17 17:09:19 +08:00
|
|
|
<div class="col-md-4">
|
2018-04-08 17:41:55 +08:00
|
|
|
<form:textarea path="specServiceDesc" htmlEscape="false" maxlength="64" class="form-control"/>
|
2018-03-17 17:09:19 +08:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="form-actions">
|
|
|
|
|
<div class="row">
|
|
|
|
|
<div class="col-md-offset-3 col-md-9">
|
2018-03-28 18:24:09 +08:00
|
|
|
<shiro:hasPermission name="specific:service:edit"><button type="submit" class="btn btn-circle blue"><spring:message code="submit"/></button></shiro:hasPermission>
|
2018-03-17 17:09:19 +08:00
|
|
|
<button type="button" class="btn btn-circle grey-salsa btn-outline" onclick="history.go(-1)"><spring:message code="cancel"/></button>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</form:form>
|
|
|
|
|
<!-- END FORM-->
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</body>
|
|
|
|
|
</html>
|