<?php
    /**
     * @var \common\models\Question $model;
     */
    use artbox\core\helpers\Url;
?>
<div class="service-comments style service-ansvers">
    <div class="style comments-h-autor"><?=$model->name?></div>
    <div class="style comments-h-text"><?=$model->question?> </div>
    <div class="style answers-date-wr">
        <span><?=date('d.m.Y', $model->created_at)?></span><p> <?=\Yii::t('app','Department');?>:
            <?php if ($model->service_id != null) {?>
            <a href="<?=Url::to(['alias' => $model->service->alias])?>"><?=$model->service->title?></a></p>
        <?php }?>
    </div>
    <div class="service-ansvers-text-wr style">
      <?php if ($model->doctor !== null){?>
        <div class="service-ansvers-title"><?=$model->doctor->position?> <span><?=$model->doctor->name?></span></div>
      <?php }?>
        <div class="service-ansvers-txt">
            <?=$model->answer?>
        </div>
    </div>
</div>
