mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
MINOR: Provide a default message for FIELDISREQUIRED (from r106568)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112531 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
333a5b487b
commit
48cea784f6
@ -101,7 +101,7 @@ JS;
|
||||
foreach($this->required as $fieldName) {
|
||||
$formField = $fields->dataFieldByName($fieldName);
|
||||
if($formField && !$data[$fieldName]) {
|
||||
$errorMessage = sprintf(_t('Form.FIELDISREQUIRED').'.', strip_tags('"' . ($formField->Title() ? $formField->Title() : $fieldName) . '"'));
|
||||
$errorMessage = sprintf(_t('Form.FIELDISREQUIRED', '%s is required').'.', strip_tags('"' . ($formField->Title() ? $formField->Title() : $fieldName) . '"'));
|
||||
if($msg = $formField->getCustomValidationMessage()) {
|
||||
$errorMessage = $msg;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user