This question is locked. New answers and comments are not allowed.
I have the following code in my script, which tries to add child asynchronously.
I want to send the TreeviewItem and the name of the new node to the controller action , How should I proceed?
I want to send the TreeviewItem and the name of the new node to the controller action , How should I proceed?
function AddCategory() { var treeViewElement = getTreeView(); var treeView = getTreeViewData(treeViewElement); var selected = getSelected(treeViewElement); // Add the category asynchronously. $.ajax({ type: "POST", url: "/Controller/Action" data: {parent: }, dataType: "json", // Not sure how to send data to controller action
// with prototype: ActionResult Action(TreeviewItem parent, string newNodeName) }) // Rebind the parent node by fetching children. treeView.ajaxRequest(selected);}