Re: Congratulations!! FormBuilder 0.10.0
| From: | Alejandro Vartabedian | Date: | Mon, 13 Sep 2004 23:11:47 +0000 |
| Subject: | Re: Congratulations!! FormBuilder 0.10.0 | ||
| References: | 1 2 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-14522@lists.php.net to get a copy of this message | ||
without the attach it can't be understood.
it seems the attach was skipped by the server.
i am not annoyed by a mention or the like, my point is that a _private_ mail reply to my patch, saying thanks, could be apreciated.
it's all right Justin, only a little lack of gentility.
regards.
this was attached in the original mail to Markus.
--- FormBuilder.php 2004-05-15 15:31:16.000000000 -0300
+++ /usr/share/php/DB/DataObject/FormBuilder.php 2004-06-19 01:43:57.000000000 -0300
@@ -524,7 +524,10 @@
if ($elValidator !== false) {
$rules[$key][] = array('validator' => $elValidator, 'rule' => $elValidRule);
} // End if
-
+
+ // to freeze non editable fields by Alejandro Vartabedian
+ if (in_array($key, $elements_to_freeze)) { $element->freeze(); }
+
} // End else
} // End else
@@ -538,11 +541,17 @@
//VALIDATION RULES
if (isset($rules[$key])) {
+ // validate the form data in the client by javascript
+ // by Alejandro Vartabedian
+ if (isset($_DB_DATAOBJECT_FORMBUILDER['CONFIG']['clientRules']) &&
+ $_DB_DATAOBJECT_FORMBUILDER['CONFIG']['clientRules'] == '1') {
+ $rule_side = 'client';
+ }
while(list($n, $rule) = each($rules[$key])) {
if ($rule['rule'] === false) {
- $form->addRule($key, $this->rule_violation_message, $rule['validator']);
+ $form->addRule($key, '('.$this->getFieldLabel($key).')'.$this->rule_violation_message, $rule['validator'], '', $rule_side);
} else {
- $form->addRule($key, $this->rule_violation_message, $rule['validator'], $rule['rule']);
+ $form->addRule($key, '('.$this->getFieldLabel($key).')'.$this->rule_violation_message, $rule['validator'], $rule['rule'], $rule_side);
} // End if
} // End while
} // End if
@@ -1325,4 +1334,4 @@
}} -?> \ No newline at end of file +?> Justin Patrin escribió:
On Mon, 13 Sep 2004 15:48:45 -0300, Alejandro Vartabedian <avartabedian@webservices.com.uy> wrote:Hello *Markuss*, i feel happy about the FormBuilder upgrade saying: *- Added missing code to freeze fields not in userEditableFields (if it exists)* Do you remember me? Do you remember this mail? ####################################################################### -------- Mensaje Original -------- Asunto: minor bugfix and one functionality Fecha: Sat, 19 Jun 2004 05:19:32 -0000 De: Alejandro Vartabedian <avartabedian@webservices.com.uy> Para: Markus Wolff <mw21st@php.net> Markus,I'm not understanding this e-mail. Are you happy about the upgrade or are you annoyed that your code didn't get in? First thing, I don't see a feature request in the bug system for this. It's easy for such things to get lost unless it's in the bug system. Please post a feature request for what you want. It will likely get into the next release of FormBuilder. I'm not sure what you're trying to say about Markus' ego. He's been very nice to me, even giving me lead status on FormBuilder and allowing me to make many changes and help set up the newest release. Of course, I've submitted lots of patches, but I know that he tries to handle everyone's problems. I also try to, although I (and most other PEAR developers) sometimes don't have time to implement things very quickly.i started testing Alan Knowles excellent DB_DataObject (and otherssimilar projects, but i prefer DO's features) yesterday, so i'm new in those classes, specially HTML_QuickForm, and didn't resist to test DB_DataObject_FormBuilder.it's very tunned with some things i was thinking to implement withPEAR's posibility's, it's really util, so started to use it and found a minor bugfix in the 'elements_to_freeze' application, and added a little feature to the QF rules controls.that's the reason why i'm mailing you.i hope it helps. good luck.pd: i think i will be doing more things with those classes, so if you like i can post more changes. an example could be the DB_DataObjects pager. -------------------------------------------------------------- Creado con ws-GroupWare webservices - http://www.webservices.com.uy ####################################################################### you never reply me saying only thanks. it looks your 'ego' capacity is bigger than your gratefulness one. i am not suffered but it's a pitty.... perhaps i would have to post that mail to the list, but it shows me how you deal with those things. the QF client side validation rules code i send you not appear in the changelog or in the rules related code, it may be a useless feature. good luck Markuss. to the list: i'll no longer use FormBuilder anymore but have some code to contribute to the list, and to Markuss ego too. (why not?) is anyone in the list interested in: _ an example of building editable DataGrids using FormBuilder? _ using it with an Smarty FormBuilder-oriented generic form template? _ how to enable QF client-side validation rules to FormBuilder? if so let me know and i'll post it to the list. regards. Alejandro Vartabedian.