<?php
use yii\widgets\ActiveForm;
use yii\helpers\ArrayHelper;
use yii\helpers\Html;
use yii\helpers\Url;
use home\models\Attachment;
use common\models\User;

/* @var $this \yii\web\View */
/* @var $form yii\bootstrap\ActiveForm */
/* @var $model \home\modules\project\models\Project */

$this->title = '回款详情';
?>

<!--container-->
<div class="container manage-project fix">

    <!--manage-left -->
    <div class="manage-right">
        <div class="mgt10">
            <table class="table task-table taskdetail-table">
                <tr>
                    <td width="60" class="table-blue">客户名称</td>  
                    <td width="35%">
                        <a target="_blank" href="<?= isset($contract->customer->name)?Url::to(['/customer/customer/detail', 'id' => $contract->customer->customer_id]):'javascript:;' ?>">
                            <?= isset($contract->customer->name)?$contract->customer->name:'' ?>
                        </a>
                    </td>
                    <td width="60" class="table-blue">项目名称</td>
                    <?php if (empty($contract->project->name)) : ?>
                        <td width="35%"></td>
                    <?php else : ?>
                        <td width="35%">
                            <a target="_blank" href="<?= isset($contract->project->name)?Url::to(['/project/project/detail', 'id' => $contract->project->project_id]):'javascript:;' ?>">
                                <?= isset($contract->project->name)?$contract->project->name:'' ?>
                            </a>
                        </td>
                    <?php endif; ?>
                </tr>
                <tr>
                    <td width="60" class="table-blue">回款编号</td>  
                    <td width="35%"><?= $model->rece_no ?></td>
                    <td width="60" class="table-blue">回款金额</td>
                    <td width="35%"><?= $model->rece_money ?></td>
                </tr>
                <tr>
                    <td width="60" class="table-blue">回款开户行</td>  
                    <td width="35%"><?= $model->rece_bank ?></td>
                    <td width="60" class="table-blue">回款账号</td>
                    <td width="35%"><?= $model->rece_account ?></td>
                </tr>
                <tr>
                    <td width="60" class="table-blue">收款银行</td>  
                    <td width="35%"><?= isset($model->bank->name)?$model->bank->name:'' ?></td>
                    <td width="60" class="table-blue">收款账号</td>
                    <td width="35%"><?= $model->receiving_account ?></td>
                </tr>
                <tr>
                    <td width="60" class="table-blue">到款日期</td>  
                    <td width="35%"><?= date('Y-m-d', $model->to_date) ?></td>
                    <td width="60" class="table-blue">回款登记人</td>
                    <td width="35%"><?= User::findById($model->user_id)->realname ?></td>
                </tr>
                <tr>
                    <td width="60" class="table-blue">备注</td>  
                    <td colspan="3"><?= $model->remark ?></td>
                </tr>
            </table>
        </div>
    <!--manage-right--> 
</div>
<!--container-->
</div>