This module serves as a base class for all controller classes in smolder.
As such it defines some behavior with regard to templates,
form validation,
etc and provides some utility methods for accessing this data.

This method will return the Smolder::DB::Developer object that this request is associated with, if it's not a public request. This information is pulled from the $ENV{REMOTE_USER} which is set by mod_auth_tkt.

This method is provided by the TT Plugin plugin. It is used to choose and process the Template Toolkit templates. If no name is provided for the template (as the first argument) then the package name and the run mode will be used to determine which template to use. For instance:

$self->tt_process({ arg1 => 'foo', arg2 => 'bar' });

If this was done in the Smolder::Control::Foo package for the 'list' run mode then it would use the templates/Foo/list.tmpl template. If you want to use a different template then you can explicitly specify it as well:

This is a convenience method to get access to the last Data::FormValidator messages that were created due to a form validation failure. These messages are simply flags indicating which fields were missinage, which failed their constraints and which constraints failed.

This method will take the URL and add the smolder version number to the front so that caching can be more aggressive. This is only done if it's not a developer install, so that developers aren't frustrated by having to fight with browser caches.

We also customize the resulting hash of messages that is generated upon validation failure. All failed and missing constraints will become err_$field. All fields that were present but failed a constraint will become invalid_$name (where $name is the name of the field or the name of the constraint if it's named). And all missing constraints will have a missing_$field message. Also, the 'any_errors' message will be set.