7 msgConfiguration of $c->log with Catalyst::Log:...
8 msgInvalid session ids being generated
4 msgCatalyst / dbix-class / mysql / REST job
2 msgStrange UTF16 warning
1 msgWikipedia article improvement?
5 msgFastCGI: incomplete headers (0 bytes) received ...
5 msgBasic CRUD Tutorial
2 msgHow to display a single HTML::Widget form field...
7 msgLet's port Twitter to Perl
8 msgCatalyst, utf8 in form element type text
17 msgAnybody who fancies some LWP poking ...
54 msgRFC: Catalyst::Controller::REST::DBIC
1 msgKill the book thread please
2 msgMore Catalyst Template Toolkit examples?
6 msgFw: high school reunion (no subject)
2 msg(no subject)
6 msgUsing URIs for my app in another program
4 msgTutorial

$row->copy causing exit from controller(!)
\ Paul Makepeace (1 May 2008)
. \ Jonathan Rockway (1 May 2008)
. . \ Ash Berlin (1 May 2008)
. . . \ Ash Berlin (1 May 2008)
. . \ Paul Makepeace (1 May 2008)
. . . \ Aristotle Pagaltzis (1 May 2008)
. . . . \ Paul Makepeace (2 May 2008)
. . . . . \ Kieren Diment (2 May 2008)
. . . . . . \ Paul Makepeace (2 May 2008)
. . . . . \ Aristotle Pagaltzis (3 May 2008)
. \ Paul Makepeace (8 May 2008)

14 msgHow to print/display some data in an end action
Subject:$row->copy causing exit from controller(!)
Group:Catalyst
From:Paul Makepeace
Date:1 May 2008


 
I'm seeing something exceedingly odd: copying data causing a premature
return from the controller, like a detach(),

foreach my $table (@chart_related_tables) {
my $rs = $ds->resultset($table);
warn "copying $table for ", $new_chart->uid;
for my $row ($rs->search({web_chart_spec_uid => $chart->uid})) {
warn "..row ", $row->web_chart_spec_uid, $row;
$row->copy({web_chart_spec_uid => $new_chart->uid}); # XXX
}
#$_->copy({web_chart_spec_uid => $new_chart->uid})
#for $rs->search({web_chart_spec_uid => $chart->uid});
die "cloned", $new_chart->uid;
}

There's no further execution past the line marked XXX: the template is
rendered from that point on. The die is never called.

I have a feeling it's something to do with has_many

Chart:
__PACKAGE__->has_many(chartview_company => 'IDL::Schema::ChartCompany'
=> 'web_chart_spec_uid', {cascade_delete => 0});

If I exclude from @chart_related_tables ChartCompany it works.

**

I realize there's scads of debug I could provide but wanted to check
first this wasn't something someone had run into before. If not, what
kind of debug can I provide?

DBIC $VERSION = '0.08009';
Catalyst 5.7012

Paul

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


© 2004-2008 readlist.com