Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Bug in filter in listGrid when a initialCriteria exist. 11.0p 2016-08-13 GP

    Sorry about my english.

    When in listgrid is defined an initialCriteria hidden from the list (the field is not in the grid) and a current selection is cleared the list is never refresehed.

    I put some images that explain the problem.

    In this image i show the breakpoint and the current value of oldCriteria in the watch area, it contain 2 values one for insumo_descripcion and one for insumo_tipo (the last one is the initialCriteria). THIS IS CORRECT.
    Also in the grid image the filter for descripcion is already empty, but in the list are the results of the previous filter insumo_descripcion = 'ccc'

    Click image for larger version

Name:	fig1.jpeg
Views:	78
Size:	340.4 KB
ID:	239761

    After execute the line in the breakpoint we can see that the value of oldCriteria now is the same value of allRowsCriteria , but thats wrong, because after that in the comparision between .newCriteria and oldCriteria always will be equal and because of that nothing happens.

    The problem is here.

    // When filtering locally previous criteria could be in this.allRowsCriteria instead of this.criteria
    if (isFilteringLocally) {

    --> Here this.allRowsCriteria never will be empty because the initialCriteria
    if (this.allRowsCriteria && Object.keys(this.allRowsCriteria).length > 0) {
    oldCriteria = isc.DS.combineCriteria(this.implicitCriteria, this.allRowsCriteria) --> loose the real oldCriteria
    }
    }

    after the this comparision
    if (this.compareCriteria(newCriteria, oldCriteria) != 0) {
    return false;
    }
    return null;

    always will return null.

    See this image.
    Click image for larger version

Name:	fig3.jpeg
Views:	54
Size:	341.2 KB
ID:	239763

    This only happens when initialCriteria or implicitCriteria is used otherwise work ok.
    implicitCriteria: {insumo_tipo: 'PR'} or using initialCriteria: {insumo_tipo: 'PR'} same results. I compare the 10x code with the last one i see that this code doesnt exist before.

    Click image for larger version

Name:	fig2.jpeg
Views:	69
Size:	479.6 KB
ID:	239762

    Please your comments.

    #2
    Yes, we're aware of a breaking change in the implicitCriteria/initialCriteria subsystem, and it will be fixed shortly.

    You didn't mention your SmartClient version...

    Comment


      #3
      in the title 11.0p 2016-08-13 GPL

      Comment


        #4
        Ah, we see you noted the version in the thread title. We'll update here when the fix is in place.

        Comment


          #5
          This has been fixed for builds dated Auguest 23 and later.

          Comment

          Working...
          X