jQuery UI Widgets Forums Navigation Tree Drag an item fires checkchange function

This topic contains 1 reply, has 2 voices, and was last updated by  ivailo 8 years, 5 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • Drag an item fires checkchange function #75777



    I’ve created a tree with three states checkboxes that has the drag and drop functionality, also, i have a function in the checkchange event that works fine when i check/uncheck an item, but whenever i drag-drop an item it fires the checkchange event too, i want to skip the function in that case (when performs drag-drop event), how should i do that?

    Thanks in advance, here’s my code:

    <!DOCTYPE html>
    <html lang=”en”>
    <link rel=”stylesheet” href=”../../jqwidgets/styles/jqx.base.css” type=”text/css” />
    <script type=”text/javascript” src=”../../scripts/jquery-1.11.1.min.js”></script>
    <script type=”text/javascript” src=”../../jqwidgets/jqxcore.js”></script>
    <script type=”text/javascript” src=”../../jqwidgets/jqxdata.js”></script>
    <script type=”text/javascript” src=”../../jqwidgets/jqxbuttons.js”></script>
    <script type=”text/javascript” src=”../../jqwidgets/jqxscrollbar.js”></script>
    <script type=”text/javascript” src=”../../jqwidgets/jqxpanel.js”></script>
    <script type=”text/javascript” src=”../../jqwidgets/jqxtree.js”></script>
    <script type=”text/javascript” src=”../../jqwidgets/jqxcheckbox.js”></script>
    <script type=”text/javascript” src=”../../jqwidgets/jqxexpander.js”></script>
    <script type=”text/javascript” src=”../../jqwidgets/jqxmenu.js”></script>
    <script type=”text/javascript” src=”../../jqwidgets/jqxdropdownbutton.js”></script>
    <script type=”text/javascript” src=”../../jqwidgets/jqxdragdrop.js”></script>
    <script type=”text/javascript”>
    $(document).ready(function () {
    $(‘#jqxTree’).jqxTree({width: 500, height: 700, checkboxes: true, hasThreeStates: true, allowDrag: true, allowDrop: true});
    $(‘#jqxTree’).on(‘checkChange’, function (event) {
    //i call a webservice on this function that performs a database transaction updating the status of the element
    <body class=’default’>
    <div id=’jqxWidget’>
    <div style=’float: left;’>
    <div id=’jqxTree’ style=float: left; margin-left: 20px;’>
    <li id=’0’ item-checked=’true’>Root

      <li id=’1’ item-checked=’true’ item-expanded=’true’>CATALOGS
      <li id=’2’ item-checked=’true’ >AGENCIES
      <li id=’3’ >AREAS

    <li id=’8’ item-checked=’true’ item-expanded=’true’>CLASIFICATION

      <li id=’9’>ENTITIES
      <li id=’10’ item-checked=’true’ >DEPENDENCIES


    Drag an item fires checkchange function #75846


    Hi alekzvargas,

    Thanks for the feedback. We will investigate the problem.

    Best Regards,
    Ivailo Ivanov

    jQWidgets Team

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.