File: /var/www/html/performance.sumar.com.py/resources/views/exports/objetivos.blade.php
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Exportación de Objetivos</title>
</head>
<body>
<table class="table table-bordered">
<thead style="text-align: center;">
<tr>
<th>Objetivos</th>
<th>Indicadores</th>
<th>Meta</th>
<th>Planes de acción</th>
<th>Responsables</th>
<th>Fecha inicio</th>
<th>Fecha fin</th>
<th>Porcentaje de cumplimiento</th>
<th>Status</th>
</tr>
</thead>
<tbody>
@foreach($objetivos as $value)
<?php
if($value->status == "No Realizado"){
$fondo='bg-danger';
}elseif($value->status == "En Proceso"){
$fondo='bg-warning';
}elseif($value->status == "Realizado"){
$fondo='bg-success';
}elseif($value->status == "Suspendido"){
$fondo='bg-light';
}
?>
<tr>
<td>{{ $value->objetivos }}</td>
<td>{{ $value->indicadores }}</td>
<td>{{ $value->meta }}</td>
<td>{{ $value->planes }}</td>
<td>{{ $value->responsable }}</td>
<td>{{ $value->inicio }}</td>
<td>{{ $value->fin }}</td>
<td>{{ $value->porcentaje }} %</td>
<td class="{{$fondo}}">{{ $value->status }}</td>
</tr>
@endforeach
</tbody>
</table>
</body>
</html>