[html-formfu] Constraint on a joined field (CompoundJoin)

Moritz Onken onken at houseofdesign.de
Mon Aug 18 13:40:07 BST 2008


>>
>
> I did reply, but here it is again, in case it didn't get through to  
> the list:.
> (short answer is: there is a couple of ways to work around it, but it
> can't be fixed)
> ...
>
> Filters are run before Constraints.
> So by the time the 'enddate' Required constraint tries to run, the
> CompoundJoin filter has already munged the hashref into a string.
>
> I think the only way around this, is to instead attach a constraint to
> the Multi block, which checks the filtered value is logically correct.
>
> Alternatively, I suppose you could create a new Required constraint,
> which instead checks the value was present in the initial input,
> rather than the value that's fed to the constraint.
> Something like this should work:
>

Yes I read that reply. But it was referring to the other test where
a compound join block is inside of a repeatable block:

xt/repeatable_compoundjoin.t

moritz




More information about the HTML-FormFu mailing list