Usage: use kartik\form\ActiveForm; use kartik\builder\TabularForm; $form = ActiveForm::begin($options); // $options is array for your form config echo TabularForm::widget([ 'model' => $model, // your model 'form' => $form, 'gridSettings' => [ 'toolbar' => \yii\helpers\Html::submitButton('Submit') ], 'attributes' => [ 'id' => ['type' => TabularForm::INPUT_STATIC], 'name' => ['type' => TabularForm::INPUT_TEXT], 'description' => ['type' => TabularForm::INPUT_TEXT], 'status' => ['type' => TabularForm::INPUT_CHECKBOX, 'enclosedByLabel' => true], ] ]); ActiveForm::end();
Since: 1.0
Author: Kartik Visweswaran (kartikv2@gmail.com)
Inheritance: extends BaseForm
Example #1
0
$buttons .= '<button type="button" class="btn btn-primary dropdown-toggle" data-toggle="dropdown">' . Yii::t('igolf', 'Add points') . ' <span class="caret"></span></button>';
$buttons .= '<ul class="dropdown-menu" role="menu">';
foreach ([1, 2, 5, 10, 20, 50] as $cnt) {
    $buttons .= '<li>' . Html::a(Yii::t('igolf', 'Add {0, number} points', $cnt), ['rule/addpoints', 'rule_id' => $rule->id, 'count' => $cnt]) . '</a></li>';
}
$buttons .= '</ul>';
$buttons .= '</div> ';
if ($rule->getPoints()->count() > 0) {
    $buttons .= Html::submitButton(Yii::t('igolf', 'Update Points'), ['class' => 'btn btn-primary']);
}
?>
<div class="point-index">

    <?php 
$form = ActiveForm::begin(['action' => Url::to(['/admin/point/updates'])]);
echo TabularForm::widget(['form' => $form, 'dataProvider' => $dataProvider, 'serialColumn' => false, 'actionColumn' => ['template' => '{delete}', 'controller' => 'point', 'buttons' => ['delete' => function ($url, $model) {
    return Html::a('<i class="glyphicon glyphicon-trash"></i>', $url, ['class' => 'btn', 'data-confirm' => Yii::t('igolf', 'Are you sure to delete this point?'), 'title' => Yii::t('igolf', 'Delete')]);
}], 'urlCreator' => function ($action, $model, $key, $index) {
    $url = '';
    switch ($action) {
        case 'delete':
            $url = Url::to(['point/delete-get', 'id' => $model->id]);
            break;
    }
    return $url;
}], 'checkboxColumn' => false, 'gridSettings' => ['floatHeader' => true, 'panel' => ['heading' => '<h4>' . $this->title . '</h4>', 'footer' => $buttons]], 'attributes' => ['position' => ['type' => TabularForm::INPUT_TEXT], 'points' => ['type' => TabularForm::INPUT_TEXT]]]);
ActiveForm::end();
?>

</div>
Example #2
0
    }
}
?>

                    </table>
                </div>
            </div>


            <div role="tabpanel" class="tab-pane" id="Specification">
              <div class="col-md-8">

                  <?php 
Pjax::begin(['id' => 'countries']);
$form = ActiveForm::begin();
echo TabularForm::widget(['dataProvider' => $dataProvider, 'form' => $form, 'attributes' => $model_q->formAttribs, 'gridSettings' => ['floatHeader' => true, 'panel' => ['heading' => '<h3 class="panel-title"><i class="glyphicon glyphicon-book"></i> Manage Books</h3>', 'type' => GridView::TYPE_PRIMARY, 'after' => Html::a('<i class="glyphicon glyphicon-plus"></i> Add New', '#', ['class' => 'btn btn-success create_cat_btn']) . ' ' . Html::submitButton('<i class="glyphicon glyphicon-floppy-disk"></i> Save', ['class' => 'btn btn-primary tabular_save_btn'])]]]);
ActiveForm::end();
Pjax::end();
?>
                
              </div>

              <div class="col-md-4">
                <div class="pane" style="padding:0;">
                  <h2><span>Preview</span></h2>
                    <div class="preview_cont">
                      
                    </div>
                </div>
              </div>
            </div>
Example #3
0
<?php

use common\models\Score;
use kartik\builder\TabularForm;
use kartik\grid\GridView;
use kartik\widgets\ActiveForm;
use yii\helpers\Html;
use yii\helpers\Url;
/* @var $this yii\web\View */
/* @var $searchModel app\models\RegistrationSearch */
/* @var $dataProvider yii\data\ActiveDataProvider */
$this->title = Yii::t('igolf', 'Scorecard');
?>
<div class="scorecard-update">

	<?php 
