Se agregan archivos a todo lo modificable
This commit is contained in:
@ -9,7 +9,6 @@ use Carbon\Carbon;
|
||||
|
||||
class Base {
|
||||
public function __invoke(Request $request, Response $response, View $view, Container $container) {
|
||||
$aviso = true;
|
||||
$filename = implode(DIRECTORY_SEPARATOR, [
|
||||
$container->get('folders.data'),
|
||||
'avisos.json'
|
||||
@ -32,7 +31,12 @@ class Base {
|
||||
}
|
||||
$item->imagen = '<img src="' . $container->get('urls')->images . '/' . $item->imagen . '" />';
|
||||
});
|
||||
$filename = implode(DIRECTORY_SEPARATOR, [
|
||||
$container->get('folders.data'),
|
||||
'resumen.json'
|
||||
]);
|
||||
$resumen = json_decode(trim(file_get_contents($filename)));
|
||||
$indicadores = ['uf' => 'UF', 'euro' => 'Euro', 'imacec' => 'IMACEC', 'dolar' => 'USD', 'ipc' => 'IPC', 'utm' => 'UTM', 'bitcoin' => 'BitCoin', 'libra_cobre' => 'Lb. Cu'];
|
||||
return $view->render($response, 'home', compact('aviso', 'avisos', 'destacados', 'segmentos', 'indicadores'));
|
||||
return $view->render($response, 'home', compact('aviso', 'avisos', 'destacados', 'segmentos', 'resumen', 'indicadores'));
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user