@extends('layouts.print')
 
@section('content')
<div class="main-content-wrapper">
	<div class="main-box">
		<div class="main-content">
			<div class="container">
				<div class="page">
					<div class="row">
						<div class="report-capital layout-print">
							<div class="header">
								<div class="logo">
									<img src="{{asset('assets/images/resize')}}/{{$branch->branch_img}}" alt="" width="200px">
								</div>
								<div class="title">
									<h2>{{$branch->branch_kh}}</h2>
									<h2>{{$branch->branch_en}}</h2>
									<h3>{{$title}}</h3>
								</div>
								<div class="clear"></div>
								<div class="border-bottom"></div>
								<div class="table">
									<table>
										<thead>
						                    <tr class="centers">
												<th>No </th>
												<th>Requested Date</th>
												<th>Transaction</th>
												<th>Agent Name</th>
												<th>Contact Person</th>
												<th>Remark</th>
												<th>Bank Name</th>
												<th>Account Name</th>
												<th>Account Number</th>
												<th>Amount</th>
												<th>Status</th>
						                    </tr>
						                </thead>
										<tbody>
											<?php $status=''; ?>
											@foreach($transac as $key => $value)
												<?php
                                                if($value->status == 3){
                                                    $status ='Proccessing';
                                                }else if($value->status == 1){
                                                    $status ='Done /'.$value->done_date;
                                                }
												?>
											<tr>
												<td>{{$key+1}}</td>
												<td>{{$value->app_rej_date}}</td>
												<td>Withdraw Funds</td>
												<td>{{$value->account_name.' ('.$value->account_number.')'}}</td>
												<td>{{$value->phone}}</td>
												<td>{{$value->remark}}</td>
												<td>{{$value->bank_name}}</td>
												<td>{{$value->bank_account_name}}</td>
												<td>{{$value->bank_account_number}}</td>
												<td class="right">$ {{number_format($value->amount,2)}}</td>
												<td>{{$status}}</td>

											</tr>
											@endforeach()
										</tbody>
										<tfoot>
											<tr>
												<th colspan="9">Total</th>
												<th class="right">${{number_format($amount,2)}}</th>
												<th></th>
											</tr>
										</tfoot>
									</table>
									<div class="make-date">
										<p>ធ្វើនៅ​ <strong>ភ្នំពេញ</strong> ថ្ងៃទី <strong>{{\Globals::date_khmers(date('Y-m-d'))}}</strong></p>
									</div>
									<div class="row">
										<div class="col-lg-12 col-sm-12 col-xs-12 tt">
											<div class="col-lg-4 col-sm-4 col-xs-4">
												<p>អ្នកធ្វើបញ្ជី</p>
												<p>ថាយ ម៉ាណែល</p>
											</div>
											<div class="col-lg-4 col-sm-4 col-xs-4">
												<p>អ្នកពិនិត្យ</p>
												<p>_________________</p>
											</div>
											<div class="col-lg-4 col-sm-4 col-xs-4">
												<p>ឯកភាព</p>
												<p>ស៊ីន មុំ  យ៉ែន សុខលីន</p>
											</div>
										</div>
									</div>
								</div>
							</div>
						</div>
							
						
					</div>
					
					
				</div>
			</div>
		</div>
	</div>
</div>
<style>
	.container{
		width: 360mm !important;
		margin-top: 10px;
	}
	@media print {
		html, body {
			width: 390mm !important;
			margin: 0mm 0 0 0 !important;
			background-color:#FFFFFF;
		}

	}
</style>
@endsection