$form = ActiveForm::begin(['action' => Url::to(['update-scores', 'id' => $model->id])]);
?>

     <?php 
echo TabularForm::widget(['form' => $form, 'dataProvider' => $dataProvider, 'gridSettings' => ['panel' => ['heading' => '<h4>' . $this->title . '</h4>', 'footer' => Html::submitButton('Save', ['class' => 'btn btn-primary'])]], 'serialColumn' => [], 'actionColumn' => false, 'checkboxColumn' => false, 'attributes' => ['score' => ['type' => TabularForm::INPUT_TEXT], 'putts' => ['type' => TabularForm::INPUT_TEXT], 'teeshot' => ['type' => TabularForm::INPUT_DROPDOWN_LIST, 'items' => Score::getLocalizedConstants('TARGET_')], 'teeshot_length' => ['type' => TabularForm::INPUT_TEXT], 'regulation' => ['type' => TabularForm::INPUT_CHECKBOX], 'penalty' => ['type' => TabularForm::INPUT_TEXT], 'sand' => ['type' => TabularForm::INPUT_CHECKBOX], 'approach' => ['type' => TabularForm::INPUT_DROPDOWN_LIST, 'items' => Score::getLocalizedConstants('TARGET_')], 'approach_length' => ['type' => TabularForm::INPUT_TEXT], 'putt_length' => ['type' => TabularForm::INPUT_TEXT], 'putt' => ['type' => TabularForm::INPUT_DROPDOWN_LIST, 'items' => Score::getLocalizedConstants('TARGET_')]]]);
?>

	<?php 
ActiveForm::end();
?>
	
</div>
Example #4
0
<?php

use kartik\grid\GridView;
use kartik\builder\TabularForm;
use yii\data\ArrayDataProvider;
use yii\helpers\Html;
use yii\widgets\Pjax;
Pjax::begin();
$dataProvider = new ArrayDataProvider(['allModels' => $row]);
echo TabularForm::widget(['dataProvider' => $dataProvider, 'formName' => 'ReportTest', 'checkboxColumn' => false, 'actionColumn' => false, 'attributeDefaults' => ['type' => TabularForm::INPUT_TEXT], 'attributes' => ['test_id' => ['label' => 'Test', 'type' => TabularForm::INPUT_WIDGET, 'widgetClass' => \kartik\widgets\Select2::className(), 'options' => ['data' => \yii\helpers\ArrayHelper::map(\app\models\plrs\Test::find()->orderBy('id')->asArray()->all(), 'id', 'name'), 'options' => ['placeholder' => Yii::t('app', 'Choose Test')]], 'columnOptions' => ['width' => '200px']], 'result' => ['type' => TabularForm::INPUT_TEXT], 'del' => ['type' => TabularForm::INPUT_STATIC, 'label' => '', 'value' => function ($model, $key) {
    return Html::a('<i class="glyphicon glyphicon-trash"></i>', '#', ['title' => Yii::t('app', 'Delete'), 'onClick' => 'delRowReportTest(' . $key . '); return false;', 'id' => 'report-test-del-btn']);
}]], 'gridSettings' => ['panel' => ['heading' => '<h3 class="panel-title"><i class="glyphicon glyphicon-book"></i> ' . Yii::t('app', 'Report Test') . '  </h3>', 'type' => GridView::TYPE_INFO, 'before' => false, 'footer' => false, 'after' => Html::button('<i class="glyphicon glyphicon-plus"></i>' . Yii::t('app', 'Add Row'), ['type' => 'button', 'class' => 'btn btn-success kv-batch-create', 'onClick' => 'addRowReportTest()'])]]]);
Pjax::end();
Example #5
0
/* @var $searchModel app\models\RegistrationSearch */
/* @var $dataProvider yii\data\ActiveDataProvider */
$this->title = $competition->getFullName();
$this->params['breadcrumbs'][] = ['label' => Yii::t('igolf', 'Competitions'), 'url' => ['competition/index']];
$this->params['breadcrumbs'][] = $this->title;
$input_decimal = ['type' => function ($model, $key, $index, $widget) {
    return $model->hasDetails() ? TabularForm::INPUT_STATIC : TabularForm::INPUT_TEXT;
}, 'columnOptions' => ['width' => '100px']];
$apply_rule = in_array($competition->competition_type, [Competition::TYPE_TOURNAMENT, Competition::TYPE_SEASON]) ? Html::a(Yii::t('igolf', 'Compute'), Url::to(['competition/apply', 'id' => $competition->id]), ['class' => 'btn btn-primary']) : '';
?>
<div class="scorecard-index">

	<?php 
