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
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Rotua Panjaitan
yii2
Commits
ec663c36
Commit
ec663c36
authored
Jan 16, 2014
by
Qiang Xue
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2004 from klevron/1998
Fixes #1998 : get input value from hidden field when necessary
parents
3c05ee51
6594fbd2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
1 deletion
+6
-1
CHANGELOG.md
framework/CHANGELOG.md
+1
-0
yii.activeForm.js
framework/assets/yii.activeForm.js
+5
-1
No files found.
framework/CHANGELOG.md
View file @
ec663c36
...
...
@@ -31,6 +31,7 @@ Yii Framework 2 Change Log
-
Bug #1959:
`Html::activeCheckbox`
wasn't respecting custom values for checked/unchecked state (klevron, samdark)
-
Bug #1965:
`Controller::findLayoutFile()`
returns incorrect file path when layout name starts with a slash (qiangxue)
-
Bug #1993: afterFind event in AR is now called after relations have been populated (cebe, creocoder)
-
Bug #1998: Unchecked required checkbox never pass client validation (klevron)
-
Bug: Fixed
`Call to a member function registerAssetFiles() on a non-object`
in case of wrong
`sourcePath`
for an asset bundle (samdark)
-
Bug: Fixed incorrect event name for
`yii\jui\Spinner`
(samdark)
-
Bug: Json::encode() did not handle objects that implement JsonSerializable interface correctly (cebe)
...
...
framework/assets/yii.activeForm.js
View file @
ec663c36
...
...
@@ -381,7 +381,11 @@
var
$input
=
findInput
(
$form
,
attribute
);
var
type
=
$input
.
prop
(
'type'
);
if
(
type
===
'checkbox'
||
type
===
'radio'
)
{
return
$input
.
filter
(
':checked'
).
val
();
var
$realInput
=
$input
.
filter
(
':checked'
);
if
(
!
$realInput
.
length
)
{
$realInput
=
$form
.
find
(
'input[type=hidden][name="'
+
$input
.
prop
(
'name'
)
+
'"]'
);
}
return
$realInput
.
val
();
}
else
{
return
$input
.
val
();
}
...
...
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