Announcement

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

    Bug in filterbuilder

    Hi,

    I've found recent (after upgrading to smartgwt 1.1) bug in filterbuilder.

    If I have field specified in datasource like this:
    Code:
       DataSourceTextField serie = new DataSourceTextField("zaw_serie", "Seria");
          serie.setRequired(true);
          serie.setCanEdit(false);
    Filter builder looks this way (see attachment)

    if it's
    Code:
       DataSourceTextField serie = new DataSourceTextField("zaw_serie", "Seria");
          serie.setRequired(true);
          serie.setCanEdit(true);
    filter builder works ok.
    Attached Files

    #2
    Hi, can anyone confirm this bug? Or am I doing something wrong?

    Comment


      #3
      Hi, I really need answer why it's not working for me.

      Thank you for any help.

      Comment


        #4
        Did you tested it with last SVN revision?

        For me it's working. Tested with last revision.

        Comment


          #5
          I've just downloaded revision 584 and it's still not working.

          Strange is that when I use .setCanEdit(true) it's not working but when I use setCanEdit(false) is working.

          I'll try to post here full eclipse project with this sample.

          Comment


            #6
            Just tried release-1.0b2 version of smartclient.jar and it's working there, in 1.1 and current revision is not :(
            Attached Files
            Last edited by Przemeq; 13 Jun 2009, 11:18.

            Comment


              #7
              The FilterBuilder doesn't edit, it filters. Whether a field can be filtered is controlled by DataSourceField.setCanFilter().

              Comment


                #8
                Hi, thank's for your answer, but it doesn't solve my problem.

                I've tried to set .setCanFilter(true), but such field (with setCanEdit(false)) is still broken in filterbuilder

                Please try my example. It shows clearly where is the problem.

                Comment


                  #9
                  Hi!

                  My problem is very similar: I have set .setRequired(false); on some fields in the datasource, but they are nevertheless shown in the FilterBuilder. To be more precise the name of the field is not shown the selection box, but there is an empty entry that can be selected. I use Revision 591 (newest).

                  Comment


                    #10
                    Isomorphic, can u confirm that this is bug, please?
                    And ofcourse if there is any timeframe for fix?

                    Thank you.

                    Comment


                      #11
                      @przemeq your example sets canEdit. Set canFilter.

                      @devask "required" affects whether the user can leave a field blank when saving a record. It is unrelated to the FilterBuilder.

                      Comment


                        #12
                        Hi!

                        Sorry I copied the wrong method. Of course I meant that I have set setCanFilter(false) on some fields but nevertheless they are shown as blank rows in the combobox of the filterbuilder (and can even be selected).

                        Thx!

                        Comment


                          #13
                          @Isomorfic-> I want to disable (in datasource) user ability to EDIT this field so I'm using setCanEdit(false) but i want user to by able to Filter and this way user is not (when setCanEdit(false) was used)

                          If i use
                          .setCanEdit(false);
                          .setCanFilter(true);

                          it still does not work (please see screenshot above)

                          Comment


                            #14
                            Any updates on this issues?

                            Comment


                              #15
                              I've commented .setCanEdit(false) in data source and disabled manually each field in dynamic form, but this is only workaround and looks very ugly :(

                              Comment

                              Working...
                              X