Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- use yii\helpers\Html;
- use yii\widgets\DetailView;
- /* @var $this yii\web\View */
- /* @var $model backend\models\Zayvki */
- $this->title = $model->id;
- $this->params['breadcrumbs'][] = ['label' => 'Zayvkis', 'url' => ['index']];
- $this->params['breadcrumbs'][] = $this->title;
- \yii\web\YiiAsset::register($this);
- ?>
- <div class="zayvki-view">
- <p>
- <?= Html::a('Редактировать', ['update', 'id' => $model->id], ['class' => 'btn btn-primary']) ?>
- </p>
- <?= DetailView::widget([
- 'model' => $model,
- 'attributes' => [
- 'id',
- 'user_id',
- 'status',
- 'master',
- 'uk',
- 'create_at',
- 'oplata_id',
- 'data_vyp',
- ],
- ]);
- [
- 'attribute' => 'orders',
- 'format' => 'html',
- 'value' => call_user_func(function($model)
- {
- $items = "";
- foreach ($model->orders as $related) {
- $items .= $related->uslugi->usluginame."<br>";
- }
- return $items;
- }, $model)
- ];
- ?>
- </div>
Advertisement
Add Comment
Please, Sign In to add comment