
<?php \Laravel\Section::start('content'); ?>
	<div class="container">
		<div class="page-header">
			<h1>Historique technique des paiements reçus</h1>
		</div>
		<?php echo  BHelpers::notification() ; ?>
		<?php if($logs): ?>
		<table class="table table-striped table-hover datatable">
			<thead>
				<tr>
					<th>#</th>
					<th>Montant</th>
					<th>Statut</th>
					<th>Organisateur</th>
					<th>Projet</th>
					<th>Date</th>
				</tr>
			</thead>
			<tbody>
			<?php foreach($logs as $c): ?>
				<tr>
					<td><?php echo  $c->id ; ?></td>
					<td><?php echo  $c->amount ; ?></td>
					<td>
						<?php if($c->status == 'AUTHORISED'): ?>
						<span class="label label-success"><?php echo  $c->status ; ?></span>
						<?php elseif($c->status == 'REFUSED'): ?>
						<span class="label label-important"><?php echo  $c->status ; ?></span>
						<?php else: ?>
						<span class="label label-warning"><?php echo  $c->status ; ?></span>
						<?php endif; ?>
					</td>
					<td>
						<?php if($c->customer): ?>
						<a href="<?php echo URL::to_route('edit_customer',array($c->customer_id)); ?>"><?php echo $c->customer->email; ?></a>
						<?php else: ?>
						-
						<?php endif; ?>
					</td>
					<td>
						<?php if($c->project): ?>
						<a href="<?php echo URL::to_route('edit_project',array($c->project_id)); ?>"><?php echo $c->project->name; ?></a>
						<?php else: ?>
						-
						<?php endif; ?>
					</td>
					<td><?php echo  $c->updated_at ; ?></td>
				</tr>
			<?php endforeach; ?>
			</tbody>
		</table>
		<?php else: ?>
			<em>Aucun historique actuellement.</em>
		<?php endif; ?>
	</div>
<?php \Laravel\Section::stop(); ?>
<?php echo view('backend::template_default')->with(get_defined_vars())->render(); ?>