From fdfb82345e6d68c40dca419b80c9ebc870efff3e Mon Sep 17 00:00:00 2001 From: dabeng Date: Tue, 28 Jun 2016 13:44:55 +0800 Subject: [PATCH] update readme --- README.md | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 72fe6bbb..19bc14de 100644 --- a/README.md +++ b/README.md @@ -352,7 +352,11 @@ $('#btn-delete-nodes').on('click', function() { - **[I wanna drag & drop the nodes of orgchart](http://dabeng.github.io/OrgChart/drag-drop/)** -Users are allowed to drag & drop the nodes of orgchart when option "draggable" is assigned to true. Furthermore, users can make use of option dropCriteria to inject their custom limitations on drag & drop. As shown below, we don't want an manager employee to be under a engineer under no circumstance. +Users are allowed to drag & drop the nodes of orgchart when option "draggable" is assigned to true. + +![drag & drop](http://dabeng.github.io/OrgChart/drag-drop/recorder.gif) + +Furthermore, users can make use of option dropCriteria to inject their custom limitations on drag & drop. As shown below, we don't want an manager employee to be under a engineer under no circumstance. ```js // sample of core source code $('#chart-container').orgchart({ @@ -368,8 +372,6 @@ $('#chart-container').orgchart({ }) ``` -![drag & drop](http://dabeng.github.io/OrgChart/drag-drop/recorder.gif) - - **[I want a method that can decribe the hierarchy of orgchart](http://dabeng.github.io/OrgChart/get-hierarchy/)** That's where getHierarchy() comes in. @@ -542,6 +544,9 @@ $('#chartContainerId').orgchart(options); draggablebooleannofalseUsers can drag & drop the nodes of orgchart if they enable this option + + dropCriteriafunctionnoUsers can construct their own criteria to limit the relationships between dragged node and drop zone. Furtherly, this function accept three arguments(draggedNode, dragZone, dropZone) and just only return boolen values. +