translate buttons and breadcrumbs

This commit is contained in:
Leorne 2019-12-06 12:05:14 +03:00
parent 48001992ff
commit a8e2543313
8 changed files with 11 additions and 11 deletions

View File

@ -6,7 +6,7 @@ use yii\helpers\Html;
/* @var $model common\models\Accesses */ /* @var $model common\models\Accesses */
$this->title = 'Добавить доступ'; $this->title = 'Добавить доступ';
$this->params['breadcrumbs'][] = ['label' => 'Accesses', 'url' => ['index']]; $this->params['breadcrumbs'][] = ['label' => 'Доступы', 'url' => ['index']];
$this->params['breadcrumbs'][] = $this->title; $this->params['breadcrumbs'][] = $this->title;
?> ?>
<div class="accesses-create"> <div class="accesses-create">

View File

@ -6,9 +6,9 @@ use yii\helpers\Html;
/* @var $model common\models\Accesses */ /* @var $model common\models\Accesses */
$this->title = 'Редактировать доступ: ' . $model->name; $this->title = 'Редактировать доступ: ' . $model->name;
$this->params['breadcrumbs'][] = ['label' => 'Accesses', 'url' => ['index']]; $this->params['breadcrumbs'][] = ['label' => 'Доступы', 'url' => ['index']];
$this->params['breadcrumbs'][] = ['label' => $model->name, 'url' => ['view', 'id' => $model->id]]; $this->params['breadcrumbs'][] = ['label' => $model->name, 'url' => ['view', 'id' => $model->id]];
$this->params['breadcrumbs'][] = 'Update'; $this->params['breadcrumbs'][] = 'Редактировать';
?> ?>
<div class="accesses-update"> <div class="accesses-update">

View File

@ -7,7 +7,7 @@ use yii\widgets\DetailView;
/* @var $model common\models\Accesses */ /* @var $model common\models\Accesses */
$this->title = $model->name; $this->title = $model->name;
$this->params['breadcrumbs'][] = ['label' => 'Accesses', 'url' => ['index']]; $this->params['breadcrumbs'][] = ['label' => 'Доступы', 'url' => ['index']];
$this->params['breadcrumbs'][] = $this->title; $this->params['breadcrumbs'][] = $this->title;
\yii\web\YiiAsset::register($this); \yii\web\YiiAsset::register($this);
?> ?>
@ -19,7 +19,7 @@ $this->params['breadcrumbs'][] = $this->title;
<?= Html::a('Удалить', ['delete', 'id' => $model->id], [ <?= Html::a('Удалить', ['delete', 'id' => $model->id], [
'class' => 'btn btn-danger', 'class' => 'btn btn-danger',
'data' => [ 'data' => [
'confirm' => 'Вы уверены, что хотите удалить эот элемент?', 'confirm' => 'Вы уверены, что хотите удалить этот элемент?',
'method' => 'post', 'method' => 'post',
], ],
]) ?> ]) ?>

View File

@ -27,7 +27,7 @@ $this->params['breadcrumbs'][] = $this->title;
//'id', //'id',
[ [
'label' => 'photo', 'label' => 'Фото',
'format' => 'raw', 'format' => 'raw',
'value' => function ($model) { 'value' => function ($model) {
return Html::img(Url::to($model->photo), [ return Html::img(Url::to($model->photo), [

View File

@ -22,7 +22,7 @@ use yii\widgets\ActiveForm;
<div class="row"> <div class="row">
<div class="col-xs-12"> <div class="col-xs-12">
<?= $form->field($model, 'fields')->widget(MultipleInput::class, [ <?= $form->field($model, 'fields')->widget(MultipleInput::class, [
'cloneButton' => true,
'columns' => [ 'columns' => [
[ [
'name' => 'field_id', 'name' => 'field_id',

View File

@ -13,6 +13,7 @@ $this->params['breadcrumbs'][] = $this->title;
<div class="additional-fields-view"> <div class="additional-fields-view">
<p> <p>
<?= Html::a('Список', ['index', 'id' => $model->id], ['class' => 'btn btn-primary']) ?>
<?= Html::a('Редактировать', ['update', 'id' => $model->id], ['class' => 'btn btn-primary']) ?> <?= Html::a('Редактировать', ['update', 'id' => $model->id], ['class' => 'btn btn-primary']) ?>
<?= Html::a('Удалить', ['delete', 'id' => $model->id], [ <?= Html::a('Удалить', ['delete', 'id' => $model->id], [
'class' => 'btn btn-danger', 'class' => 'btn btn-danger',
@ -22,7 +23,6 @@ $this->params['breadcrumbs'][] = $this->title;
], ],
]) ?> ]) ?>
<?= Html::a('Создать', ['create', 'id' => $model->id], ['class' => 'btn btn-success']) ?> <?= Html::a('Создать', ['create', 'id' => $model->id], ['class' => 'btn btn-success']) ?>
<?= Html::a('Показать все', ['index', 'id' => $model->id], ['class' => 'btn btn-primary']) ?>
</p> </p>
<?= DetailView::widget([ <?= DetailView::widget([

View File

@ -17,7 +17,7 @@ $this->params['breadcrumbs'][] = $this->title;
<?php // echo $this->render('_search', ['model' => $searchModel]); ?> <?php // echo $this->render('_search', ['model' => $searchModel]); ?>
<p> <p>
<?= Html::a('Create Status', ['create'], ['class' => 'btn btn-success']) ?> <?= Html::a('Добавить', ['create'], ['class' => 'btn btn-success']) ?>
</p> </p>
<?= GridView::widget([ <?= GridView::widget([

View File

@ -59,8 +59,8 @@ class Note extends \yii\db\ActiveRecord
'id' => 'ID', 'id' => 'ID',
'name' => 'Название', 'name' => 'Название',
'description' => 'Описание', 'description' => 'Описание',
'created_at' => 'Created At', 'created_at' => 'Создано',
'updated_at' => 'Updated At', 'updated_at' => 'Обновлено',
]; ];
} }
} }