aboutsummaryrefslogtreecommitdiffstats
path: root/common/src/main/webapp/thirdparty/zTree/api/cn/zTreeObj.moveNode.html
diff options
context:
space:
mode:
Diffstat (limited to 'common/src/main/webapp/thirdparty/zTree/api/cn/zTreeObj.moveNode.html')
-rwxr-xr-xcommon/src/main/webapp/thirdparty/zTree/api/cn/zTreeObj.moveNode.html46
1 files changed, 46 insertions, 0 deletions
diff --git a/common/src/main/webapp/thirdparty/zTree/api/cn/zTreeObj.moveNode.html b/common/src/main/webapp/thirdparty/zTree/api/cn/zTreeObj.moveNode.html
new file mode 100755
index 00000000..9c9180b9
--- /dev/null
+++ b/common/src/main/webapp/thirdparty/zTree/api/cn/zTreeObj.moveNode.html
@@ -0,0 +1,46 @@
+<div class="apiDetail">
+<div>
+ <h2><span>Function(targetNode, treeNode, moveType, isSilent)</span><span class="path">zTreeObj.</span>moveNode</h2>
+ <h3>概述<span class="h3_info">[ 依赖 <span class="highlight_green">jquery.ztree.exedit</span> 扩展 js ]</span></h3>
+ <div class="desc">
+ <p></p>
+ <div class="longdesc">
+ <p>移动节点。</p>
+ <p class="highlight_red">请通过 zTree 对象执行此方法。</p>
+ </div>
+ </div>
+ <h3>Function 参数说明</h3>
+ <div class="desc">
+ <h4><b>targetNode</b><span>JSON</span></h4>
+ <p>要移动到的目标节点 JSON 数据</p>
+ <p class="highlight_red">如果移动成为根节点,请设置 targetNode 为 null 即可</p>
+ <p class="highlight_red">请务必保证此节点数据对象 是 zTree 内部的数据对象</p>
+ <h4 class="topLine"><b>treeNode</b><span>JSON</span></h4>
+ <p>需要被移动的节点数据</p>
+ <p class="highlight_red">请务必保证此节点数据对象 是 zTree 内部的数据对象</p>
+ <h4 class="topLine"><b>moveType</b><span>String</span></h4>
+ <p>指定移动到目标节点的相对位置</p>
+ <p class="highlight_red">"inner":成为子节点,"prev":成为同级前一个节点,"next":成为同级后一个节点</p>
+ <h4 class="topLine"><b>isSilent</b><span>Boolean</span></h4>
+ <p>设定移动节点后是否自动展开父节点。</p>
+ <p>isSilent = true 时,不展开父节点,其他值或缺省状态都自动展开。</p>
+ <h4 class="topLine"><b>返回值</b><span>JSON</span></h4>
+ <p>返回值是最终被移动的节点数据,正常情况下与 treeNode 参数完全相同</p>
+ <p class="highlight_red">如果 返回值 为 null,说明 移动失败,主要原因有:<br/>
+ &nbsp;1、targetNode 是 treeNode 父节点,且 moveType = "inner"<br/>
+ &nbsp;2、targetNode 是 treeNode 子孙节点
+ </p>
+ </div>
+ <h3>function 举例</h3>
+ <h4>1. 将根节点中第二个节点 移动成为 第一个节点的子节点</h4>
+ <pre xmlns=""><code>var treeObj = $.fn.zTree.getZTreeObj("tree");
+var nodes = treeObj.getNodes();
+treeObj.moveNode(nodes[0], nodes[1], "inner");
+</code></pre>
+ <h4>2. 将根节点中第二个节点 移动成为 第一个节点的前一个节点</h4>
+ <pre xmlns=""><code>var treeObj = $.fn.zTree.getZTreeObj("tree");
+var nodes = treeObj.getNodes();
+treeObj.moveNode(nodes[0], nodes[1], "prev");
+</code></pre>
+</div>
+</div> \ No newline at end of file