[Jifty-commit] r1151 - in jifty/trunk: lib/Jifty/Action
jifty-commit at lists.jifty.org
jifty-commit at lists.jifty.org
Fri Jun 2 19:56:56 EDT 2006
Author: alexmv
Date: Fri Jun 2 19:56:55 2006
New Revision: 1151
Modified:
jifty/trunk/ (props changed)
jifty/trunk/lib/Jifty/Action/Record.pm
Log:
r13423 at zoq-fot-pik: chmrr | 2006-06-02 19:56:43 -0400
* Jifty::Action::Record doesn't clobber the action's validator if
there is a record validator
Modified: jifty/trunk/lib/Jifty/Action/Record.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Action/Record.pm (original)
+++ jifty/trunk/lib/Jifty/Action/Record.pm Fri Jun 2 19:56:55 2006
@@ -174,7 +174,8 @@
}
# build up a validator sub if the column implements validation
- if ( defined $column->validator && $column->validator ) {
+ # and we're not overriding it at the action level
+ if ( $column->validator and not $self->can("validate_$field")) {
$info->{ajax_validates} = 1;
$info->{validator} = sub {
my $self = shift;
@@ -187,7 +188,7 @@
else {
unless ($message) {
$self->log->error(
- qq{_Schema validator for $field didn't explain why the value '$value' is invalid}
+ qq{Schema validator for $field didn't explain why the value '$value' is invalid}
);
}
return (
More information about the Jifty-commit
mailing list