You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by leo leonid <te...@leonid.de> on 2004/04/02 16:54:27 UTC
Re: cvs commit: cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript Form.js
I can't confirm that <wd:submit validate="false"/> functionality is
restored.
It's OK in Revision 1.2 though. Or did the syntax change?
/Leo
On Mar 31, 2004, at 11:06 PM, vgritsenko@apache.org wrote:
> vgritsenko 2004/03/31 13:06:59
>
> Modified:
> src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript
> Form.js
> Log:
> Regression: restoring <wd:submit validate="false"/> functionality.
>
> Revision Changes Path
> 1.5 +2 -2
> cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/
> javascript/Form.js
>
> Index: Form.js
> ===================================================================
> RCS file:
> /home/cvs/cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/
> flow/javascript/Form.js,v
> retrieving revision 1.4
> retrieving revision 1.5
> diff -u -r1.4 -r1.5
> --- Form.js 18 Mar 2004 21:04:40 -0000 1.4
> +++ Form.js 31 Mar 2004 21:06:59 -0000 1.5
> @@ -118,8 +118,8 @@
> this.isValid = this.form.isValid();
> } else {
> this.isValid = this.form.isValid() &
> this.validator(this.form, bizData);
> + finished = this.isValid;
> }
> - finished = this.isValid;
> }
>
> // FIXME: Theoretically, we should clone the form widget
> (this.form) to ensure it keeps its
>
>
>
>
Re: cvs commit: cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript
Form.js
Posted by Joerg Heinicke <jo...@gmx.de>.
On 06.04.2004 14:13, Vadim Gritsenko wrote:
>>>>>> The problem is, that you only cancel standard validation. But you
>>>>>> get stuck if you have a additional custom validation step.
>
>>>>> If so, this feature is more or less deprecated though there was no
>>>>> official decision made about this until now, but Sylvain mentioned
>>>>> it as he added the possibility of adding validators to every
>>>>> widget. The flow script validator was more or less a hack,
>
> What's decision - do we remove this (flow-only custom form validation)
> feature?
+1 Don't recommend the users to use such a "hack" when there is a better
way. Of course we can not prevent that they use it when they modify
Form.js or use their own script file.
And as Leo pointed out, our samples should reflect the changes for the
custom validators too.
Joerg
Re: cvs commit: cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript
Form.js
Posted by Vadim Gritsenko <va...@reverycodes.com>.
leo leonid wrote:
>
> On Apr 3, 2004, at 9:35 PM, Sylvain Wallez wrote:
>
>> leo leonid wrote:
>>
>>>
>>> On Apr 3, 2004, at 5:55 PM, Joerg Heinicke wrote:
>>>
>>>> On 02.04.2004 19:42, leo leonid wrote:
>>>
...
>>>>> The problem is, that you only cancel standard validation. But you
>>>>> get stuck if you have a additional custom validation step.
>>>>
...
>>>> If so, this feature is more or less deprecated though there was no
>>>> official decision made about this until now, but Sylvain mentioned
>>>> it as he added the possibility of adding validators to every
>>>> widget. The flow script validator was more or less a hack,
>>>
What's decision - do we remove this (flow-only custom form validation)
feature?
Vadim
Re: cvs commit: cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript Form.js
Posted by leo leonid <te...@leonid.de>.
On Apr 3, 2004, at 9:35 PM, Sylvain Wallez wrote:
> leo leonid wrote:
>
>>
>> On Apr 3, 2004, at 5:55 PM, Joerg Heinicke wrote:
>>
>>> On 02.04.2004 19:42, leo leonid wrote:
>>>
>>>>>>> I can't confirm that <wd:submit validate="false"/> functionality
>>>>>>> is restored.
>>>>>>> It's OK in Revision 1.2 though. Or did the syntax change?
>>>>>>
>>>>>>
>>>>>> Try CForms "aggregate" sample, "switch" button - it was broke
>>>>>> before, now works.
>>>>>>
>>>>> It still doesn't work in general.
>>>>
>>>> The problem is, that you only cancel standard validation. But you
>>>> get stuck if you have a additional custom validation step.
>>>
>>>
>>> This means you have set a validator on the flow script level, i.e.
>>> this.validator = aFunction; ??
>>>
>> yep, inspired by Bruno's custom validation sample...
>>
>>> If so, this feature is more or less deprecated though there was no
>>> official decision made about this until now, but Sylvain mentioned
>>> it as he added the possibility of adding validators to every widget.
>>> The flow script validator was more or less a hack,
>>
>> Hey, I'm happy with it, it was a feature, *now* we have a bug.
>>
>>> now you have something official.
>>
>> If it is as useful and funny, OK!
>>
>> I mean, if you say its a wontfix I immediately stop patching my
>> Form.js, willing to follow your official way. Could you give me a
>> pointer to this. (Or a replacement of the then deprecated custom
>> validation sample would be great ;)
>
>
> I don't have much time to follow up on this, but yes, the flow-level
> validator *was* useful when we did not have
> validators-on-every-widget. But now I am +1 to remove that feature
> from flow.js since we can directly add it to the Form object.
>
> Sylvain
>
OK, I'm a switcher.
OT: Stepping through the source of v2/ScriptableWidget - though without
understanding that much - by now I can say: it was worth it! a visual
treasure, that is not code formatting anymore, but fine arts. (e.g.
lines 661-673)
/leo
Re: cvs commit: cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript
Form.js
Posted by Sylvain Wallez <sy...@apache.org>.
leo leonid wrote:
>
> On Apr 3, 2004, at 5:55 PM, Joerg Heinicke wrote:
>
>> On 02.04.2004 19:42, leo leonid wrote:
>>
>>>>>> I can't confirm that <wd:submit validate="false"/> functionality
>>>>>> is restored.
>>>>>> It's OK in Revision 1.2 though. Or did the syntax change?
>>>>>
>>>>>
>>>>> Try CForms "aggregate" sample, "switch" button - it was broke
>>>>> before, now works.
>>>>>
>>>> It still doesn't work in general.
>>>
>>> The problem is, that you only cancel standard validation. But you
>>> get stuck if you have a additional custom validation step.
>>
>>
>> This means you have set a validator on the flow script level, i.e.
>> this.validator = aFunction; ??
>>
> yep, inspired by Bruno's custom validation sample...
>
>> If so, this feature is more or less deprecated though there was no
>> official decision made about this until now, but Sylvain mentioned it
>> as he added the possibility of adding validators to every widget. The
>> flow script validator was more or less a hack,
>
> Hey, I'm happy with it, it was a feature, *now* we have a bug.
>
>> now you have something official.
>
> If it is as useful and funny, OK!
>
> I mean, if you say its a wontfix I immediately stop patching my
> Form.js, willing to follow your official way. Could you give me a
> pointer to this. (Or a replacement of the then deprecated custom
> validation sample would be great ;)
I don't have much time to follow up on this, but yes, the flow-level
validator *was* useful when we did not have validators-on-every-widget.
But now I am +1 to remove that feature from flow.js since we can
directly add it to the Form object.
Sylvain
--
Sylvain Wallez Anyware Technologies
http://www.apache.org/~sylvain http://www.anyware-tech.com
{ XML, Java, Cocoon, OpenSource }*{ Training, Consulting, Projects }
Re: cvs commit: cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript Form.js
Posted by leo leonid <te...@leonid.de>.
On Apr 3, 2004, at 5:55 PM, Joerg Heinicke wrote:
> On 02.04.2004 19:42, leo leonid wrote:
>
>>>>> I can't confirm that <wd:submit validate="false"/> functionality
>>>>> is restored.
>>>>> It's OK in Revision 1.2 though. Or did the syntax change?
>>>>
>>>> Try CForms "aggregate" sample, "switch" button - it was broke
>>>> before, now works.
>>>>
>>> It still doesn't work in general.
>> The problem is, that you only cancel standard validation. But you get
>> stuck if you have a additional custom validation step.
>
> This means you have set a validator on the flow script level, i.e.
> this.validator = aFunction; ??
>
yep, inspired by Bruno's custom validation sample...
> If so, this feature is more or less deprecated though there was no
> official decision made about this until now, but Sylvain mentioned it
> as he added the possibility of adding validators to every widget. The
> flow script validator was more or less a hack,
Hey, I'm happy with it, it was a feature, *now* we have a bug.
> now you have something official.
If it is as useful and funny, OK!
I mean, if you say its a wontfix I immediately stop patching my
Form.js, willing to follow your official way. Could you give me a
pointer to this. (Or a replacement of the then deprecated custom
validation sample would be great ;)
/leo
> Joerg
>
Re: cvs commit: cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript
Form.js
Posted by Joerg Heinicke <jo...@gmx.de>.
On 02.04.2004 19:42, leo leonid wrote:
>>>> I can't confirm that <wd:submit validate="false"/> functionality is
>>>> restored.
>>>> It's OK in Revision 1.2 though. Or did the syntax change?
>>>
>>> Try CForms "aggregate" sample, "switch" button - it was broke before,
>>> now works.
>>>
>> It still doesn't work in general.
>
> The problem is, that you only cancel standard validation. But you get
> stuck if you have a additional custom validation step.
This means you have set a validator on the flow script level, i.e.
this.validator = aFunction; ??
If so, this feature is more or less deprecated though there was no
official decision made about this until now, but Sylvain mentioned it as
he added the possibility of adding validators to every widget. The flow
script validator was more or less a hack, now you have something official.
Joerg
Re: cvs commit: cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript Form.js
Posted by leo leonid <te...@leonid.de>.
On Apr 2, 2004, at 7:23 PM, leo leonid wrote:
>
> On Apr 2, 2004, at 5:17 PM, Vadim Gritsenko wrote:
>
>> leo leonid wrote:
>>
>>> I can't confirm that <wd:submit validate="false"/> functionality is
>>> restored.
>>> It's OK in Revision 1.2 though. Or did the syntax change?
>>
>>
>> Try CForms "aggregate" sample, "switch" button - it was broke before,
>> now works.
>>
>
<ignore>
> True, but only because you specially handle it in your flowscript
>
> if (form.submitId == "switch") {
> ...
>
> }
>
</ignore>
> It still doesn't work in general.
The problem is, that you only cancel standard validation. But you get
stuck if you have a additional custom validation step.
/Leo
>
> /Leo
>
>> Vadim
>>
>>
>>> /Leo
>>>
>>>
>>>
>>> On Mar 31, 2004, at 11:06 PM, vgritsenko@apache.org wrote:
>>>
>>>> vgritsenko 2004/03/31 13:06:59
>>>>
>>>> Modified:
>>>> src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript
>>>> Form.js
>>>> Log:
>>>> Regression: restoring <wd:submit validate="false"/> functionality.
>>>
>>
>>
>>
>
>
Re: cvs commit: cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript Form.js
Posted by leo leonid <te...@leonid.de>.
On Apr 2, 2004, at 5:17 PM, Vadim Gritsenko wrote:
> leo leonid wrote:
>
>> I can't confirm that <wd:submit validate="false"/> functionality is
>> restored.
>> It's OK in Revision 1.2 though. Or did the syntax change?
>
>
> Try CForms "aggregate" sample, "switch" button - it was broke before,
> now works.
>
True, but only because you specially handle it in your flowscript
if (form.submitId == "switch") {
...
}
It still doesn't work in general.
/Leo
> Vadim
>
>
>> /Leo
>>
>>
>>
>> On Mar 31, 2004, at 11:06 PM, vgritsenko@apache.org wrote:
>>
>>> vgritsenko 2004/03/31 13:06:59
>>>
>>> Modified:
>>> src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript
>>> Form.js
>>> Log:
>>> Regression: restoring <wd:submit validate="false"/> functionality.
>>
>
>
>
Re: cvs commit: cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript
Form.js
Posted by Vadim Gritsenko <va...@reverycodes.com>.
leo leonid wrote:
> I can't confirm that <wd:submit validate="false"/> functionality is
> restored.
> It's OK in Revision 1.2 though. Or did the syntax change?
Try CForms "aggregate" sample, "switch" button - it was broke before,
now works.
Vadim
> /Leo
>
>
>
> On Mar 31, 2004, at 11:06 PM, vgritsenko@apache.org wrote:
>
>> vgritsenko 2004/03/31 13:06:59
>>
>> Modified:
>> src/blocks/forms/java/org/apache/cocoon/forms/flow/javascript
>> Form.js
>> Log:
>> Regression: restoring <wd:submit validate="false"/> functionality.
>