From 971158afb196dbc91c72d7aa3c0d6183e5cb0a63 Mon Sep 17 00:00:00 2001 From: elsoftpy Date: Tue, 17 Sep 2024 10:17:29 -0400 Subject: [PATCH] correccion calculo TEA naviera --- app/Detalle_encuesta.php | 5 +++-- app/Http/Controllers/HomeController.php | 2 +- app/Http/Controllers/ReporteController.php | 6 +++++- app/Traits/ClubsTrait.php | 4 ++-- app/Traits/ReportTrait.php | 5 ++++- 5 files changed, 15 insertions(+), 7 deletions(-) diff --git a/app/Detalle_encuesta.php b/app/Detalle_encuesta.php index 25271f4..9e0e046 100644 --- a/app/Detalle_encuesta.php +++ b/app/Detalle_encuesta.php @@ -133,8 +133,9 @@ public function getAdicionalesNavierasAttribute(){ $this->adicional_amarre + $this->adicional_tipo_combustible + $this->adicional_embarque + - $this->adicional_carga; - + $this->adicional_carga + + $this->plus_rendimiento; + return $adicionales; } diff --git a/app/Http/Controllers/HomeController.php b/app/Http/Controllers/HomeController.php index 8c40f1d..5c0108b 100644 --- a/app/Http/Controllers/HomeController.php +++ b/app/Http/Controllers/HomeController.php @@ -42,7 +42,7 @@ public function index() $dbEncuestas = Cabecera_encuesta::where('empresa_id', $dbEmpresa->id) ->orderBy('id', 'DESC') ->get(); - $dbEncuestaAnt = $dbEncuestas->get(1); + $dbEncuestaAnt = $dbEncuestas->get(1); $club = $this->club($dbEmpresa->rubro_id); return view('clientes.home')->with('dbEmpresa', $dbEmpresa) diff --git a/app/Http/Controllers/ReporteController.php b/app/Http/Controllers/ReporteController.php index 4747c91..1a6f46d 100644 --- a/app/Http/Controllers/ReporteController.php +++ b/app/Http/Controllers/ReporteController.php @@ -1350,6 +1350,7 @@ public function resultadosExcel(Request $request){ $item->adicional_tipo_combustible + $item->adicional_embarque + $item->adicional_carga + + $item->plus_rendimiento + ( ( $item->fallo_caja + $item->fallo_caja_ext + $item->gratificacion_contrato + @@ -1375,7 +1376,10 @@ public function resultadosExcel(Request $request){ // Efectivo Total Anual if($rubro == 4){ $efectivoTotalAnual = $item->salario_anual + - $item->aguinaldo; + $item->aguinaldo + + $adicional + + $item->bono_anual + + $item->incentivo_largo_plazo; }else{ $efectivoTotalAnual = $efectivoAnual + $adicional + diff --git a/app/Traits/ClubsTrait.php b/app/Traits/ClubsTrait.php index 4d17418..2a399f0 100644 --- a/app/Traits/ClubsTrait.php +++ b/app/Traits/ClubsTrait.php @@ -55,7 +55,7 @@ public function club($rubro, $getImagen = null){ $club = "CARSA"; break; case 30: - $imagen = "images/caratula-agro.PNG"; + $imagen = "images/logo-carsa.png"; $club = "CARSA - sin svr"; break; case 31: @@ -146,7 +146,7 @@ public function club($rubro, $getImagen = null){ $club = "CARSA"; break; case 30: - $imagen = "images/caratula-agro.PNG"; + $imagen = "images/logo-carsa.png"; $club = "CARSA - sin svr"; break; case 31: diff --git a/app/Traits/ReportTrait.php b/app/Traits/ReportTrait.php index 3359ad0..f6eb7b1 100644 --- a/app/Traits/ReportTrait.php +++ b/app/Traits/ReportTrait.php @@ -964,7 +964,10 @@ public function segmenter( &$collection, // Efectivo Total Anual $detalle = $detalle->map(function($item){ $item['efectivo_total_anual'] = $item['salario_base'] * 12 + - $item['aguinaldo']; + $item['aguinaldo'] + + $item['adicionales_naviera'] + + $item['bono_anual'] + + $item['incentivo_largo_plazo']; return $item; });