mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-15 05:45:33 +08:00
Merge pull request #3285 from mikehaertl/master
Fix bootstrap templates
This commit is contained in:
@@ -173,6 +173,9 @@ class ActiveField extends \yii\widgets\ActiveField
|
||||
} else {
|
||||
$this->template = "<div class=\"checkbox\">\n{beginLabel}\n{input}\n{labelTitle}\n{endLabel}\n{error}\n{hint}\n</div>";
|
||||
}
|
||||
} else {
|
||||
$this->template = $options['template'];
|
||||
unset($options['template']);
|
||||
}
|
||||
$this->labelOptions['class'] = null;
|
||||
}
|
||||
@@ -189,6 +192,9 @@ class ActiveField extends \yii\widgets\ActiveField
|
||||
if ($this->inline) {
|
||||
if (!isset($options['template'])) {
|
||||
$this->template = "{label}\n{beginWrapper}\n{input}\n{error}\n{endWrapper}\n{hint}";
|
||||
} else {
|
||||
$this->template = $options['template'];
|
||||
unset($options['template']);
|
||||
}
|
||||
if (!isset($options['itemOptions'])) {
|
||||
$options['itemOptions'] = [
|
||||
@@ -209,6 +215,9 @@ class ActiveField extends \yii\widgets\ActiveField
|
||||
if ($this->inline) {
|
||||
if (!isset($options['template'])) {
|
||||
$this->template = "{label}\n{beginWrapper}\n{input}\n{error}\n{endWrapper}\n{hint}";
|
||||
} else {
|
||||
$this->template = $options['template'];
|
||||
unset($options['template']);
|
||||
}
|
||||
if (!isset($options['itemOptions'])) {
|
||||
$options['itemOptions'] = [
|
||||
|
||||
Reference in New Issue
Block a user