$form = ActiveForm::begin();
?>

     <?php 
echo TabularForm::widget(['form' => $form, 'dataProvider' => $dataProvider, 'gridSettings' => ['panel' => ['heading' => '<h4>' . $this->title . '</h4>', 'footer' => Html::submitButton('Save', ['class' => 'btn btn-primary']) . ' ' . $apply_rule . ' ' . Html::a(Yii::t('igolf', 'Scorecard Status'), Url::to(['status', 'id' => $competition->id]), ['class' => 'btn btn-primary']) . ' ' . Html::a(Yii::t('igolf', 'Publish'), Url::to(['publish', 'id' => $competition->id]), ['class' => 'btn btn-success'])]], 'serialColumn' => false, 'actionColumn' => false, 'checkboxColumn' => false, 'attributes' => ['id' => ['type' => TabularForm::INPUT_HIDDEN, 'columnOptions' => ['visible' => false]], 'golfer_name' => ['type' => TabularForm::INPUT_STATIC, 'value' => function ($model, $key, $index, $widget) {
    return $model->registration->golfer->name;
}, 'noWrap' => true], 'tee_time' => ['type' => TabularForm::INPUT_STATIC, 'value' => function ($model, $key, $index, $widget) {
    return $model->registration->flight ? $model->registration->flight->start_time : '';
}, 'noWrap' => true], 'golfer_hdcp' => ['type' => TabularForm::INPUT_STATIC, 'label' => Yii::t('igolf', 'Handicap'), 'value' => function ($model, $key, $index, $widget) {
    return $model->registration->golfer->handicap;
}, 'noWrap' => true], 'thru' => $input_decimal, 'score' => $input_decimal, 'score_net' => $input_decimal, 'stableford' => $input_decimal, 'stableford_net' => $input_decimal, 'points' => $input_decimal, 'rounds' => $input_decimal, 'status' => ['type' => TabularForm::INPUT_DROPDOWN_LIST, 'items' => Scorecard::getLocalizedConstants('STATUS_')]]]);
?>

	<?php 
ActiveForm::end();
?>
	
</div>
Example #6
0
?>
 

    <?php 
Pjax::begin(['id' => 'lanca-conteudo']);
?>
    <?php 
echo TabularForm::widget(['dataProvider' => $dataProvider, 'form' => $form, 'serialColumn' => false, 'checkboxColumn' => false, 'actionColumn' => false, 'attributes' => ['scheduleprofessorcontentid' => ['type' => TabularForm::INPUT_RAW, 'label' => 'ID', 'value' => function ($model, $key, $index, $widget) {
    // return Html::label($model->scheduleprofessorcontentid);
    return Html::label($model['scheduleprofessorcontentid']);
    // return Html::label($model->timeid);
}], 'date' => ['type' => TabularForm::INPUT_RAW, 'label' => 'Data', 'format' => ['date', 'php:d/m/Y'], 'value' => function ($model, $key, $index, $widget) {
    // return 'ola';
    //return Html::label(date('d/m/Y', strtotime($model->date)));
    return Html::label(date('d/m/Y', strtotime($model['date'])));
}], 'timeid' => ['type' => TabularForm::INPUT_RAW, 'label' => 'Horas', 'value' => function ($model, $key, $index, $widget) {
    // return 'ola';
    // return Html::label($model['timeid'] );
    return Html::label($model['timeid']->beginhour . ' às ' . $model['timeid']->endhour);
}], 'description' => ['type' => TabularForm::INPUT_RAW, 'label' => 'Conteúdo da Aula', 'value' => function ($model, $key, $index, $widget) {
    // return 'ola';
    // return Html::label($model['timeid'] );
    return Html::textarea($model['id'] . '_' . $model['scheduleprofessorcontentid'] . '_' . $model['scheduleprofessorid'] . '_' . $model['date'] . '_' . $model['timeid']->timeid . '_' . $model['timeid']->beginhour . '_' . $model['timeid']->endhour, $model['description'], ['class' => 'form-control text-conteudo-aula', 'id' => $model['id']]);
    //return Html::textarea([$model['id']][$model['scheduleprofessorcontentid']][$model['scheduleprofessorid']][$model['date']][$model['timeid']->timeid],$model['description'],['class'=>'form-control']);
}]], 'gridSettings' => ['floatHeader' => true, 'panel' => ['heading' => '<h3 class="panel-title"><i class="glyphicon glyphicon-book"></i>Conteúdo das Aulas</h3>', 'type' => GridView::TYPE_PRIMARY, 'after' => Html::Button('<i class="glyphicon glyphicon-floppy-disk"></i> Save', ['class' => 'btn btn-primary', 'onclick' => "ajaxSalvaConteudoAula('index.php?r=portal-professor/frequencia/salva-conteudo-aula','salvaConteudo');"])]]]);
?>


    <?php 
