jQWidgets Forums

jQuery UI Widgets Forums Grid Columns reorder and cell editing

This topic contains 10 replies, has 2 voices, and was last updated by  alexz 12 years, 1 month ago.

Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
  • Columns reorder and cell editing #16668

    alexz
    Member

    Hi,

    I noticed an interesting problem, when you have columnsreorder enabled, you can navigate inside cell only by keyboard arrows. Click changes the cell to editing mode as it should, but subsequent clicks do not put cursor to desired position inside the cell.

    <script type="text/javascript">
    $(document).ready(function () {
    var gridJsonData = [{ "Id": "1", "Name": "Alfreds Futterkiste"}];
    // prepare the data
    var source = {
    datatype: "json",
    localdata: gridJsonData,
    datafields: [{ name: 'Id', type:'int' }
    ,{name: 'Name', type:'string', odatatype:'String' }
    ,{name: 'StatusName', type:'string', odatatype:'String' }]
    };
    var dataAdapter = new $.jqx.dataAdapter(source);
    $('#jqxAjaxGridRoute').jqxGrid({source:dataAdapter
    , editable: true
    // THIS IS THE PROBLEM
    ,columnsreorder:true
    ,selectionmode:'singlecell'
    ,editmode:'dblclick'
    ,width:'100%'
    ,columns:[{datafield: 'Id',draggable: false,filterable: false,sortable: false,menu: false,width: '3%'}
    ,{editable: true,text: 'Nimi',datafield: 'Name'}]});});
    </script>
    <div id="jqxAjaxGridRoute"></div>
    Columns reorder and cell editing #16675

    Peter Stoev
    Keymaster

    Hi alexz,

    1. We are unable to reproduce the reported behavior. After reordering the columns, the cells editing and navigation works as expected.
    2. jqxGrid columns do not have a property called “odatatype”.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

    Columns reorder and cell editing #16683

    alexz
    Member

    Thanks Peter, odatatype is just for my own purposes, it does not affect the behavior. I have the latest version of jqx (2.7.0 and 1.8.2 jquery)

    Can you send me working sample by email?

    All the best,
    Alex

    Columns reorder and cell editing #16685

    Peter Stoev
    Keymaster

    Hi Alex,

    The test is done using the Editing sample: cellediting.htm. I added columns resorder to the sample, reordered a column and the input, mouse + kb navigation were correct.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

    Columns reorder and cell editing #16688

    alexz
    Member

    Thanks Peter, the only difference seems to be single click edit, when I have double click (dblclick)?

    Columns reorder and cell editing #16689

    Peter Stoev
    Keymaster

    Hi alexz,

    The “editmode” does not matter. In doubleclick mode you will just have to click 2 times to begin or end editing.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

    Columns reorder and cell editing #16690

    alexz
    Member

    Hi Peter,

    now I’ve tried to set cell edition params like in your solution and it still does not work. When I open your sample there’s no columns reorder by drag and drop. Are you sure you added it there? I tried with latest IE and Firefox with no results.

    All the Best,
    Alex

    Columns reorder and cell editing #16694

    Peter Stoev
    Keymaster

    Hi alexz,

    Please, re-read my post – ” I added columns reorder to the sample, reordered a column and the input, mouse + kb navigation were correct.”.

    This means that I added columns reorder by setting the “columnsreorder” property to true and included jqxgrid.columnsreorder.js in the sample, too. I also changed the editmode to “doubleclick”.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

    Columns reorder and cell editing #16699

    alexz
    Member

    Ok, thanks, I just thought you made the changes to online sample.

    Now I’ve downloaded the sample and make the changes you mention in your post. It has the same problem. The test sequence goes like this:

    Click (or doubleclick) any text cell
    Cells editor opens
    Observe that the cells value is entirely selected
    If now you click on the beginning or anywhere in the middle of the word nothing happens
    If you use keyboard right left arrows, cursor moves to the desired position

    I’ve noticed that your sample uses the same jqx version 2.7 that I use.

    Hope this helps, ask me if you still unable to reproduce.

    All the best,
    Alex

    Columns reorder and cell editing #16702

    Peter Stoev
    Keymaster

    Hi Alex,

    With the latest information, I confirm the focus selection issue with FF when columnsreorder is true. It works fine with Chrome, IE, Safari and Opera.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

    Columns reorder and cell editing #16704

    alexz
    Member

    Thanks Peter, sorry I was not precise enough, now I tried more with IE and it works, but not in FF as you said.

    All the best,
    Alex

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

You must be logged in to reply to this topic.