Rose::DB::Object::Manager and HTML Template

257 Views Asked by At

I am using Rose::DB::Object::Manager (get/iterate methods) to source data from a database and HTML::Template for reporting.

The HTML report requires a TMPL_LOOP to display entries in a database.

My question is how do I create an array reference with the get/iterate methods of RDBOM and pass it to HTML::Template. Thank You.

1

There are 1 best solutions below

0
On

Rose::DB::Object::Manager's get/iterate methods will give you objects, but HTML::Template wants plain Perl data structures and values. To bridge the gap, use one or more of the methods in the Rose::DB::Object::Helpers module. The as_tree or column_value_pairs methods are probably your best bets.