Pjax::end();
?>
    <?php 
Example #7
0
/*
 * By ptr.nov
 * Load Config CSS/JS
 */
use backend\assets\AppAsset;
use kartik\grid\GridView;
use kartik\widgets\ActiveForm;
AppAsset::register($this);
use yii\helpers\Html;
/*use yii\grid\GridView;*/
/* @var $this yii\web\View */
/* @var $searchModel app\models\maxi\MaxiprodakSearch */
/* @var $dataProvider yii\data\ActiveDataProvider */
$this->title = Yii::t('app', 'Maxiprodaks');
/*$this->params['breadcrumbs'][] = $this->title;*/
?>
<div class="maxiprodak-index">

    <?php 
echo GridView::widget(['dataProvider' => $dataProvider, 'columns' => [['class' => 'yii\\grid\\SerialColumn'], 'BRG_ID', 'BRG_NM', ['class' => 'yii\\grid\\ActionColumn'], ['class' => 'yii\\grid\\CheckboxColumn'], ['class' => '\\kartik\\grid\\RadioColumn']], 'exportConfig' => [GridView::EXCEL => ['iconOptions' => ['class' => 'text-success'], 'showHeader' => true, 'showPageSummary' => true, 'showFooter' => true, 'showCaption' => true, 'mime' => 'application/vnd.ms-excel', 'config' => ['cssFile' => '']], GridView::PDF => ['iconOptions' => ['class' => 'text-danger'], 'showHeader' => true, 'showPageSummary' => true, 'showFooter' => true, 'showCaption' => true, 'mime' => 'application/pdf', 'config' => ['mode' => 'c', 'format' => 'A4-L', 'destination' => 'D', 'marginTop' => 20, 'marginBottom' => 20, 'cssInline' => '.kv-wrap{padding:20px;}' . '.kv-align-center{text-align:center;}' . '.kv-align-left{text-align:left;}' . '.kv-align-right{text-align:right;}' . '.kv-align-top{vertical-align:top!important;}' . '.kv-align-bottom{vertical-align:bottom!important;}' . '.kv-align-middle{vertical-align:middle!important;}' . '.kv-page-summary{border-top:4px double #ddd;font-weight: bold;}' . '.kv-table-footer{border-top:4px double #ddd;font-weight: bold;}' . '.kv-table-caption{font-size:1.5em;padding:8px;border:1px solid #ddd;border-bottom:none;}', 'methods' => [], 'options' => [], 'contentBefore' => '', 'contentAfter' => '']]], 'panel' => ['heading' => '<h3 class="panel-title"><i class="glyphicon glyphicon-globe"></i> ' . $this->title . '</h3>', 'before' => Html::a('<i class="glyphicon glyphicon-plus"></i> ' . Yii::t('app', 'Create {modelClass}', ['modelClass' => 'Prodak']), ['create'], ['class' => 'btn btn-success'])], 'hover' => true]);
// mengunakan modal
use yii\bootstrap\Modal;
Modal::begin(['header' => '<h4 class="modal-title">Detail View Demo</h4>', 'toggleButton' => ['label' => '<i class="glyphicon glyphicon-th-list"></i> Detail View in Modal', 'class' => 'btn btn-primary']]);
use kartik\builder\TabularForm;
$form = ActiveForm::begin();
echo TabularForm::widget(['form' => $form, 'dataProvider' => $dataProvider, 'attributes' => ['BRG_ID' => ['type' => TabularForm::INPUT_STATIC, 'columnOptions' => ['hAlign' => GridView::ALIGN_CENTER]], 'BRG_NM' => ['type' => TabularForm::INPUT_TEXT]], 'gridSettings' => ['floatHeader' => true, 'panel' => ['heading' => '<h3 class="panel-title"><i class="glyphicon glyphicon-book"></i> Manage Books</h3>', 'type' => GridView::TYPE_PRIMARY, 'after' => Html::a('<i class="glyphicon glyphicon-plus"></i> Add New', '#', ['class' => 'btn btn-success']) . ' ' . Html::a('<i class="glyphicon glyphicon-remove"></i> Delete', '#', ['class' => 'btn btn-danger']) . ' ' . Html::submitButton('<i class="glyphicon glyphicon-floppy-disk"></i> Save', ['class' => 'btn btn-primary'])]]]);
ActiveForm::end();
?>

