diff --git a/src/main/webapp/WEB-INF/tags/sys/treeselect.tag b/src/main/webapp/WEB-INF/tags/sys/treeselect.tag index bc47cf5ed..294d2d9d5 100644 --- a/src/main/webapp/WEB-INF/tags/sys/treeselect.tag +++ b/src/main/webapp/WEB-INF/tags/sys/treeselect.tag @@ -28,7 +28,7 @@ <%@ attribute name="unCheckedPS" type="java.lang.String" required="false" description="复选框取消选中时是否关联父子节点,ps关联父子,p关联父,s关联子,都不关联为空"%>
- " data-msg-required="${dataMsgRequired}" placeholder="${empty value?labelValue:value}" class="${cssClass}" style="${cssStyle} background-color:transparent"/>
@@ -49,7 +49,7 @@ ajaxData:{selectIds: $("#${id}Id").val()},buttons:{"":"ok", "":"clear","":true}, submit:function(v, h, f){ if (v == "ok"){ var tree = h.find("iframe")[0].contentWindow.tree;//h.find("iframe").contents(); - var ids = [], names = [], nodes = [],types =[]; + var ids = [], names = [], nodes = []; if ("${checked}" == "true"){ nodes = tree.getCheckedNodes(true); }else{ @@ -100,12 +100,17 @@ }// names.push(nodes[i].name); - if(nodes[i].type){ - types.push(nodes[i].type); - } + //if(nodes[i].type){ + // types.push(nodes[i].type); + //} // break; // 如果为非复选框选择,则返回第一个选择 } + + if((nodes.length==1)&&(nodes[0].level == 0)&&('true'=='${notAllowSelectRoot}')){ + top.$.jBox.tip("("+nodes[0].name+")"); + return false; + } $("#${id}Id").val(ids.join(",").replace(/u_/ig,"")); //if(types.length>0){ // $("#${id}Id").attr('cfgtype',types.join(",")); @@ -120,9 +125,7 @@ //$("#${id}Id").removeAttr('cfgtype'); $("#${id}Id").change();//手动触发change事件,使Id的值得变化可以被监听到 $("#${id}Name").val(""); - if('${value}'){//如果值不存在,但是value却有值,将placeholder清空 - $("#${id}Name").attr("placeholder",""); - } + $("#${id}Name").attr("placeholder",""); } if(typeof ${id}TreeselectCallBack == 'function'){ ${id}TreeselectCallBack(v, h, f); diff --git a/src/main/webapp/WEB-INF/views/cfg/app/appPolicyCfgForm.jsp b/src/main/webapp/WEB-INF/views/cfg/app/appPolicyCfgForm.jsp index 5e1d0bb12..99b918ecb 100644 --- a/src/main/webapp/WEB-INF/views/cfg/app/appPolicyCfgForm.jsp +++ b/src/main/webapp/WEB-INF/views/cfg/app/appPolicyCfgForm.jsp @@ -201,8 +201,8 @@ var delContent = function(contentClassName, addBtnClassName) { + title="${spec_service_id}" url="/specific/specificServiceCfg/treeData?isLeafShow=false&cfgType=${app}" extId="0" + notAllowSelectRoot="true" cssClass="form-control required"/>
diff --git a/src/main/webapp/WEB-INF/views/cfg/basicprotocol/form.jsp b/src/main/webapp/WEB-INF/views/cfg/basicprotocol/form.jsp index 217a99c66..dd93fa071 100644 --- a/src/main/webapp/WEB-INF/views/cfg/basicprotocol/form.jsp +++ b/src/main/webapp/WEB-INF/views/cfg/basicprotocol/form.jsp @@ -153,8 +153,8 @@ var delContent = function(contentClassName, addBtnClassName) { + title="${spec_service_id}" url="/specific/specificServiceCfg/treeData?isLeafShow=false&cfgType=${app}" extId="0" + notAllowSelectRoot="true" cssClass="form-control required"/>
diff --git a/src/main/webapp/WEB-INF/views/cfg/encryptedtunnelbehav/form.jsp b/src/main/webapp/WEB-INF/views/cfg/encryptedtunnelbehav/form.jsp index d68a9267a..bee54a4ac 100644 --- a/src/main/webapp/WEB-INF/views/cfg/encryptedtunnelbehav/form.jsp +++ b/src/main/webapp/WEB-INF/views/cfg/encryptedtunnelbehav/form.jsp @@ -202,8 +202,8 @@ var delContent = function(contentClassName, addBtnClassName) { + title="${spec_service_id}" url="/specific/specificServiceCfg/treeData?isLeafShow=false&cfgType=${app}" extId="0" + notAllowSelectRoot="true" cssClass="form-control required"/>
diff --git a/src/main/webapp/WEB-INF/views/sys/tagTreeselect.jsp b/src/main/webapp/WEB-INF/views/sys/tagTreeselect.jsp index 026c03de2..079944d8a 100644 --- a/src/main/webapp/WEB-INF/views/sys/tagTreeselect.jsp +++ b/src/main/webapp/WEB-INF/views/sys/tagTreeselect.jsp @@ -89,7 +89,7 @@ for(var i=0; i