summaryrefslogtreecommitdiff
path: root/tests/FunctionalTests/active-controls/protected/pages/CustomValidatorByPass.php
diff options
context:
space:
mode:
authorwei <>2006-12-13 10:07:37 +0000
committerwei <>2006-12-13 10:07:37 +0000
commit3c24d31c69dffb6f65214b6d383d446ac122ff14 (patch)
tree971267876c36893930f84d9663031b154799b10b /tests/FunctionalTests/active-controls/protected/pages/CustomValidatorByPass.php
parent840854be7886236d46d3408de5a084983373b4c7 (diff)
Fixed #488.
Diffstat (limited to 'tests/FunctionalTests/active-controls/protected/pages/CustomValidatorByPass.php')
-rw-r--r--tests/FunctionalTests/active-controls/protected/pages/CustomValidatorByPass.php37
1 files changed, 37 insertions, 0 deletions
diff --git a/tests/FunctionalTests/active-controls/protected/pages/CustomValidatorByPass.php b/tests/FunctionalTests/active-controls/protected/pages/CustomValidatorByPass.php
new file mode 100644
index 00000000..e88f10de
--- /dev/null
+++ b/tests/FunctionalTests/active-controls/protected/pages/CustomValidatorByPass.php
@@ -0,0 +1,37 @@
+<?php
+
+class CustomValidatorByPass extends TPage
+{
+ public function onLoad($param)
+ {
+
+ parent::onLoad($param);
+
+ $Client = $this->validator2->getActiveControl()->getClientSide();
+
+ $Client->setOnLoading('$(\'loginLoader\').show();');
+ $Client->setOnComplete('$(\'loginLoader\').hide();');
+
+ //$Client->setOnValidationError('alert(\'Authentication Failed\');');
+ $Client->setOnValidationSuccess('new Effect.Fade(\'loginBox\')');
+
+ }
+
+ public function validateUser($sender,$param)
+ {
+ $param->IsValid = $this->Password->Text=='test';
+ }
+
+ public function doLogin($sender,$param)
+ {
+
+ /* This isnt even getting called */
+ if($this->Page->IsValid)
+ {
+ // Re-Render the active panel
+ }
+
+ }
+}
+
+?> \ No newline at end of file