<?php
use yii\helpers\Html;

/* @var $this yii\web\View */
/* @var $model modules\forms\models\Dt129 */
/* @var $form yii\widgets\ActiveForm */
$this->title = $model->id;
/*$this->params['breadcrumbs'][] = ['label' => 'Dt129s', 'url' => ['index']]; */
/*$this->params['breadcrumbs'][] = $this->title;*/

?>
<div class="dt129-view">
    <table class="Table notbb nolb norb">
        <tr>
            <td colspan="10" rowspan="2" class="" style="padding:none;">
                <?= $this->render('//common/_viewheader', ['title' => 'Site Report Form (DT129)']) ?>
            </td>
            <td colspan="2" class="DarkerBlue">Pad no</td>
        </tr>
        <tr>
            <td colspan="2"><?= $model->padno ?></td>
        </tr>
        <tr>
            <td colspan="2" class="DarkerBlue">Date</td>
            <td colspan="2"><?= $model->date  ?></td>
            <td colspan="2" class="DarkerBlue">Location</td>
            <td colspan="2"><?= $model->location ?></td>
            <td colspan="2" class="DarkerBlue">Client</td>
            <td colspan="2"><?= $model->account != null ? $model->account->account_name : null; ?></td>
        </tr>
        <tr>
            <td colspan="2" class="DarkerBlue">Welders Name</td>
            <td colspan="2"><?= $model->weldersname ?></td>
            <td colspan="2" class="DarkerBlue">Welder’s signature</td>
            <td colspan="6">
                <img height="75px" width="auto" src="<?= $model->wsignatureloc ?>" />
            </td>
        </tr>
        <tr>
            <td colspan="2" class="DarkerBlue">Start Time:</td>
            <td colspan="2"><?= $model->starttime ?></td>
            <td colspan="2" class="DarkerBlue">Finish Time:</td>
            <td colspan="2"><?= $model->finishtime ?></td>
            <td colspan="2" class="DarkerBlue">Inline Job No</td>
            <td colspan="2"><?= $model->injobno ?></td>
        </tr>
        <br>
        <tr>
            <td colspan="12" class="textboxcenter">Detail in the section below all shift details that you deem relevant
                to the activity</td>
        </tr>
        <tr class="DarkerBlue">
            <td colspan="2">Issue No</td>
            <td colspan="2">Time Reported:</td>
            <td colspan="6">Description of Delay:</td>
            <td colspan="2">Time Lost:</td>
        </tr>
        <?php $x = 1; ?>
        <?php while($x <= 10) {?>
        <tr>
            <td colspan="2"><?= $x ?> </td>
            <td colspan="2"><?php $field = 'timereported'.$x; echo $model->$field ?></td>
            <td colspan="6"><?php $field = 'description'.$x; echo $model->$field ?></td>
            <td colspan="2"><?php $field = 'timelost'.$x; echo $model->$field ?></td>
            
        </tr>
        <?php $x++ ?>
        <?php } ?>
        <tr>
            <td colspan="10" class="text-right" align="right" style="padding-right:15px">Total Time lost</td>
            <td colspan="2"><?= $model->totaltimelost?></td>
        </tr>
        <tr>
            <td colspan="2" class="DarkerBlue">Client Name</td>
            <td colspan="4"><?= $model->clientname?></td>
            <td colspan="2" class="DarkerBlue">Client Signature</td>
            <td colspan="4">
                <img height="75px" width="auto" src="<?= $model->signatureloc ?>" />
            </td>
        </tr>
    </table>

    <div align="center">DT129 / <?= $model->id ?> / <?= $model->weldersname ?> </div>

</div>
<style>
.dt129-view td{
    padding: 10px 5px;
}
</style>