</div>
Example #8
0
use kartik\builder\TabularForm;
use kartik\grid\GridView;
use kartik\widgets\ActiveForm;
use yii\helpers\Html;
use yii\helpers\Url;
/* @var $this yii\web\View */
/* @var $searchModel app\models\RegistrationSearch */
/* @var $dataProvider yii\data\ActiveDataProvider */
$this->title = $scorecard->player->name;
$this->params['breadcrumbs'][] = ['label' => Yii::t('igolf', 'Competitions'), 'url' => ['competition/index']];
$this->params['breadcrumbs'][] = ['label' => $scorecard->registration->competition->name, 'url' => ['competition', 'id' => $scorecard->registration->competition_id]];
$this->params['breadcrumbs'][] = ['label' => $this->title, 'url' => ['view', 'id' => $scorecard->id]];
$this->params['breadcrumbs'][] = Yii::t('igolf', 'Update');
?>
<div class="scorecard-update">

	<?php 
$form = ActiveForm::begin();
?>

     <?php 
echo TabularForm::widget(['form' => $form, 'dataProvider' => $dataProvider, 'gridSettings' => ['panel' => ['heading' => '<h4>' . $this->title . '</h4>', 'footer' => Html::submitButton('Save', ['class' => 'btn btn-primary']) . ' ' . Html::a(Yii::t('igolf', 'Publish'), Url::to(['publish', 'id' => $scorecard->id]), ['class' => 'btn btn-success'])]], 'serialColumn' => [], 'actionColumn' => false, 'checkboxColumn' => false, 'attributes' => ['allowed' => ['type' => TabularForm::INPUT_STATIC, 'value' => function ($model, $key, $index, $widget) {
    return $model->hole->par . str_repeat(' •', $model->allowed);
}], 'score' => ['type' => TabularForm::INPUT_TEXT], 'putts' => ['type' => TabularForm::INPUT_TEXT], 'teeshot' => ['type' => TabularForm::INPUT_DROPDOWN_LIST, 'items' => Score::getLocalizedConstants('TARGET_')], 'teeshot_length' => ['type' => TabularForm::INPUT_TEXT], 'regulation' => ['type' => TabularForm::INPUT_CHECKBOX], 'penalty' => ['type' => TabularForm::INPUT_TEXT], 'sand' => ['type' => TabularForm::INPUT_CHECKBOX], 'approach' => ['type' => TabularForm::INPUT_DROPDOWN_LIST, 'items' => Score::getLocalizedConstants('TARGET_')], 'approach_length' => ['type' => TabularForm::INPUT_TEXT], 'putt_length' => ['type' => TabularForm::INPUT_TEXT], 'putt' => ['type' => TabularForm::INPUT_DROPDOWN_LIST, 'items' => Score::getLocalizedConstants('TARGET_')]]]);
?>

	<?php 
ActiveForm::end();
?>
	
</div>
Example #9
0
use frontend\models\TeamMember;
use common\models\User;
/* @var $this yii\web\View */
/* @var $model app\models\Timesheet */
$formatter = Yii::$app->formatter;
$this->title = $formatter->asDate($model->date, 'medium');
?>
<div class="timesheet-update">

