--- trunk/lib/Frey/Run.pm 2008/08/31 18:02:50 180 +++ trunk/lib/Frey/Run.pm 2008/10/30 22:35:11 206 @@ -7,6 +7,11 @@ Frey::Run - display required form field for Class and run it +=head1 DESCRIPTION + +This object will try to run other Moose objects from your application. It +will try to invoke C or C method on the. + =cut has 'class' => ( @@ -44,10 +49,19 @@ } else { my $o = $class->new( %params ); $o->depends if $o->can('depends'); - $html = $o->markup; + if ( $o->can('html') ) { + warn "## turning over to $o->html"; + $o->html( $req ); + } elsif ( $o->can('markup') ) { + warn "## using $o->markup"; + $html = $o->markup; + warn ">>> markup $class ",length( $html ), " bytes\n"; + } else { + $html = "IGNORE: $class ", $o->dump; + warn $html; + } } - warn ">>> markup $class ",length( $html ), " bytes\n"; $req->print( $self->page( title => $class, body => $html ) ); }