[QFC] applyDefaults and its behaviour ?
| From: | Laurent Laville | Date: | Fri, 20 Jan 2006 13:59:46 +0000 |
| Subject: | [QFC] applyDefaults and its behaviour ? | ||
| Groups: | php.pear.dev | ||
| Request: | Send a blank email to pear-dev+get-41009@lists.php.net to get a copy of this message | ||
Hello Alexey
Working on a GUI frontend for PEAR_PackageFileManager2 with HTML_QuickForm_Controller (1.0.5), i've realized that i can't implement a real RESET function with QFC->applyDefaults() method.
I'm expected to have this behavior:
Fill page N of QFC, jump to another page, and then back to page N.
Click on RESET button (that will call a QFC Action running QFC->applyDefaults()) and retrieve all defaults values of page N.
I've noticed that it's not the case.
RESET button work fine when i've not yet jump to another page (data are not yet submitted).
But when i've jump once (data submitted) it no more possible to retrieve defaults values.
I think it's due to code implementation of
element.php,v 1.33 2005/06/24 17:58:29 avb (into QuickForm 3.2.5)
onQuickFormEvent() method
case 'updateValue':
apply constant first, then if not, try to apply submit values, and if not apply defaults values.
This behaviour is good for normal situation but not with a RESET button as i expect to have ?
I hope i'm not wrong, and don't disturb you for nothing: i didn't yet found a thread about this topic on archives !
Laurent