diff options
author | xue <> | 2007-07-27 19:37:47 +0000 |
---|---|---|
committer | xue <> | 2007-07-27 19:37:47 +0000 |
commit | 5971cea3c452efc18206aa36ef4914c7e49f87e0 (patch) | |
tree | 0355ce9737163c2eb2563bcbd5aa8de14b4578ec | |
parent | 162d442316c8a9e6c161b589f04332691e57c7f7 (diff) |
Validators will not validate disabled controls
-rw-r--r-- | HISTORY | 3 | ||||
-rw-r--r-- | framework/Web/Javascripts/source/prado/validator/validation3.js | 4 | ||||
-rw-r--r-- | framework/Web/UI/WebControls/TBaseValidator.php | 3 |
3 files changed, 6 insertions, 4 deletions
@@ -1,17 +1,18 @@ Version 3.1.1 To be released ============================ BUG: Ticket#592 - TRadioButton with UniqueGroupName always return false to getChecked (Christophe) +BUG: Ticket#648 - Validation: onClick and onBlur events order (Christophe) BUG: Ticket#656 - TDatePicker does not return correct value when in callback mode (Christophe) BUG: Ticket#662 - Ensure TForm to properly encode the ampersand in action URL (Qiang) BUG: Ticket#666 - TActiveRecord::deleteAll() method always requires a criteria or null parameter (Qiang) BUG: Ticket#670 - TDatePicker: Year Issue (Christophe) -BUG: Ticket#648 - Validation: onClick and onBlur events order (Christophe) ENH: Ticket#577 - Added image button support for TPager (Qiang) ENH: Ticket#623 - TMemCache to support multiple servers (Carl) ENH: Ticket#667 - Added TFeedService.ContentType property (Qiang) ENH: Ticket#678 - Improved DateTimeFormatInfo performance (Stever) ENH: Added THead requirement check (Qiang) CHG: GeSHi is replaced with Text_Highlighter (Christophe) +CHG: Validators will not validate disabled controls (Qiang) NEW: Added TTabPanel (Qiang) NEW: Ticket#676 - Added primilary Oracle support (Christophe) NEW: Ticket#680 - Added TCacheHttpSession (Carl, Qiang) diff --git a/framework/Web/Javascripts/source/prado/validator/validation3.js b/framework/Web/Javascripts/source/prado/validator/validation3.js index b9c2e0af..5167f351 100644 --- a/framework/Web/Javascripts/source/prado/validator/validation3.js +++ b/framework/Web/Javascripts/source/prado/validator/validation3.js @@ -625,7 +625,7 @@ Prado.WebUI.TBaseValidator.prototype = this.visible = true;
if(this.message)
{
- if(this.options.Display == "Dynamic")
+ if(this.options.Display == "Dynamic")
{
var msg=this.message;
this.isValid ? setTimeout(function() { msg.hide(); }, 250) : msg.show();
@@ -684,7 +684,7 @@ Prado.WebUI.TBaseValidator.prototype = if(!this.control)
this.control = $(this.options.ControlToValidate);
- if(!this.control)
+ if(!this.control || this.control.disabled)
{
this.isValid = true;
return this.isValid;
diff --git a/framework/Web/UI/WebControls/TBaseValidator.php b/framework/Web/UI/WebControls/TBaseValidator.php index a755d605..96aefe63 100644 --- a/framework/Web/UI/WebControls/TBaseValidator.php +++ b/framework/Web/UI/WebControls/TBaseValidator.php @@ -485,7 +485,8 @@ abstract class TBaseValidator extends TLabel implements IValidator $this->onValidate(); if($this->getVisible(true) && $this->getEnabled(true)) { - if($this->getValidationTarget()) + // if the target is not a disabled web control + if(($target=$this->getValidationTarget())!==null && !($target instanceof TWebControl && !$target->getEnabled(true))) { if($this->evaluateIsValid()) { |