Wijmo Flexgrid edits with dropdown when filters on is behaing weirdly

Posted by: selvakumar.periyasamy on 18 December 2017, 7:28 am EST

    • Post Options:
    • Link

    Posted 18 December 2017, 7:28 am EST

    Hi,

    I have been using wijmo Flexgrid for angular 2.

    I’m experiencing a wierd issue when I try to apply filter and try changing the dropdowns the dropdown is showing a value different than the actual binded value.

    Please find the attached sample code where I can reproduce the issue by following steps

    1.Apply a filter on Department and Select Infrastructure Services

    2.Now in the second row with name “Camey” change the department drop down value to “IT services” and focus out of the cell.

    3.Now as expected “Camey” row is removed from the grid, but I see the selected department “IT Services” on “Camey” is carrying forward to the next row “Andrew”

    This should not happen please find the attached sample.sampleFlexGrid.zip

  • Posted 18 December 2017, 7:40 am EST

    This issue does not exist on a older version of wijmo 20171.300.

    This issue I’m seeing only in wijmo 5.20173.380.

    We need the newer version with this fix as this version is having the date inputs clear fixes.

  • Posted 18 December 2017, 10:58 pm EST

    Hi Selva,

    We are investigating on this. We will update you soon.

    ~Manish

  • Posted 19 December 2017, 3:13 am EST

    Hi Manish,

    Please try to address this issue as soon as possible as we have postponed our release because of this issue, also please let me know is there any work around for this?

    Thanks

    Selvakumar P

  • Posted 19 December 2017, 7:47 pm EST

    Hi SelvaKumar,

    We are observing that you are using ComboBox for updating values for current item. You may use dataMap instead of using ComboBox as cell template and update value of item using cellEditEnding event.

    Please refer to the updated sample.

    ~Manish

    FlexGrid_dataMap_updateValues.zip

  • Posted 20 December 2017, 5:31 am EST

    Hi Manish,

    We will not be able to use datamap’s as we want the auto complete feature to show the list of items starting with the typed characters, it will be great if we can get the issue fixed in the Flexgrid or any other work around using autocomplete.

    Thanks

    Selvakumar P

  • Posted 20 December 2017, 10:57 pm EST

    Hi SelvaKumar,

    This seems a bug, hence this issue has been forwarded to the concerned team for further investigation with id 301917.

    We will let you know as we get any update on this.

    ~Manish

  • Posted 21 December 2017, 8:43 am EST

    Hi Manish,

    Thanks! for forwarding this issue to the team, it would be great, if you can give us a estimate on when this will be addressed .

  • Posted 21 December 2017, 8:15 pm EST

    HI Selva,

    We are sorry, we can not provide any ETA on this. We have raised priority for this issue and let you know as we get any update.

    ~Manish

  • Posted 25 December 2017, 4:32 pm EST

    Hi Selva Kumar,

    It is by design to improve FlexGrid performance with cell templates. The build 5.20173.380 reuses existing cells when re-draw its content while 5.20171.300 refresh full FlexGrid and recreate.

    The way to fix this in the sample is very easy (yet required lots of research to the team :blush:):

    1. Make binding two-way:
    [(selectedValue)]="cell.item.dept"
    
    1. Make a corresponding change in the lostFocus handler, actually it’s about the check:
    if( cellItem[property] != selectedVal.id )  {
    

    , it should be:

    if( cellItem[property] == selectedVal.id )  {
    

    Please note that instead of beginUpdate/editItem you can just call ```

    grid.collectionView.refresh()

    
    Please refer to the attached sample that implements the same. 
    
    ~Manish
    
    [zip filename="sampleFlexGrid.zip"]public\uploads\2407bfb53a11903362fb8551bc9c94311514266366409.zip[/zip]
  • Posted 27 December 2017, 6:36 am EST

    Hi Manish,

    Thanks for the update and fix, I tried your fix it works really well but I have a problem when I change a value in the drop down the data collection gets updated, but the collection.itemsEdited length is always 0 hence I’m not able to find which data has changed. Is there any solution available for this.

    Thanks

    Selvakumar P

  • Posted 28 December 2017, 7:32 pm EST

    Hi SelvaKumar,

    You may use editItem method used in original example from you with updated condition in previous reply.

    The collectionView.refresh is used to make code smaller only.

    Here is the updated sample.

    ~Manish

    sampleFlexGrid_fixed.zip

  • Posted 2 January 2018, 2:07 am EST

    Hi Manish,

    Thanks! for the fix it works good now.

    Wishing you a Happy New Year!

    -Selvakumar P

  • Posted 2 January 2018, 3:03 pm EST

    Thanks for notifying this and Wishing you a very Happy New Year SelvaKumar :blush:!

  • Posted 3 January 2018, 4:41 am EST

    Hi Manish,

    I want to reopen this issue.

    I was able to reproduce this issue following the steps below.

    Apply filter on Dept Infrastructure Services.

    On the First Record( Adam ), Now Type the word “con” on the autocomplete and focus out of the cell

    Now whatever the value that i typed on Adam get carried to Camey.

    This issue has been categorized as show stopper and our release has been postponed so please let me know if there is any other work around or whether it needs to be fixed in the wijmo build.

    Please find the attached sample.

    Sample.zip

    Thanks

    Selvakumar P

  • Posted 3 January 2018, 6:23 pm EST

    Hi Selva,

    The reason is same as mentioned in previous reply for this issue too. We need to modify control selectedIndex if control selectedItem is null.

    Please find the attached sample for the same.

    Changes are following:

    lostFocus event in app.component.html 
    (lostFocus)="onTeamMemberRoleChange([b]brpsDp[/b],cell.item,brpsDp.selectedItem, {property:'dept', displayNameProperty: 'deptName'})"
    

    Two changes in lostFocus event handler:

    if(selectedVal == null) {

    selectedVal = { id: null, name : AppComponent.BLANK_VAL };

    // if selected Value is null, reset Control value to null

    sender.text=“”;

    sender.selectedIndex=0;

    }

    cellItem[propObj.displayNameProperty] = selectedVal.name===AppComponent.BLANK_VAL ? null:selectedVal.name;

    ~Manish

    FlexGrid_AutoComplete_DataMap_Filter_fix.zip

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels