예제 #1
0
	<div class="col-sm-12">
		<div class="page-header">
			<h1><?php 
echo Translate::language();
?>
				<small>
					<i class="ace-icon fa fa-angle-double-right"></i> <?php 
echo Translate::list_x([Translate::language()]);
?>
				</small>
			</h1>
		</div>
		<div class="space-6"></div>
		<p>
			<?php 
echo Html::a(Translate::add_a_new_x([Translate::language()]), ['create'], ['class' => 'btn btn-success']);
?>
		</p>
		<?php 
echo GridView::widget(['id' => 'language', 'dataProvider' => $dataProvider, 'filterModel' => $searchModel, 'export' => false, 'responsive' => true, 'hover' => true, 'pjax' => true, 'columns' => [['class' => 'kartik\\grid\\SerialColumn'], ['attribute' => 'name', 'vAlign' => 'middle'], ['attribute' => 'code', 'vAlign' => 'middle'], ['attribute' => 'country', 'vAlign' => 'middle'], ['class' => 'kartik\\grid\\BooleanColumn', 'trueLabel' => Translate::in_use(), 'falseLabel' => Translate::not_in_use(), 'attribute' => 'status', 'vAlign' => 'middle'], ['class' => 'yii\\grid\\ActionColumn', 'template' => '{update}{delete}']]]);
?>
	</div>
</div>
<script>
	<?php 
if (Yii::$app->getSession()->hasFlash('message')) {
    ?>
	alert('<?php 
    echo Yii::$app->getSession()->getFlash('message');
    ?>
');