marscld has asked for the wisdom of the Perl Monks concerning the following question:
Second, for TT file to display success action, there is a hyper link of 'Return to list'. However, empty data is filled for alink.sub url_create : Local { my ($self, $c, $title, $rating, $author_id) = @_; # Call create() on the book model object. Pass the table # columns/field values we want to set as hash values my $book = $c->model('DB::Books')->create({ title => $title, rating => $rating }); ...... }
Could anyone please provide some idea ? Thank you.[% # Provide a link back to the list page + -%] [% # 'uri_for()' builds a full URI; e.g., 'http://localhost:3000/b +ooks/list' -%] <p><a href="[% c.uri_for('/books/list') %]">Return to list</a></p>
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Catalyst: model & context object usage
by actualize (Monk) on Aug 11, 2008 at 04:48 UTC | |
by marscld (Beadle) on Aug 11, 2008 at 05:46 UTC | |
by actualize (Monk) on Aug 11, 2008 at 06:49 UTC | |
by marscld (Beadle) on Aug 11, 2008 at 07:37 UTC | |
by actualize (Monk) on Aug 11, 2008 at 16:12 UTC | |
| |
|
Re: Catalyst: model & context object usage
by juster (Friar) on Aug 11, 2008 at 06:28 UTC | |
|
Re: Catalyst: model & context object usage
by maletin (Sexton) on Dec 21, 2008 at 18:53 UTC |