[rt-users] Validation of Custom Fields with Custom Code
Jeff Blaine
jblaine at kickflop.net
Fri Nov 22 15:21:35 EST 2013
> I would like to validate a custom fields with my own custom code (RT 4.0.7).
>
> I saw the code in html/Elements/ValidateCustomFields, but there is no
> callback there to implement additional code.
>
> I'm able to write an error message besides my Custom Field (ID 2) in a
> Callback "Modify.html/Default":
>
> $m->notes( ('InvalidField-2') => $my_msg );
>
> But how can I refuse the change of the custom field?
Steffi, I look forward to someone shedding some light on this too.
Right now we are using the Abort() call and requiring the
user to use the browser "back" button. It's very ... 1995.
*I* am not aware of any clean way to do what would be desired
by anyone wanting to do something like this:
Evaluate custom logic at Modify.html submission (and
Update.html!), take no action and redisplay the form
with error message if the logic requirements are not met.
More information about the rt-users
mailing list