Agregado método para pedidos de ollas
This commit is contained in:
parent
f6f565b6bd
commit
bc70e28127
1 changed files with 20 additions and 0 deletions
|
@ -34,6 +34,26 @@ class PedidosExportHelper
|
|||
)
|
||||
);
|
||||
}
|
||||
/**
|
||||
* @throws InvalidArgument
|
||||
* @throws CannotInsertRecord
|
||||
* @throws Exception
|
||||
*/
|
||||
static public function pedidosDeOllas()
|
||||
{
|
||||
$filePath = "csv/exports/pedidos-de-ollas-" . now()->format('Y-m-d') . ".csv";
|
||||
$barrios = GrupoDeCompra::barriosMenosPrueba()->get();
|
||||
self::exportarCSV(
|
||||
$filePath,
|
||||
$barrios,
|
||||
self::generarContenidoCSV(
|
||||
$barrios,
|
||||
fn ($grupoId) =>
|
||||
"subpedidos.grupo_de_compra_id = $grupoId
|
||||
AND subpedidos.tipo_pedido_id = 2"
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws InvalidArgument
|
||||
|
|
Loading…
Add table
Reference in a new issue