mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
BUGFIX: Fixed usability issue with CalendarDateField required field validation. Slightly over-coupled; resolve that in the jQuery validation rewrite.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.2@65490 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
b38253c2e0
commit
6ae1692c27
@ -108,7 +108,12 @@ Behaviour.register({
|
||||
},
|
||||
onblur : function() {
|
||||
if(this.old_onblur()) {
|
||||
return $('$formID').validate(this);
|
||||
// Don't perform instant validation for CalendarDateField fields; it creates usability wierdness.
|
||||
if(this.parentNode.className.indexOf('calendardate') == -1 || this.value) {
|
||||
return $('$formID').validate(this);
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
Loading…
x
Reference in New Issue
Block a user