Chris,
Yes and No.
The ca_fdResetFields function for the most part will work for us however, there are a couple things that we came across in testing.
1) it states "The fields will revert to their default values and any invalid data warnings will be removed." In our testing, that was mostly accurate but not completely. If the field being reset is a Label field, it actually wipes out the Label Text altogether making the label worthless. Now you might say "Why would you reset a label field?" which sounds like a reasonable question. Well the answer is that we're making a function that both hides and clears in 1 step the array of fields that apply. If the label field is to be hidden, we wanted to put it in the same array as everything else. If we do this, it'll actually break the label's purpose. So either I'd still need a way to determine if the field being evaluated is a label field in order to only apply the hiding code or keep track of that separately and call different functions for labels than I do for everything else.
2) I also noticed that fieldsets have nothing to reset, which makes some sense but similar to the label, if I want to hide that, if I can't inspect it to tell me it's a fieldset object, I'd need to do that separately instead of using a common function.
3) We have not figured out a way to catch that a field was reset by the resetfields function which means we can't build a cascading trigger response as I had illustrated above. This puts a heavier administrative load on the developers to pay attention to all possible cascading scenarios.
Any thoughts on this would be appreciated.