Hybrid View

    Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Sencha User
    Join Date
    Aug 2007
    Posts
    52
    Vote Rating
    0
    jamie.nicholson is on a distinguished road

      0  

    Default Field state valid -> invalid -> valid - doesnt remove qtip invalidClass

    Field state valid -> invalid -> valid - doesnt remove qtip invalidClass


    Ext version tested:
    • Ext 3.3 rev beta

    Adapter used:
    • ext
    • yui
    • jquery
    • prototype


    Browser versions tested against:
    • Chrome
    • FF3 (firebug 1.3.0.10 installed)

    Operating System:
    • Ubuntu Lucid

    Description:
    • When using a field qtip to display a custom message if that field has been invalid but is now valid the invalid class isn't cleared correctly and the custom message looks like an error with exclamation mark and red border line.

    Test Case:

    Apply this configuration to combo, works with other fields too,

    Code:
          Ext.apply(this,{
             allowBlank:false,
             listeners:{
                scope:this,
                valid:function(c){
                   //c.el.dom.qclass = ''; WORKAROUND clear the class manually
                   c.el.set({qtip:c.getRawValue()});
                },
                invalid:function(c){
                   c.el.set({qtip:''});
                },
             },
          });


    Steps to reproduce the problem:
    • ensure field is blank and is invalid state
    • enter in some information making the field valid
    • hover over field to produce qtip

    The result that was expected:
    • qtip would display in normal nice blue box

    The result that occurs instead:
    • qtip displays in validation error box with exclamation mark and red outline

    Possible fix:
    • Code:
      Ext.form.MessageTargets = {
          'qtip' : {
      ...
              clear: function(field){
                  field.el.removeClass(field.invalidClass);
                  field.el.dom.qtip = '';
              }
          },
      
      changed to 
      Ext.form.MessageTargets = {
          'qtip' : {
      ...
              clear: function(field){
                  field.el.removeClass(field.invalidClass);
                  field.el.dom.qtip = '';
                  field.el.dom.qClass ='';
              }
          },

  2. #2
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,246
    Vote Rating
    97
    Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of

      0  

    Default


    I agree with you, but I also have to say that you shouldn't be mixing qtip tips and qtip error messages on the same element.

Similar Threads

  1. Show valid icon if field is valid.
    By emredagli in forum Ext 3.x: Help & Discussion
    Replies: 2
    Last Post: 20 Mar 2011, 11:35 AM
  2. [Sloved][custom Vtype] form is valid if my field is invalid
    By aityahia in forum Ext 2.x: Help & Discussion
    Replies: 2
    Last Post: 17 Mar 2009, 2:15 AM
  3. [SOLVED] too much recursion with event valid/invalid and isvalid function
    By stevanovich in forum Ext 2.x: Help & Discussion
    Replies: 3
    Last Post: 4 Dec 2008, 6:10 AM
  4. [OPEN] Invalid entry in combobox keeps a valid value
    By fecund in forum Ext 1.x: Bugs
    Replies: 2
    Last Post: 20 Apr 2007, 10:39 AM

Thread Participants: 1

Tags for this Thread