[Catalyst] forward not working correctly ?

John Napiorkowski jjn1056 at yahoo.com
Mon Feb 2 18:09:50 GMT 2015

FWIW I highly recommend not using ->forward at all.  ->detach has some sort of reasonable use but all the other 'skip around the code' methods almost always end up with a huge mess.  
That stuff was semi useful prior to chained actions and Moose in controllers (for reusable roles).  At this point there is very little I'd use that stuff for. 

     On Thursday, January 29, 2015 9:18 AM, Luca Ferrari <fluca1978 at infinito.it> wrote:

 Hi all,
I'm surely missing something in my action:

sub edit : Local Form {
    my ( $self, $c, $id ) = @_;
    my $form = $self->formbuilder();

    if ( $is_form_ok ){
        $c->forward( 'list' );
  } else {

The result is that the same page (the form for the edit action) is
always rendered, even if all the business logic works fine.
detach is not working as I'm expecting too, and  only visit appears to
render the list action, but without changing the url.

The development server console provides me the call chain:
 -> /workers/list
-> Smickets::View::HTML->process

I'm using TTSite as my view.
What am I missing?


List: Catalyst at lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.scsys.co.uk/pipermail/catalyst/attachments/20150202/1ce9dd4a/attachment.htm>

More information about the Catalyst mailing list