diff --git a/app/Area_en.php b/app/Area_en.php
new file mode 100644
index 0000000..a4afc98
--- /dev/null
+++ b/app/Area_en.php
@@ -0,0 +1,16 @@
+hasMany("App\Detalle_encuesta");
+ }
+}
diff --git a/app/Cargo.php b/app/Cargo.php
index b767c11..52b4077 100644
--- a/app/Cargo.php
+++ b/app/Cargo.php
@@ -26,4 +26,8 @@ public function nivel(){
return $this->belongsTo("App\Nivel");
}
+ public function cargoEn(){
+ return $this->hasOne('App\Cargo_en', 'id', 'id');
+ }
+
}
diff --git a/app/Cargo_en.php b/app/Cargo_en.php
new file mode 100644
index 0000000..6579efe
--- /dev/null
+++ b/app/Cargo_en.php
@@ -0,0 +1,29 @@
+hasMany("App\Encuestas_cargo");
+ }
+
+ public function cargosRubro(){
+ return $this->hasMany("App\Cargos_rubro");
+ }
+
+ public function area(){
+ return $this->belongsTo("App\Area");
+ }
+
+ public function nivel(){
+ return $this->belongsTo("App\Nivel_en");
+ }
+
+}
diff --git a/app/Cargos_rubro.php b/app/Cargos_rubro.php
index 63853a2..b44bee6 100644
--- a/app/Cargos_rubro.php
+++ b/app/Cargos_rubro.php
@@ -10,6 +10,8 @@ class cargos_rubro extends Model
protected $fillable = ["cargo_id", "rubro_id"];
+ public $timestamps = false;
+
public function rubro(){
return $this->belongsTo("App\Rubro");
}
@@ -18,6 +20,14 @@ public function cargo(){
return $this->belongsTo("App\Cargo");
}
+ public function cargoEn(){
+ return $this->belongsTo("App\Cargo_en", "cargo_id", "id");
+ }
+
+ public function getDescripcionRubroAttribute(){
+ return $this->rubro->descripcion;
+ }
+
}
diff --git a/app/Http/Controllers/CargosController.php b/app/Http/Controllers/CargosController.php
index 6c644ce..cbcc9ad 100644
--- a/app/Http/Controllers/CargosController.php
+++ b/app/Http/Controllers/CargosController.php
@@ -5,9 +5,13 @@
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;
use App\Cargo;
+use App\Cargo_en;
+use App\Cargos_rubro;
use App\Area;
use App\Nivel;
+use App\Rubro;
use flash;
+use DB;
class CargosController extends Controller
{
@@ -18,20 +22,46 @@ public function index(){
public function create(){
$dbNivel = Nivel::all()->pluck('descripcion', 'id');
- $dbArea = Area::all()->pluck('descripcion', 'id');
- return view('cargos.create')->with('dbNivel', $dbNivel)
+ $dbArea = Area::all()->pluck('descripcion', 'id');
+ $dbRubros = Rubro::get()->pluck('descripcion', 'id');
+ return view('cargos.create')->with('dbNivel', $dbNivel)
+ ->with('dbRubros', $dbRubros)
->with('dbArea', $dbArea);
}
public function store(Request $request){
- $dbData = new Cargo($request->all());
- if(!is_null($request->is_temporal)){
- $dbData->is_temporal = 1;
- }else{
- $dbData->is_temporal = 0;
- }
-
- $dbData->save();
+ DB::transaction(function() use($request){
+ $dbData = new Cargo($request->all());
+ if(!is_null($request->is_temporal)){
+ $dbData->is_temporal = 1;
+ }else{
+ $dbData->is_temporal = 0;
+ }
+
+ $dbDataEn = new Cargo_en($request->all());
+ if(!is_null($request->is_temporal)){
+ $dbDataEn->is_temporal = 1;
+ }else{
+ $dbDataEn->is_temporal = 0;
+ }
+ $dbDataEn->descripcion = $request->descripcion_en;
+ $dbDataEn->detalle = $request->detalle_en;
+
+ $dbData->save();
+ $dbDataEn->save();
+
+ if($request->rubros){
+ foreach ($request->rubros as $key => $value) {
+ $dbRubro = new Cargos_rubro();
+ $dbRubro->cargo_id = $dbData->id;
+ $dbRubro->rubro_id = $value;
+ $dbRubro->save();
+ }
+ }
+
+
+ });
+
return redirect()->route('cargos.index');
}
@@ -44,21 +74,57 @@ public function edit($id){
$dbData = Cargo::find($id);
$dbNivel = Nivel::all()->pluck('descripcion', 'id');
$dbArea = Area::all()->pluck('descripcion', 'id');
+ $dbRubros = Rubro::get()->pluck('descripcion', 'id');
return view('cargos.edit')->with('dbData', $dbData)
->with('dbNivel', $dbNivel)
+ ->with('dbRubros', $dbRubros)
->with('dbArea', $dbArea);
}
public function update(Request $request, $id){
+
+ //Cargo en español
+ $dbData = Cargo::find($id);
+ //Cargo en inglés
+ $dbDataEn = Cargo_en::find($id);
+ DB::transaction(function() use($request, $id, $dbData, $dbDataEn){
+ $dbRubros = Cargos_rubro::where('cargo_id', $id);
+
+ if($request->rubros){
+ if($dbRubros->count() > 0){
+ $dbRubros->delete();
+
+ }
+ foreach ($request->rubros as $key => $value) {
+ $dbRubro = new Cargos_rubro();
+ $dbRubro->cargo_id = $id;
+ $dbRubro->rubro_id = $value;
+ $dbRubro->save();
+ }
+ }else{
+ if($dbRubros->count() > 0){
+ $dbRubros->delete();
+ }
+ }
+
+ $dbData->fill($request->all());
+ $dbDataEn->fill($request->all());
+ if(!is_null($request->is_temporal)){
+ $dbData->is_temporal = 1;
+ $dbDataEn->is_temporal = 1;
+ }else{
+ $dbData->is_temporal = 0;
+ $dbDataEn->is_temporal = 0;
+ }
+ $dbDataEn->descripcion = $request->descripcion_en;
+ $dbDataEn->detalle = $request->detalle_en;
+
+ $dbData->save();
+ $dbDataEn->save();
+ });
+
+
- $dbData = Cargo::find($id);
- $dbData->fill($request->all());
- if(!is_null($request->is_temporal)){
- $dbData->is_temporal = 1;
- }else{
- $dbData->is_temporal = 0;
- }
- $dbData->save();
return redirect()->route('cargos.index');
}
diff --git a/app/Http/Controllers/LanguageController.php b/app/Http/Controllers/LanguageController.php
new file mode 100644
index 0000000..ca37c51
--- /dev/null
+++ b/app/Http/Controllers/LanguageController.php
@@ -0,0 +1,26 @@
+put('applocale', $lang);
+ }
+ return redirect()->back();
+ }
+
+ public function switchLangReport($lang){
+ if (array_key_exists($lang, config('languages'))) {
+ session()->put('applocale', $lang);
+ }
+ return "true";
+ }
+}
diff --git a/app/Http/Controllers/ReporteController.php b/app/Http/Controllers/ReporteController.php
index 9ac841e..aafb816 100644
--- a/app/Http/Controllers/ReporteController.php
+++ b/app/Http/Controllers/ReporteController.php
@@ -11,7 +11,9 @@
use App\Empresa;
use App\Ficha_dato;
use App\Nivel;
+use App\Nivel_en;
use App\Cargo;
+use App\Cargo_en;
use App\Rubro;
use App\User;
use Hash;
@@ -19,9 +21,13 @@
use Auth;
use Excel;
use Session;
+use Lang;
+
+
class ReporteController extends Controller
{
+
/**
* Display a listing of the resource.
*
@@ -32,6 +38,7 @@ public function index()
}
+
/**
* Show the form for creating a new resource.
*
@@ -67,8 +74,9 @@ public function show($id)
$empresa = Empresa::find($id);
$club = $this->club($empresa->rubro_id);
$rubro = $empresa->rubro_id;
+ $locale = $this->getIdioma();
//dd($club, $empresa->rubro_id);
- switch ($rubro) {
+ /*switch ($rubro) {
case 1:
$imagen = "images/caratula-bancos.PNG";
break;
@@ -84,102 +92,74 @@ public function show($id)
default:
$imagen = "images/caratula-autos.PNG";
break;
- }
-
- return view('report.home')->with('dbEmpresa', $id)->with('imagen', $imagen)->with('club', $club);
- }
+ }*/
+ $imagen = $this->club($empresa->rubro_id, true);
- private function club($rubro){
- switch ($rubro) {
- case 1:
- $imagen = "images/caratula-bancos.PNG";
- $club = "- Bancos de Paraguay";
- break;
- case 2:
- $imagen = "images/caratula-agro.PNG";
- $club = "- Empresas de Agronegocios - Paraguay";
- break;
- case 3:
- $imagen = "images/caratula-autos.PNG";
- $club = '- Empresas del Sector Automotriz, Maquinarias y Utilitarios';
- break;
- case 4:
- $imagen = "images/caratula-naviera.PNG";
- $club = "- Navieras de Paraguay";
- break;
- default:
- $imagen = "images/caratula-bancos.PNG";
- $club = "de Bancos";
- break;
- }
- return $club;
+ return view('report.home')->with('dbEmpresa', $id)
+ ->with('imagen', $imagen)
+ ->with('club', $club)
+ ->with('locale', $locale);
}
- /**
- * Display the specified resource.
- *
- * @param int $id
- * @return \Illuminate\Http\Response
- */
- public function filter($id)
- {
- $dbNiveles = Nivel::pluck('descripcion', 'id');
- $dbCargos = Cargo::orderBy('descripcion')->pluck('descripcion', 'id');
- $dbEmpresa = $id;
- return view('report.filter')->with('dbNiveles', $dbNiveles)->with('dbCargos', $dbCargos)->with('dbEmpresa', $dbEmpresa);
- }
-
- public function showCargosClub($id){
- $dbEmpresa = $id;
- $empresa = Empresa::find($id);
- $club = $this->club($empresa->rubro_id);
- $rubro = $empresa->rubro_id;
- if(Session::has('periodo')){
- $per = Session::get('periodo');
- $dbEncuesta = Cabecera_encuesta::where('empresa_id', $id)->whereRaw("periodo = '". $per."'")->first();
+ private function club($rubro, $getImagen = null){
+ if($this->getIdioma() == "en"){
+ switch ($rubro) {
+ case 1:
+ $imagen = "images/caratula-bancos.PNG";
+ $club = "Banking";
+ break;
+ case 2:
+ $imagen = "images/caratula-agro-en.PNG";
+ $club = "Agribusiness";
+ break;
+ case 3:
+ $imagen = "images/caratula-autos.PNG";
+ $club = 'Car and Machine';
+ break;
+ case 4:
+ $imagen = "images/caratula-naviera-en.PNG";
+ $club = "Shipping";
+ break;
+ case 6:
+ $imagen = "images/caratula-bancos.PNG";
+ $clue = "Non Governmental Organizations";
+ default:
+ $imagen = "images/caratula-bancos.PNG";
+ $club = "de Bancos";
+ break;
+ }
}else{
- $dbEncuesta = Cabecera_encuesta::where('empresa_id', $id)->whereRaw('id = (select max(id) from cabecera_encuestas where empresa_id = '. $id.')')->first();
- }
- $periodo = $dbEncuesta->periodo; // periodo de la encuesta actual
- $empresasId = Empresa::where('rubro_id', $rubro)->pluck('id');
- $encuestasRubro = Cabecera_encuesta::whereIn('empresa_id', $empresasId)->where('periodo', $periodo)->pluck('id');
- $encuestasCargos = Encuestas_cargo::whereIn('cabecera_encuesta_id', $encuestasRubro)->whereNotNull('cargo_id')->get();
- $cargosEmpresas = collect();
- foreach ($encuestasCargos as $encuestaCargo) {
- if($encuestaCargo->detalleEncuestas){
- if($encuestaCargo->detalleEncuestas->cantidad_ocupantes > 0){
- $cargosEmpresas->push(["cargo"=> $encuestaCargo->cargo_id, "empresa"=>$encuestaCargo->cabeceraEncuestas->empresa_id]);
- }
+ switch ($rubro) {
+ case 1:
+ $imagen = "images/caratula-bancos.PNG";
+ $club = "- Bancos de Paraguay";
+ break;
+ case 2:
+ $imagen = "images/caratula-agro.PNG";
+ $club = "- Empresas de Agronegocios - Paraguay";
+ break;
+ case 3:
+ $imagen = "images/caratula-autos.PNG";
+ $club = '- Empresas del Sector Automotriz, Maquinarias y Utilitarios';
+ break;
+ case 4:
+ $imagen = "images/caratula-naviera.PNG";
+ $club = "- Navieras de Paraguay";
+ break;
+ case 6:
+ $imagen = "images/caratula-bancos.PNG";
+ $clue = "- Organizaciones No Gubernamentales";
+ default:
+ $imagen = "images/caratula-bancos.PNG";
+ $club = "de Bancos";
+ break;
}
}
-
- $groupedCargosEmpresas = $cargosEmpresas->groupBy('cargo');
- $cargosIds = $groupedCargosEmpresas->map(function($item, $key){
- if($item->groupBy('empresa')->count() > 1){
- return $key;
- }
- })->values()->reject(function($value, $key){
- return is_null($value);
- })->sort();
-
- $cargos = Cargos_rubro::where('rubro_id', $rubro)->whereIn('cargo_id', $cargosIds)->get();
- //$cargos = Cargos_rubro::where('rubro_id', $rubro)->get();
- $cargos = $cargos->map(function($item){
- $item['nivel_id'] = $item->cargo->nivel->id;
- $item['descripcion'] = $item->cargo->descripcion;
- return $item;
- });
- $colNiveles = collect();
- foreach ($cargos as $key => $value) {
- $colNiveles->push($value->cargo->nivel->id);
+ if($getImagen){
+ return $imagen;
}
- $niveles = Nivel::whereIn('id', $colNiveles->unique())->orderBy('descripcion')->get();
- return view('report.cargos_club')->with('dbEmpresa', $dbEmpresa)
- ->with('club', $club)
- ->with('niveles', $niveles)
- ->with('cargos', $cargos);
+ return $club;
}
-
public function lista($id){
$dbEmpresa = $id;
$empresa = Empresa::find($id);
@@ -220,10 +200,39 @@ public function lista($id){
->with('niveles', $niveles)
->with('cargos', $cargos);
}
+
+ public function conceptos($id){
+ $dbEmpresa = $id;
+ $empresa = Empresa::find($id);
+ $rubro = $empresa->rubro_id;
+ $club = $this->club($empresa->rubro_id);
+ $locale = $this->getIdioma();
+ if($locale == 'en'){
+ return view('report.conceptos_en')->with('club', $club)->with('dbEmpresa', $dbEmpresa)->with('locale', $locale);
+ }else{
+ return view('report.conceptos')->with('club', $club)->with('dbEmpresa', $dbEmpresa)->with('locale', $locale);
+ }
+
+ }
+
+ public function metodologia($id){
+ $dbEmpresa = $id;
+ $empresa = Empresa::find($id);
+ $rubro = $empresa->rubro_id;
+ $club = $this->club($empresa->rubro_id);
+ $locale = $this->getIdioma();
+ if($locale == 'en'){
+ return view('report.metodologia_en')->with('club', $club)->with('dbEmpresa', $dbEmpresa)->with("locale", $locale);
+ }
+
+ return view('report.metodologia')->with('club', $club)->with('dbEmpresa', $dbEmpresa)->with("locale", $locale);
+ }
+
public function ficha($id){
$dbEmpresa = $id;
$empresa = Empresa::find($id);
$rubro = $empresa->rubro_id;
+ $locale = $this->getIdioma();
if(Session::has('periodo')){
$per = Session::get('periodo');
$dbEncuesta = Cabecera_encuesta::where('empresa_id', $id)->whereRaw("periodo = '". $per."'")->first();
@@ -269,25 +278,100 @@ public function ficha($id){
->with('periodo', $periodo)
->with('club', $club)
->with('tipoCambio', $tipoCambio)
+ ->with('locale', $locale)
->with('participantes', $participantes);
}
- public function conceptos($id){
- $dbEmpresa = $id;
+ /**
+ * Display the specified resource.
+ *
+ * @param int $id
+ * @return \Illuminate\Http\Response
+ */
+ public function filter($id)
+ {
$empresa = Empresa::find($id);
- $rubro = $empresa->rubro_id;
- $club = $this->club($empresa->rubro_id);
- return view('report.conceptos')->with('club', $club)->with('dbEmpresa', $dbEmpresa);
+ $cargosRubros = Cargos_rubro::where('rubro_id', $empresa->rubro_id)->pluck('cargo_id');
+ if($this->getIdioma() == "en"){
+ $dbNiveles = Nivel_en::pluck('descripcion', 'id');
+ $dbCargos = Cargo_en::orderBy('descripcion')
+ ->whereIn('id', $cargosRubros)
+ ->pluck('descripcion', 'id');
+ }else{
+ $dbNiveles = Nivel::pluck('descripcion', 'id');
+ $dbCargos = Cargo::orderBy('descripcion')
+ ->whereIn('id', $cargosRubros)
+ ->pluck('descripcion', 'id');
+ }
+ $dbEmpresa = $id;
+ return view('report.filter')->with('dbNiveles', $dbNiveles)->with('dbCargos', $dbCargos)->with('dbEmpresa', $dbEmpresa);
}
- public function metodologia($id){
+ public function showCargosClub($id){
$dbEmpresa = $id;
$empresa = Empresa::find($id);
- $rubro = $empresa->rubro_id;
$club = $this->club($empresa->rubro_id);
- return view('report.metodologia')->with('club', $club)->with('dbEmpresa', $dbEmpresa);
+ $rubro = $empresa->rubro_id;
+ $locale = $this->getIdioma();
+ if(Session::has('periodo')){
+ $per = Session::get('periodo');
+ $dbEncuesta = Cabecera_encuesta::where('empresa_id', $id)->whereRaw("periodo = '". $per."'")->first();
+ }else{
+ $dbEncuesta = Cabecera_encuesta::where('empresa_id', $id)->whereRaw('id = (select max(id) from cabecera_encuestas where empresa_id = '. $id.')')->first();
+ }
+ $periodo = $dbEncuesta->periodo; // periodo de la encuesta actual
+ $empresasId = Empresa::where('rubro_id', $rubro)->pluck('id');
+ $encuestasRubro = Cabecera_encuesta::whereIn('empresa_id', $empresasId)->where('periodo', $periodo)->pluck('id');
+ $encuestasCargos = Encuestas_cargo::whereIn('cabecera_encuesta_id', $encuestasRubro)->whereNotNull('cargo_id')->get();
+ $cargosEmpresas = collect();
+ foreach ($encuestasCargos as $encuestaCargo) {
+ if($encuestaCargo->detalleEncuestas){
+ if($encuestaCargo->detalleEncuestas->cantidad_ocupantes > 0){
+ $cargosEmpresas->push(["cargo"=> $encuestaCargo->cargo_id, "empresa"=>$encuestaCargo->cabeceraEncuestas->empresa_id]);
+ }
+ }
+ }
+
+ $groupedCargosEmpresas = $cargosEmpresas->groupBy('cargo');
+ $cargosIds = $groupedCargosEmpresas->map(function($item, $key){
+ if($item->groupBy('empresa')->count() > 1){
+ return $key;
+ }
+ })->values()->reject(function($value, $key){
+ return is_null($value);
+ })->sort();
+
+ $cargos = Cargos_rubro::where('rubro_id', $rubro)
+ ->whereIn('cargo_id', $cargosIds)->get();
+ //$cargos = Cargos_rubro::where('rubro_id', $rubro)->get();
+ $cargos = $cargos->map(function($item) use($locale){
+ if($locale == "es"){
+ $item['nivel_id'] = $item->cargo->nivel->id;
+ $item['descripcion'] = $item->cargo->descripcion;
+ }else{
+ $item['nivel_id'] = $item->cargoEn->nivel->id;
+ $item['descripcion'] = $item->cargoEn->descripcion;
+ }
+
+ return $item;
+ });
+ $colNiveles = collect();
+ foreach ($cargos as $key => $value) {
+ $colNiveles->push($value->cargo->nivel->id);
+ }
+ if($locale == "es"){
+ $niveles = Nivel::whereIn('id', $colNiveles->unique())->orderBy('descripcion')->get();
+ }else{
+ $niveles = Nivel_en::whereIn('id', $colNiveles->unique())->orderBy('descripcion')->get();
+ }
+
+ return view('report.cargos_club')->with('dbEmpresa', $dbEmpresa)
+ ->with('club', $club)
+ ->with('niveles', $niveles)
+ ->with('cargos', $cargos);
}
+
public function cargoReport(Request $request){
return $this->cargoReportAll($request, "view");
@@ -338,7 +422,6 @@ public function cargoReportClubExcel(Request $request){
switch ($key) {
case 'detalle_universo':
- //dd($item, $itemArray);
$this->CargaDetalle($item, $itemArray);
break;
@@ -752,25 +835,25 @@ private function cargaDetalle($item, &$itemArray){
}*/
switch ($value["Concepto"]) {
- case "Salario Base":
+ case Lang::get('reportReport.concept_salary'):
$this->cargador($value, $itemArray, true);
$salarioEmpresa = intval(str_replace(".", "", $value["Empresa"]));
break;
- case "Efectivo Anual Garantizado":
+ case Lang::get('reportReport.concept_concept_annual_cash'):
$this->cargador($value, $itemArray, false);
break;
- case "Variable Anual":
+ case Lang::get('reportReport.variable_pay'):
$variableAnual = true;
$this->cargador($value, $itemArray, false);
$variableAnualEmp = $value["Empresa"];
break;
- case "Total Adicional Anual":
+ case Lang::get('reportReport.concept_total_incentives'):
$this->cargador($value, $itemArray, false);
break;
- case "Bono Anual":
+ case Lang::get('reportReport.concept_bonus'):
$this->cargador($value, $itemArray, false);
break;
- case "Compensación Anual Total":
+ case Lang::get('reportReport.concept_total_comp'):
$this->cargador($value, $itemArray, false);
break;
}
@@ -804,6 +887,7 @@ private function cargaDetalle($item, &$itemArray){
}else{
$compMedSal = 0;
}
+
if($itemArray[8] > 0){
$comp75PercSal = round($salarioEmpresa/$itemArray[8] - 1, 2);
}else{
@@ -904,7 +988,7 @@ private function segmenter( &$collection,
// Salario Base y Anual
$this->pusher( $collection,
$countCasos,
- "Salario Base",
+ Lang::get('reportReport.concept_salary'),
$salarioMin,
$salarioMax,
$salarioProm,
@@ -927,7 +1011,7 @@ private function segmenter( &$collection,
$salarioAnual75Per = $this->percentile(75, $salariosBaseAnual);
$this->pusher( $collection,
$countCasos,
- "Salario Base Anual",
+ Lang::get('reportReport.concept_annual_salary'),
$salarioAnualMin,
$salarioAnualMax,
$salarioAnualProm,
@@ -949,7 +1033,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasosGratif,
- "Gratificación Anual Garantizada",
+ Lang::get('reportReport.concept_annual_gratif.'),
$gratificacionMin,
$gratificacionMax,
$gratificacionProm,
@@ -971,7 +1055,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasosAguinaldo,
- "Aguinaldo",
+ Lang::get('reportReport.concept_13month'),
$aguinaldoMin,
$aguinaldoMax,
$aguinaldoProm,
@@ -1007,7 +1091,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasos,
- "Efectivo Anual Garantizado",
+ Lang::get('reportReport.concept_annual_cash'),
$efectivoMin,
$efectivoMax,
$efectivoProm,
@@ -1031,7 +1115,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$casosAdicionalesBancos,
- "Total Adicional Anual",
+ Lang::get('reportReport.concept_total_incentives'),
$adicionalesMin * 12,
$adicionalesMax * 12,
$adicionalesProm * 12,
@@ -1054,7 +1138,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasosBono,
- "Bono Anual",
+ Lang::get('reportReport.concept_bonus'),
$bonoMin,
$bonoMax,
$bonoProm,
@@ -1100,7 +1184,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasos,
- "Aguinaldo Impactado por Adicional, Gratificación y Bono",
+ Lang::get('reportReport.concept_13month_impacted'),
$aguinaldoImpMin,
$aguinaldoImpMax,
$aguinaldoImpProm,
@@ -1139,7 +1223,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasos,
- "Compensación Anual Total",
+ Lang::get('reportReport.concept_total_compensation'),
$totalCompAnualMin,
$totalCompAnualMax,
$totalCompAnualProm,
@@ -1162,7 +1246,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasos,
- "Salario Base",
+ Lang::get('reportReport.concept_salary'),
$salarioMin,
$salarioMax,
$salarioProm,
@@ -1185,7 +1269,7 @@ private function segmenter( &$collection,
$salarioAnual75Per = $this->percentile(75, $salariosBaseAnual);
$this->pusher( $collection,
$countCasos,
- "Salario Base Anual",
+ Lang::get('reportReport.concept_annual_salary'),
$salarioAnualMin,
$salarioAnualMax,
$salarioAnualProm,
@@ -1206,7 +1290,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasosAguinaldo,
- "Aguinaldo",
+ Lang::get('reportReport.concept_13month'),
$aguinaldoMin,
$aguinaldoMax,
$aguinaldoProm,
@@ -1241,7 +1325,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasos,
- "Efectivo Anual Garantizado",
+ Lang::get('reportReport.concept_annual_cash'),
$efectivoMin,
$efectivoMax,
$efectivoProm,
@@ -1263,7 +1347,7 @@ private function segmenter( &$collection,
$countCasosPlus = $detalle->where('plus_rendimiento', '>', '0')->unique('cabecera_encuesta_id')->count();
$this->pusher( $collection,
$countCasosPlus,
- "Variable Anual",
+ Lang::get('reportReport.concept_variable_pay'),
$plusMin,
$plusMax,
$plusProm,
@@ -1285,7 +1369,7 @@ private function segmenter( &$collection,
$countCasosAmarre = $detalle->where('adicional_amarre', '>', '0')->unique('cabecera_encuesta_id')->count();
$this->pusher( $collection,
$countCasosAmarre,
- "Adicional por Amarre",
+ Lang::get('reportReport.concept_mooring'),
$amarreMin,
$amarreMax,
$amarreProm,
@@ -1308,7 +1392,7 @@ private function segmenter( &$collection,
$countCasosTipoCombustible = $detalle->where('adicional_tipo_combustible', '>', '0')->unique('cabecera_encuesta_id')->count();
$this->pusher( $collection,
$countCasosTipoCombustible,
- "Adicional por Tipo de Combustible",
+ Lang::get('reportReport.concept_fuel_type'),
$TipoCombustibleMin,
$TipoCombustibleMax,
$TipoCombustibleProm,
@@ -1330,7 +1414,7 @@ private function segmenter( &$collection,
$countCasosEmbarque = $detalle->where('adicional_embarque', '>', '0')->unique('cabecera_encuesta_id')->count();
$this->pusher( $collection,
$countCasosEmbarque,
- "Adicional por Disponibilidad/Embarque",
+ Lang::get('reportReport.concept_shipping'),
$embarqueMin,
$embarqueMax,
$embarqueProm,
@@ -1352,7 +1436,7 @@ private function segmenter( &$collection,
$countCasosCarga = $detalle->where('adicional_carga', '>', '0')->unique('cabecera_encuesta_id')->count();
$this->pusher( $collection,
$countCasosCarga,
- "Adicional por Carga",
+ Lang::get('reportReport.concept_load'),
$cargaMin,
$cargaMax,
$cargaProm,
@@ -1391,7 +1475,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$casosAdicionales,
- "Total Adicional Anual",
+ Lang::get('reportReport.concept_total_incentives'),
$totalAdicionalMin,
$totalAdicionalMax,
$totalAdicionalProm,
@@ -1413,7 +1497,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasosBono,
- "Bono Anual",
+ Lang::get('reportReport.concept_bonus'),
$bonoMin,
$bonoMax,
$bonoProm,
@@ -1450,7 +1534,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasos,
- "Efectivo Total Anual",
+ Lang::get('reportReport.concept_annual_cash_total'),
$efectivoTotalMin,
$efectivoTotalMax,
$efectivoTotalProm,
@@ -1474,7 +1558,7 @@ private function segmenter( &$collection,
$casosBeneficiosNavieras = $detalle->where('beneficios_navieras', '>', '0')->unique('cabecera_encuesta_id')->count();
$this->pusher( $collection,
$casosBeneficiosNavieras,
- "Total Beneficios Anual",
+ Lang::get('reportReport.concept_total_benefits'),
$beneficiosMin * 12,
$beneficiosMax * 12,
$beneficiosProm * 12,
@@ -1513,7 +1597,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasos,
- "Compensación Anual Total",
+ Lang::get('reportReport.concept_total_compensation'),
$totalCompAnualMin,
$totalCompAnualMax,
$totalCompAnualProm,
@@ -1535,7 +1619,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasos,
- "Salario Base",
+ Lang::get('reportReport.concept_salary'),
$salarioMin,
$salarioMax,
$salarioProm,
@@ -1558,7 +1642,7 @@ private function segmenter( &$collection,
$salarioAnual75Per = $this->percentile(75, $salariosBaseAnual);
$this->pusher( $collection,
$countCasos,
- "Salario Base Anual",
+ Lang::get('reportReport.concept_annual_salary'),
$salarioAnualMin,
$salarioAnualMax,
$salarioAnualProm,
@@ -1579,7 +1663,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasosGratif,
- "Gratificación Anual Garantizada",
+ Lang::get('reportReport.concept_annual_gratif.'),
$gratificacionMin,
$gratificacionMax,
$gratificacionProm,
@@ -1601,7 +1685,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasosAguinaldo,
- "Aguinaldo",
+ Lang::get('reportReport.concept_13month'),
$aguinaldoMin,
$aguinaldoMax,
$aguinaldoProm,
@@ -1644,7 +1728,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasos,
- "Efectivo Anual Garantizado",
+ Lang::get('reportReport.concept_annual_cash_total'),
$efectivoMin,
$efectivoMax,
$efectivoProm,
@@ -1667,7 +1751,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasosComision,
- "Comisión Anual",
+ Lang::get('reportReport.concept_annual_commission'),
$comisionMin*12,
$comisionMax*12,
$comisionProm*12,
@@ -1690,7 +1774,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasosAdicionales,
- "Total Adicional Anual",
+ Lang::get('reportReport.concept_total_additional'),
$adicionalesMin * 12,
$adicionalesMax * 12,
$adicionalesProm * 12,
@@ -1712,7 +1796,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasosBono,
- "Bono Anual",
+ Lang::get('reportReport.concept_bonus'),
$bonoMin,
$bonoMax,
$bonoProm,
@@ -1749,7 +1833,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasos,
- "Efectivo Total Anual",
+ Lang::get('reportReport.concept_annual_cash_total'),
$efectivoTotalMin,
$efectivoTotalMax,
$efectivoTotalProm,
@@ -1772,7 +1856,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasosBeneficios,
- "Total Beneficios Anual",
+ Lang::get('reportReport.concept_total_benefits'),
$beneficiosMin * 12,
$beneficiosMax * 12,
$beneficiosProm * 12,
@@ -1813,7 +1897,7 @@ private function segmenter( &$collection,
$this->pusher( $collection,
$countCasos,
- "Compensación Anual Total",
+ Lang::get('reportReport.concept_total_compensation'),
$totalCompAnualMin,
$totalCompAnualMax,
$totalCompAnualProm,
@@ -2405,13 +2489,29 @@ public function panel($id){
}
});
-
- return view('report.panel')->with('dbData', $dbData)->with('club', $club)->with('dbEmpresa', $dbEmpresa);
+
+ return view('report.panel') ->with('dbData', $dbData)
+ ->with('club', $club)
+ ->with('locale', $this->getIdioma())
+ ->with('dbEmpresa', $dbEmpresa);
}
public function getCargos(Request $request){
$id = $request->nivel_id;
- $dbData = Cargo::orderBy('descripcion')->where('nivel_id', $id)->pluck('id', 'descripcion');
+ $empresa = Empresa::find($request->empresa_id);
+
+ $cargosRubros = Cargos_rubro::where('rubro_id', $empresa->rubro_id)
+ ->pluck('cargo_id');
+ if($this->getIdioma() == "en"){
+ $dbData = Cargo_en::orderBy('descripcion')
+ ->whereIn('id', $cargosRubros)
+ ->pluck('id', 'descripcion');
+ }else{
+ $dbData = Cargo::orderBy('descripcion')
+ ->whereIn('id', $cargosRubros)
+ ->pluck('id', 'descripcion');
+ }
+
return $dbData;
}
@@ -2465,6 +2565,7 @@ public function setSession(Request $request){
}
private function cargoReportAll(Request $request, $tipo){
+ //dd($request->all());
$dbEmpresa = Empresa::find($request->empresa_id); // datos de la empresa del cliente
if(Session::has('periodo')){
$per = Session::get('periodo');
@@ -2478,9 +2579,17 @@ private function cargoReportAll(Request $request, $tipo){
->first();
//dd($dbEncuesta, $request->periodo);
}else{
- $dbEncuesta = Cabecera_encuesta::where('empresa_id', $dbEmpresa->id)
- ->whereRaw('id = (select max(id) from cabecera_encuestas where empresa_id = '. $dbEmpresa->id.')')
- ->first();
+ if($dbEmpresa->rubro_id == '1'){
+ $per = '06/2017';
+ $dbEncuesta = Cabecera_encuesta::where('empresa_id', $dbEmpresa->id)
+ ->whereRaw("periodo = '". $per."'")
+ ->first();
+ }else{
+ $dbEncuesta = Cabecera_encuesta::where('empresa_id', $dbEmpresa->id)
+ ->whereRaw('id = (select max(id) from cabecera_encuestas where empresa_id = '. $dbEmpresa->id.')')
+ ->first();
+ }
+
}
}
@@ -2488,8 +2597,13 @@ private function cargoReportAll(Request $request, $tipo){
$rubro = $dbEmpresa->rubro_id; // rubro de la empresa del cliente
// cargo oficial para el informe
- $cargo = $request->cargo_id;
- $dbCargo = Cargo::find($cargo);
+ $cargo = $request->cargo_id;
+ if($this->getIdioma() == "es"){
+ $dbCargo = Cargo::find($cargo);
+ }else{
+ $dbCargo = Cargo_en::find($cargo);
+ }
+
// empresas y cabeceras de encuestas de este periodo para empresas del rubro del cliente
$dbEncuestadas = Cabecera_encuesta::where('periodo', $periodo)
->where('rubro_id', $rubro)
@@ -2681,47 +2795,9 @@ private function cargoReportAll(Request $request, $tipo){
$periodo = implode('_', explode('/', $periodo));
$cargoFileName = str_replace("-", "_", str_replace(" ", "_", $dbCargo->descripcion));
$filename = 'Resultados_'.$periodo.'_'.$cargoFileName;
- $detalleUniverso = array();
- $detalleNacional = array();
- $detalleInternacional = array();
- foreach ($universo as $value) {
- $detalleUniverso[] = array( "Concepto"=>$value["concepto"],
- "Casos"=>$value["casos"],
- "Min"=>$value["min"],
- "25 Percentil"=>$value["per25"],
- "Promedio"=>$value["prom"],
- "Mediana"=>$value["med"],
- "75 Percentil"=>$value["per75"],
- "Max"=>$value["max"],
- "Empresa"=>$value["empresa"]
- );
- }
- foreach ($nacional as $value) {
- $detalleNacional[] = array( "Concepto"=>$value["concepto"],
- "Casos"=>$value["casos"],
- "Min"=>$value["min"],
- "25 Percentil"=>$value["per25"],
- "Promedio"=>$value["prom"],
- "Mediana"=>$value["med"],
- "75 Percentil"=>$value["per75"],
- "Max"=>$value["max"],
- "Empresa"=>$value["empresa"]
- );
- }
-
- foreach ($internacional as $value) {
- $detalleInternacional[] = array( "Concepto"=>$value["concepto"],
- "Casos"=>$value["casos"],
- "Min"=>$value["min"],
- "25 Percentil"=>$value["per25"],
- "Promedio"=>$value["prom"],
- "Mediana"=>$value["med"],
- "75 Percentil"=>$value["per75"],
- "Max"=>$value["max"],
- "Empresa"=>$value["empresa"]
- );
- }
-
+ $detalleUniverso = $this->segmentArrayFactory($universo);
+ $detalleNacional = $this->segmentArrayFactory($nacional);
+ $detalleInternacional = $this->segmentArrayFactory($internacional);
Excel::create($filename, function($excel) use($detalleUniverso, $detalleNacional, $detalleInternacional ) {
$excel->sheet("universo", function($sheet) use($detalleUniverso){
@@ -2786,11 +2862,35 @@ private function cargoReportAll(Request $request, $tipo){
$resultado = collect([
"detalle_universo"=> $detalleUniverso,
"detalle_nacional"=> $detalleNacional,
- "detalleInternacional"=>$detalleInternacional]);
+ "detalleInternacional"=>$detalleInternacional
+ ]);
return $resultado;
}
+
}
+ private function segmentArrayFactory($segmentArray){
+ foreach ($segmentArray as $value) {
+
+ $response[] = array( Lang::get('reportReport.table_concepts') => $value["concepto"],
+ Lang::get('reportReport.table_occupants') => $value["casos"],
+ Lang::get('reportReport.table_cases') => $value["casos"],
+ Lang::get('reportReport.table_min') => $value["min"],
+ Lang::get('reportReport.table_perc25') => $value["per25"],
+ Lang::get('reportReport.table_average') => $value["prom"],
+ Lang::get('reportReport.table_median') => $value["med"],
+ Lang::get('reportReport.table_perc75') => $value["per75"],
+ Lang::get('reportReport.table_max') => $value["max"],
+ Lang::get('reportReport.table_company') => $value["empresa"]
+ );
+ }
+ return $response;
+ }
+
+ private function getIdioma(){
+ return $locale = app()->getLocale();
+ }
+
}
diff --git a/app/Http/Kernel.php b/app/Http/Kernel.php
index bcabec4..bb4189a 100644
--- a/app/Http/Kernel.php
+++ b/app/Http/Kernel.php
@@ -30,6 +30,7 @@ class Kernel extends HttpKernel
\Illuminate\View\Middleware\ShareErrorsFromSession::class,
\App\Http\Middleware\VerifyCsrfToken::class,
\Illuminate\Routing\Middleware\SubstituteBindings::class,
+ \App\Http\Middleware\Localization::class,
],
'api' => [
diff --git a/app/Http/Middleware/Localization.php b/app/Http/Middleware/Localization.php
new file mode 100644
index 0000000..12399a0
--- /dev/null
+++ b/app/Http/Middleware/Localization.php
@@ -0,0 +1,30 @@
+hasMany("App\Detalle_encuesta");
+ }
+}
diff --git a/config/app.php b/config/app.php
index 88845fa..d04512f 100644
--- a/config/app.php
+++ b/config/app.php
@@ -12,7 +12,7 @@
| any other location as required by the application or its packages.
*/
- 'name' => 'Laravel',
+ 'name' => 'RiartConsulting S&B',
/*
|--------------------------------------------------------------------------
@@ -90,7 +90,7 @@
|
*/
- 'fallback_locale' => 'en',
+ 'fallback_locale' => 'es',
/*
|--------------------------------------------------------------------------
diff --git a/config/languages.php b/config/languages.php
new file mode 100644
index 0000000..306460a
--- /dev/null
+++ b/config/languages.php
@@ -0,0 +1,5 @@
+ 'English',
+ 'es' => 'Español',
+];
diff --git a/public/css/auxiliar.css b/public/css/auxiliar.css
index 40ea26d..c3dab49 100644
--- a/public/css/auxiliar.css
+++ b/public/css/auxiliar.css
@@ -60,29 +60,22 @@
box-shadow: 2px 5px 10px var(--color-smoke);
-
- &:hover {
+ }
+ .flat:hover {
transition: all 150ms linear;
color: #202129;
background-color: #e1e2e2;
opacity: 1;
opacity: .85;
- }
-
- &:active {
+ }
+ .flat:active {
transition: all 150ms linear;
opacity: .75;
background-color: #d5d6d6;
opacity: 1;
- }
-
- &:focus {
- outline: 1px dotted #959595;
- outline-offset: -4px;
- }
-
}
+
.items li:last-child{
padding-bottom: 0.5em !important;
}
@@ -99,3 +92,5 @@
.wrap{
overflow-wrap: normal;
}
+
+
\ No newline at end of file
diff --git a/public/css/translation.css b/public/css/translation.css
new file mode 100644
index 0000000..0085472
--- /dev/null
+++ b/public/css/translation.css
@@ -0,0 +1,45 @@
+
+ .language-switch-tooltip {
+ position: fixed;
+ right: 85px;
+ padding:0px 0.5rem;
+ text-align: right;
+ background-color: #323232;
+ border-radius: 2px;
+ color: #FFF;
+ width:auto;
+ }
+
+ /* metodolodgia style */
+ .section-metodologia ol{
+ font-weight: bold;
+ }
+
+ .metodologia-parrafo{
+ margin-top: 1em;
+ font-weight: 400 !important;
+ }
+
+ .bold{
+ font-weight: bold;
+ }
+
+ .normal{
+ font-weight: 400 !important;
+ }
+
+ .underlined{
+ text-decoration: underline;
+ }
+
+ .indented{
+ padding-left: 2em;
+ }
+
+ .conceptos_estadisticos{
+ padding-left: 2em;
+ }
+
+ .conceptos_estadisticos strong{
+ font-weight: 700;
+ }
\ No newline at end of file
diff --git a/public/images/caratula-agro_en.PNG b/public/images/caratula-agro_en.PNG
new file mode 100644
index 0000000..bcbec85
Binary files /dev/null and b/public/images/caratula-agro_en.PNG differ
diff --git a/public/images/caratula-naviera-en.PNG b/public/images/caratula-naviera-en.PNG
new file mode 100644
index 0000000..99efcb6
Binary files /dev/null and b/public/images/caratula-naviera-en.PNG differ
diff --git a/public/plugins/datatables/dataTables-materialize.css b/public/plugins/datatables/dataTables-materialize.css
index 99b177b..78be15e 100644
--- a/public/plugins/datatables/dataTables-materialize.css
+++ b/public/plugins/datatables/dataTables-materialize.css
@@ -26,7 +26,8 @@ table.dataTable thead .sorting_desc_disabled {
float: left;
margin-right: .5rem; }
.dataTables_wrapper .dataTables_filter input {
- width: calc(100% - 7rem); }
+ width: calc(100% - 7rem);
+ padding-left: 1em; }
.dataTables_wrapper .dataTables_filter .btn-floating {
margin-right: .5rem; }
.dataTables_wrapper .dataTables_info {
diff --git a/resources/lang/en/attachmentNotFound.php b/resources/lang/en/attachmentNotFound.php
new file mode 100644
index 0000000..0630082
--- /dev/null
+++ b/resources/lang/en/attachmentNotFound.php
@@ -0,0 +1,7 @@
+ 'We are sorry...',
+ 'label_not_found' => 'The file you requested was not found',
+ 'button_return_home' => 'Back Home',
+];
diff --git a/resources/lang/en/auth.php b/resources/lang/en/auth.php
index e5506df..aa48641 100644
--- a/resources/lang/en/auth.php
+++ b/resources/lang/en/auth.php
@@ -15,5 +15,7 @@
'failed' => 'These credentials do not match our records.',
'throttle' => 'Too many login attempts. Please try again in :seconds seconds.',
+ 'user_label' => 'Username',
+ 'password_label' => 'Password',
];
diff --git a/resources/lang/en/beneficiosReportCharts.php b/resources/lang/en/beneficiosReportCharts.php
new file mode 100644
index 0000000..8131a92
--- /dev/null
+++ b/resources/lang/en/beneficiosReportCharts.php
@@ -0,0 +1,7 @@
+ "Report",
+ "breadcrumb_home" => "Home",
+ "breadcrumb_results"=> "Results",
+ "title_practices" => "Práctices",
+];
\ No newline at end of file
diff --git a/resources/lang/en/beneficiosReportIndex.php b/resources/lang/en/beneficiosReportIndex.php
new file mode 100644
index 0000000..bf7694b
--- /dev/null
+++ b/resources/lang/en/beneficiosReportIndex.php
@@ -0,0 +1,7 @@
+ "Report",
+ "breadcrumb_home" => "Home",
+ "title_list" => "List of Indicators",
+ "button_sample" => "Universe Composition",
+];
\ No newline at end of file
diff --git a/resources/lang/en/cargosClientes.php b/resources/lang/en/cargosClientes.php
new file mode 100644
index 0000000..0808cf3
--- /dev/null
+++ b/resources/lang/en/cargosClientes.php
@@ -0,0 +1,11 @@
+ "Position",
+ "button_review" => "Review",
+ "table_description" => "Description",
+ "table_salary" => "Salary",
+ "table_options" => "Options",
+ "label_list" => "List of Positions",
+ "label_greeting" => "Greetings",
+ "first_time_p" => "This is the first time you participate on this study. Please create a new position",
+];
\ No newline at end of file
diff --git a/resources/lang/en/cargosClientesEdit.php b/resources/lang/en/cargosClientesEdit.php
new file mode 100644
index 0000000..d0f147a
--- /dev/null
+++ b/resources/lang/en/cargosClientesEdit.php
@@ -0,0 +1,62 @@
+ "Edit Position",
+ "title_add_position" => "Add New Position",
+ "label_amount_disclaimer" => "All amounts are completed in local currency and in thounsands of Guaranies",
+ "form_label_position" => "Job",
+ "form_label_area" => "Area",
+ "form_label_level" => "Level",
+ "form_label_incumbents" => "Incumbents",
+ "form_label_salary" => "Base Pay",
+ "form_label_allowance" => "Allowance",
+ "form_label_13th_month" => "Fix Bonus (or 13th Month)",
+ "form_label_commission" => "Comission - Monthly",
+ "form_label_variable_pay" => "Variable Pay",
+ "form_label_cash_failure" => "Cash Failure",
+ "form_label_cash_failre_fc" => "Cash Failure (foreign currency)",
+ "form_label_additional_level" => "Additional for Level Job",
+ "form_label_additional_degree" => "Additional per University Degree",
+ "form_label_fix_bonus" => "Additional as a Fix Bonus",
+ "form_label_plus_mooring" => "Plus: Mooring",
+ "form_label_plus_fuel" => "Plus: Fuel Type",
+ "form_label_plus_shipping" => "Plus: Available Shipping",
+ "form_label_plus_type_load" => "Plus: Type of Load",
+ "form_label_annual_bonus_amount"=> "Annual Bonus (amount)",
+ "form_label_annual_bonus_qty" => "Annual Bonus (target/N° of base pay/salary)",
+ "form_label_long_term_incentive"=> "Long Term Incentive",
+ "form_label_lunch" => "Lunch (middle day)",
+ "form_label_health_insurance" => "Health Insurance",
+ "form_label_hi_coverage" => "% of Coverage by Organization",
+ "form_label_life_insurance" => "Life Insurance",
+ "form_label_li_provider" => "Life Insurance Provider",
+ "form_label_car_company" => "Organization/Company Car",
+ "form_label_fuel_card" => "Fuel Card",
+ "form_label_fuel_card_amount" => "Amount of Fuel Card",
+ "form_label_car_brand" => "Car Brand",
+ "form_label_car_model" => "Car Model",
+ "form_label_car_price" => "Car Price",
+ "form_label_car_insurance" => "Insurance Car Cost",
+ "form_label_car_maintenance" => "Maintenance Car Cost",
+ "form_label_amount_km" => "Amount per Km",
+ "form_label_children_education" => "Children's Education Allowance",
+ "form_label_meals_furnished" => "Employee Meals Furnished by Organization",
+ "form_label_cellular" => "Cellular Plan",
+ "form_label_language_course" => "Language Course Cost",
+ "form_label_lc_coverage" => "% of Coverage by Organization (language course)",
+ "form_label_lc_type" => "Language Course: Single or Team/Group",
+ "option_label_single" => "Single",
+ "option_label_group" => "Team/Group",
+ "form_label_education_tuition" => "Education Tuition/Expendures (eg. Post Grade/MBA or other)",
+ "form_label_et_coverage" => "% of Coverage by Organization (education)",
+ "form_label_house_rental" => "House Rental",
+ "form_label_expat_children_edu" => "Children's Education Allowance (only for expat)",
+ "form_label_incumbent_condition"=> "Incumbent: Local or Expatriate",
+ "option_label_local" => "Local",
+ "option_label_expatriate" => "Expatriate",
+ "form_label_region" => "Region",
+ "select_label_choose" => "Please Choose...",
+ "option_label_yes" => "Yes",
+ "option_label_no" => "No",
+ "checkbox_label_exclude" => "Exclude",
+ "button_label_save" => "Save",
+];
\ No newline at end of file
diff --git a/resources/lang/en/editEmpresa.php b/resources/lang/en/editEmpresa.php
new file mode 100644
index 0000000..5997eff
--- /dev/null
+++ b/resources/lang/en/editEmpresa.php
@@ -0,0 +1,11 @@
+ "Organization",
+ "label_club" => "Club",
+ "label_segment" => "Sector",
+ "label_branches" => "Number of Branches",
+ "label_headcount" => "Incumbents",
+ "label_origin" => "Local/International",
+ "label_edit" => "Edit Organization",
+ "button_save" => "Save",
+];
\ No newline at end of file
diff --git a/resources/lang/en/homepage.php b/resources/lang/en/homepage.php
new file mode 100644
index 0000000..dae4998
--- /dev/null
+++ b/resources/lang/en/homepage.php
@@ -0,0 +1,15 @@
+ "Organization",
+ "table_club" => "Club",
+ "table_segment" => "Sector",
+ "table_branches" => "N° of Branches",
+ "table_headcount" => "Employees",
+ "table_origin" => "Local/International",
+ "button_list" => "List your Jobs",
+ "button_edit" => "Edit",
+ "button_report" => "Report",
+ "button_done" => "End",
+ "modal_survey" => "Select Survey",
+ "modal_button_close"=> "Close",
+];
\ No newline at end of file
diff --git a/resources/lang/en/layout.php b/resources/lang/en/layout.php
new file mode 100644
index 0000000..be04c65
--- /dev/null
+++ b/resources/lang/en/layout.php
@@ -0,0 +1,6 @@
+ "Panel",
+ "menu_complete" => "Complete",
+ "menu_report" => "Report",
+];
diff --git a/resources/lang/en/reportFilter.php b/resources/lang/en/reportFilter.php
new file mode 100644
index 0000000..60fb43b
--- /dev/null
+++ b/resources/lang/en/reportFilter.php
@@ -0,0 +1,10 @@
+ "Filter by Job",
+ "label_level" => "Level",
+ "label_position" => "Particular Position",
+ "label_description" => "Position Summary",
+ "button_report" => "Salary Report",
+ "select_option" => "Select a Job",
+ "select_level" => "Select a level",
+];
\ No newline at end of file
diff --git a/resources/lang/en/reportLayout.php b/resources/lang/en/reportLayout.php
new file mode 100644
index 0000000..8caff45
--- /dev/null
+++ b/resources/lang/en/reportLayout.php
@@ -0,0 +1,11 @@
+ "Panel",
+ "menu_concepts" => "Thecnical Concepts",
+ "menu_methodology" => "Methodology",
+ "menu_sheet" => "Thecnical Sheet",
+ "menu_indicators" => "Position Indicator",
+ "menu_search" => "Look for Position",
+ "menu_universe" => "All Positions",
+ "menu_attachment" => "Salary Summary"
+];
\ No newline at end of file
diff --git a/resources/lang/en/reportPanel.php b/resources/lang/en/reportPanel.php
new file mode 100644
index 0000000..bf754d4
--- /dev/null
+++ b/resources/lang/en/reportPanel.php
@@ -0,0 +1,10 @@
+ "Id",
+ "table_description" => "Organization",
+ "table_branches" => "N° of Branches",
+ "table_employees" => "Employees",
+ "table_origin" => "Local/International",
+ "label_origin_national" => "Local",
+ "label_origin_international" => "International",
+];
\ No newline at end of file
diff --git a/resources/lang/en/reportReport.php b/resources/lang/en/reportReport.php
new file mode 100644
index 0000000..78de080
--- /dev/null
+++ b/resources/lang/en/reportReport.php
@@ -0,0 +1,49 @@
+ "Convert to GS.",
+ "button_currency_us" => "Convert to U\$D",
+ "p_currency_gs" => "Values shown in thousands of Guaraníes",
+ "p_currency_us" => "Values shown in American Dollars",
+ "label_tab_universe" => "All Participants",
+ "label_tab_national" => "Local",
+ "label_tab_international" => "International",
+ "table_concepts" => "Concepts",
+ "table_cases" => "Number of Organizations",
+ "table_occupants" => "Incumbents",
+ "table_min" => "Minimum",
+ "table_perc25" => "25th Percentile",
+ "table_average" => "Average",
+ "table_median" => "Median",
+ "table_perc75" => "75th Percentile",
+ "table_max" => "Maximum",
+ "table_company" => "Your Organization",
+ "table_avg_compare" => "Compare to Average",
+ "table_median_compare" => "Compare to Median",
+ "table_perc75_compare" => "Compare to 75th Perc.",
+ "table_max_compare" => "Compare to Maximum",
+ "title_universe" => "All Participants",
+ "title_national" => "Local",
+ "title_international" => "International",
+ "chart_salary" => "Monthly Base Salary",
+ "chart_annual_cash" => "Annual Guaranted Cash",
+ "chart_total_comp" => "Annual Total Compensation",
+ "concept_salary" => "Monthly Base Salary",
+ "concept_annual_salary" => "Annual Base Salary",
+ "concept_annual_gratif." => "Annual Fixed Additional",
+ "concept_13month" => "13th Month",
+ "concept_annual_cash" => "Annual Guaranteed Cash",
+ "concept_total_incentives" => "Annual total short-term incentives",
+ "concept_bonus" => "Bonus",
+ "concept_13month_impacted" => "13th Month - Impacted by: (annual base salary + additional fixed + annual total short-term incentives)/12",
+ "concept_total_compensation"=> "Annual Total Compensation",
+ "concept_variable_pay" => "Annual Variable Pay",
+ "concept_mooring" => "Annual Additional: mooring",
+ "concept_fuel_type" => "Annual Additional: fuel type",
+ "concept_shipping" => "Annual Additional: available shipping",
+ "concept_load" => "Annual Additional: type of load",
+ "concept_total_benefits" => "Annual Total Benefits",
+ "concept_annual_cash_total" => "Annual Total Cash",
+ "concept_annual_commission" => "Annual Total Commission",
+ "concept_total_additional" => "Annual Total Incentives",
+
+];
\ No newline at end of file
diff --git a/resources/lang/en/reportThecnicalSheet.php b/resources/lang/en/reportThecnicalSheet.php
new file mode 100644
index 0000000..18f7f7c
--- /dev/null
+++ b/resources/lang/en/reportThecnicalSheet.php
@@ -0,0 +1,8 @@
+ "Date",
+ "tab_label_jobs" => "N° of Jobs",
+ "tab_label_panel" => "Panel",
+ "tab_label_exchange" => "Exchange/Rate",
+
+];
\ No newline at end of file
diff --git a/resources/lang/es/attachmentNotFound.php b/resources/lang/es/attachmentNotFound.php
new file mode 100644
index 0000000..191fd4f
--- /dev/null
+++ b/resources/lang/es/attachmentNotFound.php
@@ -0,0 +1,7 @@
+ 'Lo sentimos...',
+ 'label_not_found' => 'El archivo solicitado no fue encontrado',
+ 'button_return_home' => 'Volver al Inicio',
+];
diff --git a/resources/lang/es/auth.php b/resources/lang/es/auth.php
index ac9ffc5..a7f560d 100644
--- a/resources/lang/es/auth.php
+++ b/resources/lang/es/auth.php
@@ -15,5 +15,6 @@
'failed' => 'Los datos no corresponden a nuestros registros',
'throttle' => 'Demasiados intentos de autenticación. Por favor intétalo en :seconds segundos.',
-
+ 'user_label' => 'Usuario',
+ 'password_label' => 'Contraseña',
];
diff --git a/resources/lang/es/beneficiosReportCharts.php b/resources/lang/es/beneficiosReportCharts.php
new file mode 100644
index 0000000..20c14e9
--- /dev/null
+++ b/resources/lang/es/beneficiosReportCharts.php
@@ -0,0 +1,7 @@
+ "Reporte",
+ "breadcrumb_home" => "Inicio",
+ "breadcrumb_results"=> "Resultados",
+ "title_practices" => "Prácticas",
+];
\ No newline at end of file
diff --git a/resources/lang/es/beneficiosReportIndex.php b/resources/lang/es/beneficiosReportIndex.php
new file mode 100644
index 0000000..451bfd6
--- /dev/null
+++ b/resources/lang/es/beneficiosReportIndex.php
@@ -0,0 +1,7 @@
+ "Reporte",
+ "breadcrumb_home" => "Inicio",
+ "title_list" => "Lista de Indicadores",
+ "button_sample" => "Composición de la Muestra",
+];
\ No newline at end of file
diff --git a/resources/lang/es/cargosClientes.php b/resources/lang/es/cargosClientes.php
new file mode 100644
index 0000000..1d650fa
--- /dev/null
+++ b/resources/lang/es/cargosClientes.php
@@ -0,0 +1,11 @@
+ "Cargo",
+ "button_review" => "Revisar",
+ "table_description" => "Descripción",
+ "table_salary" => "Salario",
+ "table_options" => "Opciones",
+ "label_list" => "Listado de Cargos",
+ "label_greeting" => "Saludos",
+ "first_time_p" => "Esta la primera vez que participa de la Encuesta. Por favor ingrese un cargo nuevo",
+];
\ No newline at end of file
diff --git a/resources/lang/es/cargosClientesEdit.php b/resources/lang/es/cargosClientesEdit.php
new file mode 100644
index 0000000..71ae2bd
--- /dev/null
+++ b/resources/lang/es/cargosClientesEdit.php
@@ -0,0 +1,62 @@
+ "Editar Cargo",
+ "title_add_position" => "Crear Nuevo Cargo",
+ "label_amount_disclaimer" => "Los montos se cargan en moneda local y en miles de Guaraníes",
+ "form_label_position" => "Cargo",
+ "form_label_area" => "Area",
+ "form_label_level" => "Nivel",
+ "form_label_incumbents" => "Cantidad de Personas",
+ "form_label_salary" => "Salario",
+ "form_label_allowance" => "Gratificación",
+ "form_label_13th_month" => "Aguinaldo",
+ "form_label_commission" => "Comisión Mensual",
+ "form_label_variable_pay" => "Plus por Rendimiento",
+ "form_label_cash_failure" => "Fallo de Caja",
+ "form_label_cash_failre_fc" => "Fallo de Caja Moneda Extranjera",
+ "form_label_additional_level" => "Adicional por Nivel de Cargo",
+ "form_label_additional_degree" => "Adicional por Título",
+ "form_label_fix_bonus" => "Gratificación por Contrato",
+ "form_label_plus_mooring" => "Adicional por Amarre",
+ "form_label_plus_fuel" => "Adicional por Tipo de Combustible",
+ "form_label_plus_shipping" => "Adicional por Embarque",
+ "form_label_plus_type_load" => "Adicional por Tipo de Carga",
+ "form_label_annual_bonus_amount"=> "Bono Anual (monto)",
+ "form_label_annual_bonus_qty" => "Bono Anual (Cantidad)",
+ "form_label_long_term_incentive"=> "Incentivo a Largo Plazo",
+ "form_label_lunch" => "Refrigerio",
+ "form_label_health_insurance" => "Seguro Médico",
+ "form_label_hi_coverage" => "Cobertura Seguro Médico",
+ "form_label_life_insurance" => "Seguro de Vida",
+ "form_label_li_provider" => "Aseguradora (Seguro de Vida)",
+ "form_label_car_company" => "Automóvil Empresa",
+ "form_label_fuel_card" => "Tarjeta Flota",
+ "form_label_fuel_card_amount" => "Monto de la Tarjeta Flota",
+ "form_label_car_brand" => "Marca del Automóvil",
+ "form_label_car_model" => "Model del Automóvil",
+ "form_label_car_price" => "Valor del Automóvil",
+ "form_label_car_insurance" => "Seguro del Automóvil",
+ "form_label_car_maintenance" => "Costo de Mantenimiento Automóvil",
+ "form_label_amount_km" => "Monto por Km Recorrido",
+ "form_label_children_education" => "Ayuda Escolar",
+ "form_label_meals_furnished" => "Comedor Interno",
+ "form_label_cellular" => "Celular Corporativo",
+ "form_label_language_course" => "Curso de Idiomas",
+ "form_label_lc_coverage" => "Cobertura del Curso de Idiomas",
+ "form_label_lc_type" => "Tipo de Curso de Idiomas",
+ "option_label_single" => "Individual",
+ "option_label_group" => "Grupal",
+ "form_label_education_tuition" => "Post Grado o Maestría",
+ "form_label_et_coverage" => "Cobertura de la Maestría",
+ "form_label_house_rental" => "Importe de Cobertura por Vivienda",
+ "form_label_expat_children_edu" => "Importe - Cobertura Colegio Hijos",
+ "form_label_incumbent_condition"=> "Condición del Ocupante",
+ "option_label_local" => "Local",
+ "option_label_expatriate" => "Expatriado",
+ "form_label_region" => "Región",
+ "select_label_choose" => "Elija una opción...",
+ "option_label_yes" => "Sí",
+ "option_label_no" => "No",
+ "checkbox_label_exclude" => "Excluir",
+ "button_label_save" => "Guardar",
+];
\ No newline at end of file
diff --git a/resources/lang/es/editEmpresa.php b/resources/lang/es/editEmpresa.php
new file mode 100644
index 0000000..d4ffab6
--- /dev/null
+++ b/resources/lang/es/editEmpresa.php
@@ -0,0 +1,11 @@
+ "Descripción",
+ "label_club" => "Club",
+ "label_segment" => "Segmento",
+ "label_branches" => "Cantidad de Sucursales",
+ "label_headcount" => "Cantidad de Empleados",
+ "label_origin" => "Origen",
+ "label_edit" => "Editar Empresa",
+ "button_save" => "Save",
+];
\ No newline at end of file
diff --git a/resources/lang/es/homepage.php b/resources/lang/es/homepage.php
new file mode 100644
index 0000000..25025bd
--- /dev/null
+++ b/resources/lang/es/homepage.php
@@ -0,0 +1,15 @@
+ "Descripción",
+ "table_club" => "Club",
+ "table_segment" => "Segmento",
+ "table_branches" => "Nro. Sucursales",
+ "table_headcount" => "Nro. Emp.",
+ "table_origin" => "Origen",
+ "button_list" => "Listar",
+ "button_edit" => "Editar",
+ "button_report" => "Reporte",
+ "button_done" => "Finalizar",
+ "modal_survey" => "Seleccionar Encuesta",
+ "modal_button_close"=> "Cerrar",
+];
\ No newline at end of file
diff --git a/resources/lang/es/layout.php b/resources/lang/es/layout.php
new file mode 100644
index 0000000..308f932
--- /dev/null
+++ b/resources/lang/es/layout.php
@@ -0,0 +1,6 @@
+ "Panel de Empresas",
+ "menu_complete" => "Completar",
+ "menu_report" => "Reporte",
+];
\ No newline at end of file
diff --git a/resources/lang/es/pagination.php b/resources/lang/es/pagination.php
index fcab34b..325916d 100644
--- a/resources/lang/es/pagination.php
+++ b/resources/lang/es/pagination.php
@@ -13,7 +13,7 @@
|
*/
- 'previous' => '« Previous',
- 'next' => 'Next »',
+ 'previous' => '« Anterior',
+ 'next' => 'Siguiente »',
];
diff --git a/resources/lang/es/reportFilter.php b/resources/lang/es/reportFilter.php
new file mode 100644
index 0000000..1ad7696
--- /dev/null
+++ b/resources/lang/es/reportFilter.php
@@ -0,0 +1,10 @@
+ "Filtrar Cargo",
+ "label_level" => "Nivel",
+ "label_position" => "Cargo",
+ "label_description" => "Descripcion del Cargo",
+ "button_report" => "Reporte",
+ "select_option" => "Elija una Opción",
+ "select_level" => "Elija una Opción",
+];
\ No newline at end of file
diff --git a/resources/lang/es/reportLayout.php b/resources/lang/es/reportLayout.php
new file mode 100644
index 0000000..1f2dd5e
--- /dev/null
+++ b/resources/lang/es/reportLayout.php
@@ -0,0 +1,11 @@
+ "Panel",
+ "menu_concepts" => "Conceptos Técnicos",
+ "menu_methodology" => "Metodología",
+ "menu_sheet" => "Ficha Técnica",
+ "menu_indicators" => "Indicadores por Cargo",
+ "menu_search" => "Buscar por Cargo",
+ "menu_universe" => "Universo de Cargos",
+ "menu_attachment" => "Archivo Adjunto"
+];
\ No newline at end of file
diff --git a/resources/lang/es/reportPanel.php b/resources/lang/es/reportPanel.php
new file mode 100644
index 0000000..22b5a7c
--- /dev/null
+++ b/resources/lang/es/reportPanel.php
@@ -0,0 +1,10 @@
+ "Id",
+ "table_description" => "Descripcion",
+ "table_branches" => "Cant. Sucursales",
+ "table_employees" => "Cant. Empleados",
+ "table_origin" => "Origen",
+ "label_origin_national" => "Nacional",
+ "label_origin_international" => "Internacional",
+];
\ No newline at end of file
diff --git a/resources/lang/es/reportReport.php b/resources/lang/es/reportReport.php
new file mode 100644
index 0000000..327460e
--- /dev/null
+++ b/resources/lang/es/reportReport.php
@@ -0,0 +1,49 @@
+ "Ver en GS.",
+ "button_currency_us" => "Ver en U\$D.",
+ "p_currency_gs" => "Los montos están en miles de Guaraníes",
+ "p_currency_us" => "Los montos están en Dólares Americanos",
+ "label_tab_universe" => "Universo",
+ "label_tab_national" => "Nacional",
+ "label_tab_international" => "Internacional",
+ "table_concepts" => "Conceptos",
+ "table_cases" => "Casos",
+ "table_occupants" => "Ocupantes",
+ "table_min" => "Mínimo",
+ "table_perc25" => "25 Perc.",
+ "table_average" => "Promedio",
+ "table_median" => "Mediana",
+ "table_perc75" => "75 Perc.",
+ "table_max" => "Máximo",
+ "table_company" => "Su Compañía",
+ "table_avg_compare" => "Comparación Promedio",
+ "table_median_compare" => "Comparación Mediana",
+ "table_perc75_compare" => "Comparación 75 Percentil",
+ "table_max_compare" => "Comparación Máximo",
+ "title_universe" => "Universo",
+ "title_national" => "Nacional",
+ "title_international" => "Internacional",
+ "chart_salary" => "Salario Base",
+ "chart_annual_cash" => "Efectivo Anual Garantizado",
+ "chart_total_comp" => "Compensación Anual Total",
+ "concept_salary" => "Salario Base",
+ "concept_annual_salary" => "Salario Base Anual",
+ "concept_annual_gratif." => "Gratificación Anual Garantizada",
+ "concept_13month" => "Aguinaldo",
+ "concept_annual_cash" => "Efectivo Anual Garantizado",
+ "concept_total_incentives" => "Total Adicional Anual",
+ "concept_bonus" => "Bono Anual",
+ "concept_13month_impacted" => "Aguinaldo Impactado por Adicional, Gratificación y Bono",
+ "concept_total_compensation"=> "Compensación Anual Total",
+ "concept_variable_pay" => "Variable Anual",
+ "concept_mooring" => "Adicional por Amarre",
+ "concept_fuel_type" => "Adicional por Tipo de Combustible",
+ "concept_shipping" => "Adicional por Disponibilidad/Emarque",
+ "concept_load" => "Adicional por Carga",
+ "concept_total_benefits" => "Total Beneficios Anual",
+ "concept_annual_cash_total" => "Efectivo Total Anual",
+ "concept_annual_commission" => "Comisión Anual",
+ "concept_total_additional" => "Total Adicional Anual",
+
+];
\ No newline at end of file
diff --git a/resources/lang/es/reportThecnicalSheet.php b/resources/lang/es/reportThecnicalSheet.php
new file mode 100644
index 0000000..c8b1775
--- /dev/null
+++ b/resources/lang/es/reportThecnicalSheet.php
@@ -0,0 +1,8 @@
+ "Fecha/Corte",
+ "tab_label_jobs" => "Casos Emergentes",
+ "tab_label_panel" => "Participantes N°",
+ "tab_label_exchange" => "Tipo de Cambio",
+
+];
\ No newline at end of file
diff --git a/resources/views/auth/login.blade.php b/resources/views/auth/login.blade.php
index 9e44b06..2d4ce48 100644
--- a/resources/views/auth/login.blade.php
+++ b/resources/views/auth/login.blade.php
@@ -9,12 +9,11 @@
@endsection
+
diff --git a/resources/views/beneficios_admin/create.blade.php b/resources/views/beneficios_admin/create.blade.php
index 1d7757e..9e688fd 100644
--- a/resources/views/beneficios_admin/create.blade.php
+++ b/resources/views/beneficios_admin/create.blade.php
@@ -24,7 +24,7 @@
diff --git a/resources/views/beneficios_report/charts.blade.php b/resources/views/beneficios_report/charts.blade.php
index c5572d2..6e4237d 100644
--- a/resources/views/beneficios_report/charts.blade.php
+++ b/resources/views/beneficios_report/charts.blade.php
@@ -5,13 +5,13 @@
@@ -41,7 +41,7 @@
-
diff --git a/resources/views/beneficios_report/index.blade.php b/resources/views/beneficios_report/index.blade.php
index bb862ad..441e9c6 100644
--- a/resources/views/beneficios_report/index.blade.php
+++ b/resources/views/beneficios_report/index.blade.php
@@ -5,10 +5,10 @@
@@ -23,12 +23,12 @@
@endif
-
Listado de Indicadores
+
@lang('beneficiosReportIndex.title_list')
-
+
@foreach ($dbCategorias as $element)
-
+
@@ -39,7 +39,7 @@