2024-08-27 20:57:11 -03:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Http\Controllers;
|
|
|
|
|
|
|
|
use App\GrupoDeCompra;
|
|
|
|
|
|
|
|
class ComprasController
|
|
|
|
{
|
2024-09-17 20:41:50 -03:00
|
|
|
public function indexPedidos() {
|
|
|
|
return view('compras_pedidos');
|
|
|
|
}
|
|
|
|
|
|
|
|
public function descargarPedidos() {
|
2024-08-27 20:57:11 -03:00
|
|
|
GrupoDeCompra::exportarTodosLosPedidosEnCSV();
|
|
|
|
$file = resource_path('csv/exports/total-pedidos.csv');
|
|
|
|
return response()->download($file);
|
|
|
|
}
|
2024-10-15 20:44:28 -03:00
|
|
|
|
|
|
|
public function descargarNotas() {
|
|
|
|
GrupoDeCompra::exportarProductosConNotasEnCSV();
|
|
|
|
$file = resource_path('csv/exports/pedidos-notas.csv');
|
|
|
|
return response()->download($file);
|
|
|
|
}
|
2024-09-10 21:11:22 -03:00
|
|
|
|
2024-09-14 13:37:06 -03:00
|
|
|
public function show()
|
2024-09-10 21:11:22 -03:00
|
|
|
{
|
|
|
|
return view('auth/compras_login');
|
|
|
|
}
|
2024-08-27 20:57:11 -03:00
|
|
|
}
|