Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yii2
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PSDI Army
yii2
Commits
cb90f31c
Commit
cb90f31c
authored
Oct 23, 2014
by
Qiang Xue
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixes #5702: Parenthesis should be automatically added to `Validator::whenClient` to avoid js error
parent
284643fe
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
1 deletion
+2
-1
CHANGELOG.md
framework/CHANGELOG.md
+1
-0
ActiveField.php
framework/widgets/ActiveField.php
+1
-1
No files found.
framework/CHANGELOG.md
View file @
cb90f31c
...
...
@@ -12,6 +12,7 @@ Yii Framework 2 Change Log
-
Bug #5657:
`yii\caching\ApcCache::mset()`
and
`madd()`
may cause warning in some APC setup (LAV45)
-
Bug #5665: The
`currentPage`
meta data in the RESTful result should be 1-based, similar to that in HTTP headers (qiangxue)
-
Bug #5682: The
`asset`
command would incorrectly combine CSS files when
`UrlManager::linkAssets`
is true (dmvslv)
-
Bug #5702: Parenthesis should be automatically added to
`Validator::whenClient`
to avoid js error (mdmunir, qiangxue)
-
Bug: Gii console command help information does not contain global options (qiangxue)
-
Enh #3760: Gii model generator now imports classes when necessary instead of using fully qualified class names (umneeq, samdark)
-
Enh #5223: Query builder now supports selecting sub-queries as columns (qiangxue)
...
...
framework/widgets/ActiveField.php
View file @
cb90f31c
...
...
@@ -710,7 +710,7 @@ class ActiveField extends Component
$js
=
$validator
->
clientValidateAttribute
(
$this
->
model
,
$attribute
,
$this
->
form
->
getView
());
if
(
$validator
->
enableClientValidation
&&
$js
!=
''
)
{
if
(
$validator
->
whenClient
!==
null
)
{
$js
=
"if (
{
$validator
->
whenClient
}
(attribute, value)) {
$js
}"
;
$js
=
"if (
(
{
$validator
->
whenClient
}
)
(attribute, value)) {
$js
}"
;
}
$validators
[]
=
$js
;
}
...
...
Write
Preview
Markdown
is supported
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