Fixes #14230: Fixed itemsOptions ignored in checkBoxList

This commit is contained in:
Evgeniy Moiseenko
2018-09-19 17:39:21 +03:00
committed by Alexander Makarov
parent 421bd96e99
commit a8bfe8bbe6
3 changed files with 14 additions and 2 deletions

View File

@ -4,6 +4,7 @@ Yii Framework 2 Change Log
2.0.16 under development
------------------------
- Bug #14230: Fixed `itemsOptions` ignored in `checkBoxList` (s1lver)
- Bug #14368: Added `role` attribute for active radio list (s1lver)
- Bug #16680: Fixed ActiveField 'text' input with maxlength (s1lver)
- Bug #5341: HasMany via two relations (shirase, cebe)

View File

@ -958,10 +958,10 @@ class BaseHtml
if ($formatter !== null) {
$lines[] = call_user_func($formatter, $index, $label, $name, $checked, $value);
} else {
$lines[] = static::checkbox($name, $checked, array_merge($itemOptions, [
$lines[] = static::checkbox($name, $checked, array_merge([
'value' => $value,
'label' => $encode ? static::encode($label) : $label,
]));
], $itemOptions));
}
$index++;
}