public/assets/js/custom_js/HaseImageActivityRegionTree.js
/**
 * Function is use for expand the image category tree with selected value.
 * @param array nodeIdList.
 * @param string autoCompleteUrl.
 * @param string treeName.
 * @param string autoCompleteName.
 * @param integer autoCompleteJsonItems.
 */
Function is use for expand the image category tree with selected value.
Function is use for expand the image category tree with selected value .
function expandCategoryTree(nodeIdList, autoCompleteUrl, treeName, autoCompleteName, autoCompleteJsonItems) {
    var nodeId = [];
    var nodeId = nodeIdList.split(activityRegionTreeView.ACTIVITY_REGION_SPLIT_VALUE);
    nodeId = nodeId.filter(onlyUniqueItem);
    var nodeLength = (nodeId.length);
    var treeView = jQuery(activityRegionTreeView.HASH_SYMBOL + treeName).data(activityRegionTreeView.KENDO_TREE_VIEW_VALUE);
    treeView.setOptions({
        animation: false
    });
    treeView.collapse(activityRegionTreeView.KENDO_ITEM_VALUE);
    for (nodeCount = activityRegionTreeView.FIRST_NODE_INDEX; nodeCount < nodeLength; nodeCount++) {
        var nodeDetail = getJsonObjects(autoCompleteJsonItems, activityRegionTreeView.REGION_ACTIVITY_TEXT_VALUE, nodeId[nodeCount]);
        if (nodeDetail[activityRegionTreeView.FIRST_NODE_INDEX] == undefined) {
            continue;
        }
        var treeDataSource = treeView.dataSource;
        var treeNodePath = nodeDetail[activityRegionTreeView.FIRST_NODE_INDEX].path;
        treeNodePath = treeNodePath.replace(activityRegionTreeView.TREE_NODE_PATH_FORWARD_SLASH, activityRegionTreeView.ACTIVITY_REGION_SPLIT_VALUE);
        openCategoryTreePath(treeView, treeNodePath);
    }
    treeView.setOptions({
        animation: kendo.ui.TreeView.fn.options.animation
    });
}
function expandCategoryTree ( nodeIdList , autoCompleteUrl , treeName , autoCompleteName , autoCompleteJsonItems ) { var nodeId = [ ] ; var nodeId = nodeIdList . split ( activityRegionTreeView . ACTIVITY_REGION_SPLIT_VALUE ) ; nodeId = nodeId . filter ( onlyUniqueItem ) ; var nodeLength = ( nodeId . length ) ; var treeView = jQuery ( activityRegionTreeView . HASH_SYMBOL + treeName ) . data ( activityRegionTreeView . KENDO_TREE_VIEW_VALUE ) ; treeView . setOptions ( { animation : false } ) ; treeView . collapse ( activityRegionTreeView . KENDO_ITEM_VALUE ) ; for ( nodeCount = activityRegionTreeView . FIRST_NODE_INDEX ; nodeCount < nodeLength ; nodeCount ++ ) { var nodeDetail = getJsonObjects ( autoCompleteJsonItems , activityRegionTreeView . REGION_ACTIVITY_TEXT_VALUE , nodeId [ nodeCount ] ) ; if ( nodeDetail [ activityRegionTreeView . FIRST_NODE_INDEX ] == undefined ) { continue ; } var treeDataSource = treeView . dataSource ; var treeNodePath = nodeDetail [ activityRegionTreeView . FIRST_NODE_INDEX ] . path ; treeNodePath = treeNodePath . replace ( activityRegionTreeView . TREE_NODE_PATH_FORWARD_SLASH , activityRegionTreeView . ACTIVITY_REGION_SPLIT_VALUE ) ; openCategoryTreePath ( treeView , treeNodePath ) ; } treeView . setOptions ( { animation : kendo . ui . TreeView . fn . options . animation } ) ; }
Function is use for expand the image category tree with selected value.
Function is use for expand the image category tree with selected value .