Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
drupal.org
clientside_validation
Commits
ee1be5f8
Commit
ee1be5f8
authored
Oct 12, 2012
by
Jelle Sebreghts
Browse files
Issue #1804784 by SeanBannister: Fixed Bug with support for Field Validation Tokens.
parent
1213cdee
Changes
1
Hide whitespace changes
Inline
Side-by-side
clientside_validation_field_validation/clientside_validation_field_validation.js
View file @
ee1be5f8
...
...
@@ -26,9 +26,14 @@
Drupal
.
myClientsideValidation
.
validators
[
formid
].
settings
.
showErrors
=
function
(
errorMap
,
errorList
)
{
this
.
defaultShowErrors
();
for
(
var
index
in
errorList
)
{
var
label
=
this
.
errorsFor
(
errorList
[
index
].
element
);
var
$element
=
$
(
errorList
[
index
].
element
);
var
label
=
this
.
errorsFor
(
errorList
[
index
].
element
);
if
(
label
.
length
)
{
label
.
html
(
label
.
html
().
replace
(
"
[value]
"
,
$
(
errorList
[
index
].
element
).
val
()));
label
.
html
(
label
.
html
()
.
replace
(
"
[value]
"
,
$element
.
val
())
.
replace
(
"
[field-name]
"
,
$element
.
closest
(
"
.form-item
"
).
find
(
'
label
'
).
text
())
);
}
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment