[Jifty-commit] r7683 - jifty/trunk/lib/Jifty/Action
Jifty commits
jifty-commit at lists.jifty.org
Tue Dec 1 04:24:48 EST 2009
Author: sartak
Date: Tue Dec 1 04:24:48 2009
New Revision: 7683
Modified:
jifty/trunk/lib/Jifty/Action/Record.pm
Log:
When running canonicalizers for record actions, pass on for => create/update
Modified: jifty/trunk/lib/Jifty/Action/Record.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Action/Record.pm (original)
+++ jifty/trunk/lib/Jifty/Action/Record.pm Tue Dec 1 04:24:48 2009
@@ -391,11 +391,13 @@
# Add a canonicalizer for the column if the record provides one
if ( $self->record->has_canonicalizer_for_column($field) ) {
$do_ajax = 1 unless defined $column->render_as and lc( $column->render_as ) eq 'checkbox';
+ my $for = $self->isa('Jifty::Action::Record::Create') ? 'create' : 'update';
$method ||= sub {
my ( $self, $value ) = @_;
return $self->record->run_canonicalization_for_column(
column => $field,
value => $value
+ extra => [{}, { for => $for }],
);
};
}
More information about the Jifty-commit
mailing list