I am looking to add some customizations to the Orm package for its observer/validation.php class.
I tried the add_classes override in my config.php like when overriding core classes but it appears to be ignored or already loaded by time it gets there. For time being I have just edited the Orm bootstrap.php to point to my custom validation class.
Is there an out of box and clean way to do this? Or just via creating and clone of the Orm package as "MyOrm" or equivalent?
Dont know the full extent of the customizations yet, just started jumping into first fuel project this week. First thing I am doing is adding new field types and processing.., for example first one is a "calendar" field that when passing the model to fieldset and build() is called it will render a js date picker popup.
Bigger effort to look at down the road after getting my initial project done, but would like to rewrite or see new way fields are handled in more pluggable manner. Right now there are too many touch points to add a new type.
I guess for now I will keep using my override files for where I need to tap in and change the behavior, as well as spend some spare cycles looking at how a new way of handling fields might be best implemented
Seems like a complicated way of doing things. i just add 'datepicker' to the class value of the form array, and use some jQuery magic to add the datepicker to all fields with this class defined.
Ideally, from a "separation of concerns" point of view, you want like to avoid code that generates HTML.
I am using custom styled date/calendar fields that are leveraging some bootstrap css extensions.., so the markup isnt just standard field with custom class attribute.