Re: farcry 6.2.* formtool UUID property ftvalidation="required" still validates if no UUID is selected
Matthew Attanasio <matthew-s5+8xnkFq1N97EbBUNGEsFaTQe2KTcn/@public.gmane.org>
| Newsgroups | gmane.comp.cms.farcry.devel |
|---|---|
| Message-ID | <[email protected]> |
Very happy to do so Geoff
Before I do however I just want to know a bit more about the current
situation with validation in farcry.
It seems through debugging this whole ordeal that formtools uses the jQuery
validate plugin to validate the form but no longer also uses coldfusion
server side validation. Is this intentional or also a bug?
Also I resolved the problem by creating a custom formtool type that is
basically the exact same as the uuid type however it adds
#arguments.stMetadata.ftValidation# as a class name to the hidden input
field used for the UUID.
Also added this bit of nifty javascript that updates the jquery validation
setting to allow hidden input fields to be included in the validation
process.
$j(".uniForm").data("validator").settings.ignore = '';
I guess this is a hack but it wouldn't require to much more work to
implement something a lot more elegant.
On Monday, May 27, 2013 2:59:35 PM UTC+9:30, Geoff Bowers wrote:
>
> Please raise an issue on http://farcry.jira.com and let me know the
> number. I'll escalate it to the "Shiny" build.
>
> -- geoff
> http://www.daemon.com.au/
> twitter. @modius
>
>
> On 27 May 2013 14:09, Matthew Attanasio <mat...-s5+8xnkFq1N97EbBUNGEsFaTQe2KTcn/@public.gmane.org<javascript:>
> > wrote:
>
>> After some investigation, it looks like the UUID.cfc formtool does have a
>> validation method and its seems to correctly return a failed response when
>> ftValidation='required' however for some reason the form still passes as
>> valid.
>>
>> Regards Matthew
>>
>>
>> On Monday, May 20, 2013 5:11:19 PM UTC+9:30, Matthew Attanasio wrote:
>>>
>>> Hello Blair and Geoff
>>>
>>> Think I may have have caused a bit of confusion, I meant a custom
>>> content type.
>>>
>>> Yeah that's what I thought as well for a UUID, looking at the docs there
>>> is no specific validation option for a required UUID so I assumed that
>>> simply adding ftValidation="required" would be enough to enable simple
>>> validation on that property type. Guess this isnt the case at the moment....
>>>
>>>
>>> On Monday, May 20, 2013 4:36:33 PM UTC+9:30, Geoff Bowers wrote:
>>>>
>>>> Do you mean custom formtool or custom content type?
>>>>
>>>> fttype="UUID" should already have a required validation option. If it
>>>> doesn't we should address that as a bug on the UUID formtool.
>>>>
>>>> GB
>>>>
>>>>
>>>> On 20 May 2013 16:25, Matthew Attanasio <mat...-s5+8xnkFq1N97EbBUNGEsFaTQe2KTcn/@public.gmane.org>wrote:
>>>>
>>>>> Hello All.
>>>>>
>>>>> I have built a custom formtool that has a property assigned as UUID
>>>>> and would like to add validation to the property so that the user has to
>>>>> pick an object before they can save it in farcry. I have added the
>>>>> required="true" and ftValidation="required" to the property but I am able
>>>>> to create an object and save it with out having to add an uuid to that
>>>>> property.
>>>>>
>>>>> Here is an example of what I have now, I have changed the name, ftJoin
>>>>> and ftLabel fields
>>>>>
>>>>> <cfproperty name="testProperty" type="uuid" ftSeq="2" ftFieldset="General
>>>>> Details" ftWizardStep="General Details" ftLabel="Test Label" required=
>>>>> "true" ftJoin="testObject" ftHint="" ftvalidation="required">
>>>>>
>>>>> Is this even possible in farcry at the moment to do?
>>>>>
>>>>> Regards Matthew.
>>>>>
>>>>> --
>>>>> You received this message cos you are subscribed to "farcry-dev"
>>>>> Google group.
>>>>> To post, email: farcr...-/[email protected]
>>>>> To unsubscribe, email: farcry-dev+...@googlegroups.**com
>>>>> For more options: http://groups.google.com/**group/farcry-dev<http://groups.google.com/group/farcry-dev>
>>>>> ------------------------------**--
>>>>> Follow us on Twitter: http://twitter.com/farcry
>>>>> ---
>>>>> You received this message because you are subscribed to the Google
>>>>> Groups "farcry-dev" group.
>>>>> To unsubscribe from this group and stop receiving emails from it, send
>>>>> an email to farcry-dev+...@googlegroups.**com.
>>>>> For more options, visit https://groups.google.com/**groups/opt_out<https://groups.google.com/groups/opt_out>
>>>>> .
>>>>>
>>>>>
>>>>>
>>>>
>>>> --
>> You received this message cos you are subscribed to "farcry-dev" Google
>> group.
>> To post, email: farcr...-/[email protected] <javascript:>
>> To unsubscribe, email: farcry-dev+...-/[email protected] <javascript:>
>> For more options: http://groups.google.com/group/farcry-dev
>> --------------------------------
>> Follow us on Twitter: http://twitter.com/farcry
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "farcry-dev" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to farcry-dev+...-/[email protected] <javascript:>.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>>
>>
>
>
--
You received this message cos you are subscribed to "farcry-dev" Google group.
To post, email: farcry-dev-/[email protected]
To unsubscribe, email: farcry-dev+unsubscribe-/[email protected]
For more options: http://groups.google.com/group/farcry-dev
--------------------------------
Follow us on Twitter: http://twitter.com/farcry
---
You received this message because you are subscribed to the Google Groups "farcry-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to farcry-dev+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected]
For more options, visit https://groups.google.com/groups/opt_out.