Author image Colin Newell
and 1 contributors

NAME

OpusVL::AppKit::RolesFor::Plugin

VERSION

version 2.29

SYNOPSIS

    with 'OpusVL::AppKit::RolesFor::Plugin';


    after 'setup_components' => sub {
        my $class = shift;

        $class->add_paths(__PACKAGE__);

DESCRIPTION

This role helps integrate your module into a catalyst app by adding to the paths setup so that the auto directory contents are included in your app. This includes, TT templates, HTML::FormFu forms, static content and Excel::Template::Plus templates.

NAME

OpusVL::AppKit::RolesFor::Plugin

METHODS

add_paths

This sets up the paths for the TT templates and the Excel::Template::Plus view. Both views are setup to point to the same directory, named templates. It also sets up the static content path to point to the static directory.

It sets up the HTML::FormFu include directory so that it will pick up your forms. The AppKitForm attribute also has some logic to pull forms from the current module but that doesn't allow you to do includes on other forms, either within your own module, or across modules.

add_form_path

This sets up the HTML::FormFu include directory so that it will pick up your forms. The AppKitForm attribute also has some logic to pull forms from the current module but that doesn't allow you to do includes on other forms, either within your own module, or across modules.

This is called by the add_paths method. The primary reason this method is exposed is that this was originaly the only method on this role. Now I've added the add_paths method you should change any existing modules calling this method to use the add_paths call instead.

AUTHOR

OpusVL - www.opusvl.com

COPYRIGHT AND LICENSE

This software is copyright (c) 2010 by OpusVL - www.opusvl.com.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.