<!doctype html>
|
<html class="no-js">
|
<head>
|
<meta charset="utf-8">
|
<title>增加/修改配置分类</title>
|
|
[#include "/business/pages/include/static.html" /]
|
</head>
|
<body class="end_task_body widthauto">
|
|
<script type="text/javascript">
|
$(function() {
|
$.formValidator.initConfig({formID:"myform",onError:function(msg){popupTips(msg)},onSuccess:function(){
|
document.getElementById("myform").target = window.top.openDialog("1","操作",
|
{},
|
{"width":40,"height":40},[{btnId:"tipBtnSure", btnName:"确定", btnStyle:"bluebtn"}]);
|
return true;
|
}});
|
|
|
$("#gnmc").formValidator({empty:false,onFocus:"请输入功能的名称"}).inputValidator({min:4,max:20,onError:"功能名称4-20个字符或2-10个汉字"});
|
[#if RequestParameters.type == 2 || info.TYPE == 3]
|
$("#address").formValidator({empty:false,onShow:"功能的访问地址",onFocus:"请输入功能的访问地址"}).inputValidator({min:4,max:80,onError:"功能地址4-80个字符或2-40个汉字"});
|
|
[#if info.GN_MARK == ""]
|
$("#gn_mark").formValidator({empty:false,onShow:"请输入功能标志",onFocus:"功能标志由大写字母组成长度为3~10位"}).inputValidator({min:3,max:10,onCorrect:"123",onError:"功能标志由大写字母组成长度为3~10位"})
|
.regexValidator({regExp:"letter_u",param:"g",dataType:"enum",onError:"功能标志只能由大写字母组成"})
|
.ajaxValidator({
|
dataType : "html",
|
async : true,
|
url : "checkGn_mark.html?sjbh=${sjbh}",
|
success : function(data){
|
if( data == 0 ) return true;
|
if( data == 1 ) return false;
|
return false;
|
},
|
buttons: $("#dosubmit"),
|
error: function(jqXHR, textStatus, errorThrown){alert("服务器没有返回数据,可能服务器忙,请重试"+errorThrown);},
|
onError : "该功能标志已存在,请更换标志",
|
onWait : "正在对标志进行合法性校验,请稍候..."
|
});
|
[#else]
|
$("#gn_mark").formValidator({empty:false,onShow:"功能标志不允许修改!",onFocus:"功能标志不允许修改!"}).inputValidator({min:3,max:10,onCorrect:"123",onError:"功能标志不允许修改!"});
|
[/#if]
|
[/#if]
|
$("#sxh").formValidator({empty:false,onFocus:"请输入顺序号"}).inputValidator({min:1,max:5,onError:"顺序号必须为1到5位"})
|
.regexValidator({regExp:"intege1", dataType:"enum", onError:"顺序号必须为正整数"});
|
$("#big_image").formValidator({empty:true,onShow:"大图标用在页面头部,目前仅对一级菜单有效!",onFocus:"大图标用在页面头部,目前仅对一级菜单有效!"})
|
.inputValidator({min:3,max:200,onError:"非法文件路径"})
|
.regexValidator({regExp:"picture1", dataType:"enum", onError:"文件格式必须为:jpg|jpeg||png格式"});
|
$("#medium_image").formValidator({empty:true,onShow:"中图标用在页面左侧菜单,目前仅对三级菜单有效!",onFocus:"中图标用在页面左侧菜单,目前仅对三级菜单有效!"})
|
.inputValidator({min:3,max:200,onError:"非法文件路径"})
|
.regexValidator({regExp:"picture1", dataType:"enum", onError:"文件格式必须为:jpg|jpeg||png格式"});
|
$("#small_image").formValidator({empty:true,onShow:"小图标用在功能选项卡,目前仅对二、三级菜单有效!",onFocus:"小图标用在功能选项卡,目前仅对二、三级菜单有效!"})
|
.inputValidator({min:3,max:200,onError:"非法文件路径"})
|
.regexValidator({regExp:"picture1", dataType:"enum", onError:"文件格式必须为:jpg|jpeg||png格式"});
|
|
})
|
</script>
|
|
<div class="edit_txt">
|
<form action="addXtgnSubmit.html" method="post" enctype="multipart/form-data" id="myform" name="myform" >
|
<input type="hidden" name="sjbh" value="${RequestParameters.sjbh!info.SJBH}" />
|
<input type="hidden" name="id" value="${RequestParameters.id!info.ID}" />
|
<table class="edit_layout2">
|
<tr><th ><label class="required" >功能名称:</label></th>
|
<td><input class="general" type="text" value="${info.GNMC}" name="gnmc" id="gnmc"/>
|
|
</td>
|
<td><div id="gnmcTip" style="display:inline-block;"></div></td>
|
</tr>
|
[#if RequestParameters.type == 2 || info.TYPE == 3]
|
<tr><th ><label class="required" >功能地址:</label></th>
|
<td><input class="general" type="text" value="${info.ADDRESS}" name="address" id="address" style="width:98%;"/>
|
|
</td>
|
<td><div id="addressTip" style="display:inline-block;width:250px;"></div></td>
|
</tr>
|
<tr><th ><label class="required" >功能标志:</label></th>
|
<td><input class="general" type="text" value="${info.GN_MARK}" name="gn_mark" id="gn_mark" style="width:130px;" [#if info.GN_MARK !=""]readonly[/#if] />
|
|
</td>
|
<td><div id="gn_markTip" style="display:inline-block;width:300px;"></div></td>
|
</tr>
|
[/#if]
|
<tr><th ><label class="required" >顺序号:</label></th>
|
<td><input class="general" type="text" value="${info.SXH}" name="sxh" id="sxh"/>
|
|
</td>
|
<td><div id="sxhTip" style="display:inline-block;width:200px;"></div></td>
|
</tr>
|
<tr>
|
<th align="right">是否预留:</th>
|
<td colspan="2" >
|
<input class="audit" type="radio" name="sfyl" value="0" checked />否
|
<input class="audit" type="radio" name="sfyl" value="1" [#if info.SFYL == 1] checked [/#if] />是
|
</td>
|
</tr>
|
<tr>
|
<th align="right">大图标:</th>
|
<td><input type="file" value="" class="general" name="big_image" id="big_image" style="width:130px;"/>
|
[#if info.BIG_IMAGE??]<img src="${base+info.BIG_IMAGE}" border="0" />[/#if]
|
|
</td>
|
<td><div id="big_imageTip" style="width:320px;"></div></td>
|
</tr>
|
<tr>
|
<th align="right">中图标:</th>
|
<td><input type="file" value="" class="general" name="medium_image" id="medium_image" style="width:130px;"/>
|
[#if info.MEDIUM_IMAGE??]<img src="${base+info.MEDIUM_IMAGE}" border="0" />[/#if]
|
|
</td>
|
<td> <div id="medium_imageTip" style="width:320px;"></div></td>
|
</tr>
|
<tr>
|
<th align="right">小图标:</th>
|
<td><input type="file" value="" class="general" name="small_image" id="small_image" style="width:130px;"/>
|
[#if info.SMALL_IMAGE??]<img src="${base+info.SMALL_IMAGE}" border="0" />[/#if]
|
|
</td>
|
<td><div id="small_imageTip" style="width:320px;"></div></td>
|
</tr>
|
<tr><th><label >说明:</label></th>
|
<td colspan="2"><textarea class="general" style="width:360px;" name="beiz" id="beiz"/>${info.BEIZ}</textarea>
|
</td>
|
</tr>
|
</table>
|
</form>
|
</div>
|
|
|
|
<script type="text/javascript">
|
function onDialogBtnClick(btnID, dialogID, config){
|
if(btnID == "btnSure"){
|
$("#myform").submit();
|
}
|
}
|
|
</script>
|
|
|
</body>
|
</html>
|