jQWidgets Forums

jQuery UI Widgets Forums Layouts Kanban Kanban cancel

Tagged: 

This topic contains 1 reply, has 2 voices, and was last updated by  ivanpeevski 1 year, 9 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • Kanban cancel #133384

    EricK
    Participant

    Hello to all.
    I am trying to setup a message window to confirm the move. Not sure how to control the cancel option and move the moved item back to the original column.
    Does anyone have any ideas on how to perform this procedure.

    Thanks erick

    Kanban cancel #133387

    ivanpeevski
    Participant

    Hi EricK,

    You can use the itemMoved event to capture the moment when the user drops an item. Here is an example:

    $(‘#kanban’).on(‘itemReceived’, function (event) {
    var args = event.args;
    var itemId = args.itemId;
    var oldParentId = args.oldParentId;
    var newParentId = args.newParentId;
    var itemData = args.itemData;
    var oldColumn = args.oldColumn;
    var newColumn = args.newColumn;
    if(!confirm(“Confirm Move?”)){
    setTimeout(function(){
    itemData[“status”] = oldColumn.dataField;
    $(‘#kanban’).jqxKanban(‘removeItem’, itemId);
    $(‘#kanban’).jqxKanban(‘addItem’, itemData);
    }, 5)

    }
    });

    Best Regards,
    Ivan Peevski
    jQWidgets Support
    http://www.jqwidgets.com

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

You must be logged in to reply to this topic.