jQWidgets Forums

jQuery UI Widgets Forums Grid Grid – Checkbox custom inline editor

This topic contains 2 replies, has 2 voices, and was last updated by  gio 8 years, 7 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
  • Grid – Checkbox custom inline editor #89590

    gio
    Participant

    Hi,
    I’m trying to create my custom checkbox editor for boolean fields using the fontawesome icons.

    Here is my sample.

    I wonder if you can help me to understand why the editing still requires a double click, even if I set the editmode option of the grid to “click”.
    My goal is to update the value by clicking only once on the shown icon in the grid cell.

    Thanks in advance for your help.
    Giovanni

    Grid – Checkbox custom inline editor #89602

    Hristo
    Participant

    Hello Giovanni,

    Maybe you could try to use selectionmode: 'singlecell', (instead of “editmode: ‘click’,”) because otherwise start to edit the cell and this will enter to ‘cellsrenderer’ callback.
    We recommend using our widgets and API to achieve this.
    I would like to give some hints.
    You could use simple boolean type column and bind to ‘cellclick’ event (or ‘rowclick’).
    After clicking, checks the current value and set opposite to this cell – for this could use setcellvalue method of the Grid.

    About custom view of the cells I would like to suggest you look at this demo (mention about to focus on ‘cellclassname’).

    Best Regards,
    Hristo Hristov

    jQWidgets team
    http://www.jqwidgets.com

    Grid – Checkbox custom inline editor #89650

    gio
    Participant

    Hi Hristo,
    I exactly followed the approach you suggested with cell click and setcellvalue, the result is the user experience I was looking for.

    Thanks
    BR
    Giovanni

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

You must be logged in to reply to this topic.