<h1 style="text-align: center;"><?php 
echo Html::encode($this->title);
?>
</h1>
<br /><br /><br />
<?php 
$form = ActiveForm::begin();
echo TabularForm::widget(['form' => $form, 'dataProvider' => $dataProvider, 'attributes' => ['id' => ['type' => TabularForm::INPUT_TEXT, 'columnOptions' => ['hidden' => true]], 'work_time' => ['type' => TabularForm::INPUT_TEXT, 'label' => 'Work Time (hours)', 'columnOptions' => ['width' => '3em']], 'process_id' => ['type' => TabularForm::INPUT_WIDGET, 'widgetClass' => 'kartik\\widgets\\Select2', 'options' => ['data' => ArrayHelper::map(Process::find()->orderBy('process_name')->asArray()->all(), 'id', 'process_name')], 'label' => 'Process', 'columnOptions' => ['hAlign' => 'center', 'width' => '10em']], 'team_id' => ['type' => TabularForm::INPUT_WIDGET, 'widgetClass' => 'kartik\\widgets\\Select2', 'label' => 'Team', 'options' => ['data' => ArrayHelper::map(User::getUserTeams(Yii::$app->user->identity->id), 'id', 'team_name')], 'columnOptions' => ['hAlign' => 'center']], 'work_name' => ['type' => TabularForm::INPUT_TEXT, 'label' => 'Work Details', 'columnOptions' => ['hAlign' => 'center', 'width' => '15em']], 'comment' => ['type' => TabularForm::INPUT_TEXTAREA, 'label' => 'Comment', 'columnOptions' => ['hAlign' => 'center']]]]);
?>

<div class="form-group" style="text-align: right; margin-top: 20px;">
	<?php 
echo Html::submitButton('Save', ['class' => 'btn btn-success']);
?>
</div>

<?php 
ActiveForm::end();
?>

</div>
Example #10
0
<?php

$this->title = 'Manage Material Price';
$this->params['breadcrumbs'][] = $this->title;
use yii\helpers\Html;
use kartik\widgets\ActiveForm;
use kartik\builder\TabularForm;
use kartik\grid\GridView;
use kartik\widgets\TimePicker;
use yii\widgets\Pjax;
use kartik\widgets\DatePicker;
?>


<?php 
$form = ActiveForm::begin();
Pjax::begin();
echo TabularForm::widget(['gridSettings' => ['pjax' => true, 'panel' => ['type' => GridView::TYPE_PRIMARY, 'heading' => 'Manage Material Price']], 'actionColumn' => false, 'checkboxColumn' => false, 'dataProvider' => $dataProvider, 'form' => $form, 'attributes' => $searchModel->formAttribs]);
Pjax::end();
// Add other fields if needed or render your submit button
echo '<div class="text-right">' . Html::submitButton('Submit', ['class' => 'btn btn-primary']) . '<div>';
ActiveForm::end();
?>
</div>
Example #11
0
$this->title = Yii::t('igolf', 'Holes');
$buttons = '';
if (sizeof($tees->getHoles()->all()) == 0) {
    $buttons .= Html::a(Yii::t('igolf', 'Create holes'), ['tees/addholes', 'id' => $tees->id], ['class' => 'btn btn-primary']);
    $tees_with_holes = $tees->course->getTeesWithHoles();
    if (sizeof($tees_with_holes) > 0) {
        $buttons .= ' <div class="btn-group">';
        $buttons .= '<button type="button" class="btn btn-primary dropdown-toggle" data-toggle="dropdown">' . Yii::t('igolf', 'Copy tees set from') . ' <span class="caret"></span></button>';
        $buttons .= '<ul class="dropdown-menu" role="menu">';
        foreach ($tees_with_holes->each() as $twh) {
            $buttons .= '<li>' . Html::a($twh->name . ' (' . Yii::$app->params['tees_colors'][$twh->color] . ')', ['tees/copyholes', 'id' => $tees->id, 'copy_id' => $twh->id]) . '</li>';
        }
        $buttons .= '</ul>';
        $buttons .= '</div>';
    }
} else {
    // add button to update hole data
    $buttons .= Html::submitButton(Yii::t('igolf', 'Update Holes'), ['class' => 'btn btn-primary']);
}
?>
<div class="hole-index">

    <?php 
$form = ActiveForm::begin(['action' => Url::to(['/admin/hole/updates'])]);
echo TabularForm::widget(['form' => $form, 'dataProvider' => $dataProvider, 'serialColumn' => false, 'actionColumn' => ['template' => '{view}', 'controller' => 'hole'], 'checkboxColumn' => false, 'gridSettings' => ['floatHeader' => true, 'panel' => ['heading' => '<h4>' . $this->title . '</h4>', 'footer' => $buttons]], 'attributes' => ['position' => ['type' => TabularForm::INPUT_RAW, 'value' => function ($model, $key, $index, $widget) {
    return $model->position;
}], 'par' => ['type' => TabularForm::INPUT_TEXT], 'si' => ['type' => TabularForm::INPUT_TEXT], 'length' => ['type' => TabularForm::INPUT_TEXT]]]);
ActiveForm::end();
?>

</div>