Skip to content

Commit 3dc3ca0

Browse files
author
Igor Chepurnoy
committed
fix form
1 parent 7716aab commit 3dc3ca0

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

Bootstrap.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ public function bootstrap($app)
2323
];
2424
}
2525

26-
if ($app->getModule('comment') === null) {
26+
if (!$app->hasModule('comment')) {
2727
$app->setModule('comment', ['class' => 'yii2mod\comments\Module']);
2828
}
2929

composer.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
"require": {
2222
"php": ">=5.6",
2323
"yiisoft/yii2": "~2.0.11",
24+
"yiisoft/yii2-bootstrap": "*",
2425
"yii2mod/yii2-enum": "*",
2526
"yii2mod/yii2-editable": "*",
2627
"yii2mod/yii2-comments": "*",

views/cms/_form.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
?>
1313
<div class="cms-model-form">
1414
<div class="row">
15-
<div class="col-md-8">
15+
<div class="col-md-10">
1616
<?php $form = ActiveForm::begin(['id' => 'cms-form']); ?>
1717

1818
<?php echo $form->field($model, 'title')->textInput(['maxlength' => true]); ?>
@@ -22,7 +22,7 @@
2222
'editorOptions' => Yii::$app->getModule('cms')->markdownEditorOptions,
2323
]); ?>
2424
<?php else: ?>
25-
<?php echo $form->field($model, 'content')->widget(Widget::class, Yii::$app->getModule('cms')->imperaviEditorOptions); ?>
25+
<?php echo $form->field($model, 'content')->widget(Widget::class, Yii::$app->getModule('cms')->froalaEditorOptions); ?>
2626
<?php endif; ?>
2727

2828
<?php echo $form->field($model, 'url', [

0 commit comments

Comments
 (0)