Link to home
Start Free TrialLog in
Avatar of skillilea
skillilea

asked on

JQuery UI [Sortable]: Help with input textbox in LI

Issue:  Input box is locked when I enable the sortable.


Here is my doc ready:

    //  handle drag sort for pareto SORT
    $('#jqParetoEditList').sortable({
        cancel: ".fixed",
        delay: 100,
        //connectWith: "",
        stop: function (event, ui) {
            p.HandleSortPareto(ui, ui.item)  // note this just handles the change in order
        },
        start: function (event, ui) {
        }
    });



Here is my li build:

                t += "<li data-id='" + d.ItemID + "' class='jqSortParLI'>" +
                       "<div><img src='/img/site/hb_16x16.png' class='jqSortParHand' /></div>" +
                       "<div><input id='ParITEMX_" + d.ItemID + "' class='parINP' type='text'  maxlength='120'/></div>";
                var a = (d.IsActive ==1) ?" checked" : "";
                t+=       "<div><input type='checkbox' " + a + "/></div>" +
                    "</li>";

The container UL is:  #jqParetoEditList



Any help would be awesome.

Note: The sort works just fine it's trying to edit the text in the input boxes that is locked.

thanks in advance.

sk
Avatar of Gary
Gary
Flag of Ireland image

What do you mean locked?
Do you have a link to the page or can you make a test case at http://jsfiddle.net
Avatar of skillilea
skillilea

ASKER

I mean I can't click into the text box to edit.  I think SORTABLE overrides it.  I'll work on a fiddle.

tnx TONS

sk
That's counter intuitive - for something to be sortable it has to be draggable and it cannot be draggable if you can click into the element.
I've requested that this question be closed as follows:

Accepted answer: 0 points for skillilea's comment #a40240891

for the following reason:

Posted on fiddle
ASKER CERTIFIED SOLUTION
Avatar of skillilea
skillilea

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Found the solution.