예제 #1
0
/* <h1><?= Html::encode($this->title) ?></h1> */
?>
<div class="doclad-index">

    <?php 
// echo $this->render('_search', ['model' => $searchModel]);
?>

    <!-- p>
        <?php 
echo '';
?>
    </p -->

    <?php 
echo GridView::widget(['dataProvider' => $dataProvider, 'filterModel' => $searchModel, 'columns' => [['class' => 'yii\\grid\\DataColumn', 'attribute' => 'conferenceid', 'filter' => Conference::getList(), 'format' => 'raw', 'value' => function ($model, $key, $index, $column) {
    /** @var $model app\models\Person */
    return $model->section !== null ? Html::encode($model->section->conference->cnf_title) . '<br />' . Html::encode($model->section->sec_title) : '';
}], ['class' => 'yii\\grid\\DataColumn', 'attribute' => 'prs_fam', 'format' => 'raw', 'value' => function ($model, $key, $index, $column) {
    /** @var $model app\models\Person */
    return Html::encode($model->getPersonname(false)) . ' ' . Yii::$app->formatter->asEmail($model->prs_email) . '<br />' . Html::encode($model->prs_org);
}]]]);
?>

</div>

<div class="row">
    <div class="col-xs-12">
        <?php 
echo Html::a('Экспорт в xls', array_merge(['export'], $searchModel->getSearchArray()), ['class' => 'btn btn-default']);
?>
예제 #2
0
파일: _form.php 프로젝트: mosedu/confprof
/* @var $model app\models\Section */
/* @var $form yii\widgets\ActiveForm */
?>

<div class="section-form">

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

    <?php 
echo $form->field($model, 'sec_title')->textInput(['maxlength' => true]);
?>

    <?php 
echo $form->field($model, 'sec_cnf_id')->dropDownList(Conference::getList());
?>

    <?php 
echo $form->field($model, 'sec_doclad_type')->dropDownList(array_merge(['' => ''], Doclad::getAllTypes()));
?>

    <?php 
echo '';
?>

    <div class="form-group">
        <?php 
echo Html::submitButton($model->isNewRecord ? 'Создать' : 'Сохранить', ['class' => 'btn btn-success']);
?>
    </div>