jQWidgets Forums

jQuery UI Widgets Forums Grid grid and input 'clear' function

This topic contains 1 reply, has 2 voices, and was last updated by  Dimitar 11 years, 1 month ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • grid and input 'clear' function #52381

    chiyun jo
    Participant

    Hello,

    I have two problems of clear function. I add a input & button, checked grid.

    <td class=’nomal’ style=’height:30px;’>
    <div id=”deviceSearchText” style=”overflow: hidden;”>
    <input type=”text”/>
    <div id=”deviceSearchBtn”>search</div>
    </div>
    </td>
    <td >
    <div id=”deviceSearchGrid”></div>
    </td>

    this is javasciprt.

    $(“#deviceSearchText”).jqxInput({ placeHolder: “Enter a Device”, height: 20, width: 212, minLength: 1, theme: ‘orange’ });
    $(“#deviceSearchGrid”).jqxGrid({ height: 150, width: 210, sortable: true, selectionmode: ‘checkbox’, altrows: true, theme: ‘ui-redmond’,
    columns: [ { text: “Device”, datafield: ‘device’, width: 100},
    { text: “P”, datafield: ‘pkg’, width: 30},
    { text: “D”, datafield: ‘dms’, width: 30},
    { text: “L”, datafield: ‘lead’, width: 30 },
    { text: “id”, datafield: ‘deviceid’, width: 1 }
    ]
    });

    first problem of grid

    1 step. click search button
    result -> 1000rows input at grid

    2 step. click all check box

    3 step. clear grid(by $(“#deviceSearchGrid”).jqxGrid(‘clear’);)

    4 step. again search button(empty input)
    result -> 500row input at grid and aleady checked all id.

    result -> var deviceRows = $(“#deviceSearchGrid”).jqxGrid(‘selectedrowindexes’);

    deviceRows is 1500,
    I need to only 500 rows.

    and second problem

    1 step. some text(ex, “aaa”) input at inputbox(include autocomplete data), and search button click.
    result -> var selectedDeviceJson = $(“#deviceSearchText”).val();
    selectedDeviceJson -> “aaa”
    2 step. delete some text and search button click.
    result -> selectedDeviceJson -> “aaa”
    I need “Enter a Device” or “”

    Thanks,

    grid and input 'clear' function #52465

    Dimitar
    Participant

    Hello chiyun jo,

    Please provide us with the code that implements the “search” functionality, as it is the one that may be erroneous. It would be best to create a simple example in JSFiddle that demonstrates the issue on a smaller scale.

    Best Regards,
    Dimitar

    jQWidgets team
    http://www.jqwidgets.com/

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

You must be logged in to reply to this topic.