mirror of
https://git.imnavajas.es/jjimenez/safekat.git
synced 2025-07-25 22:52:08 +00:00
Ajustado el estilo de presupuesto y añadidos envios
This commit is contained in:
@ -89,4 +89,28 @@ class PresupuestoDireccionesModel extends \App\Models\GoBaseModel
|
||||
->orLike("t1.telefono", $search)
|
||||
->groupEnd();
|
||||
}
|
||||
|
||||
/**
|
||||
* Get resource data for pdf generation.
|
||||
*
|
||||
* @param int $presupuesto_id
|
||||
*
|
||||
* @return \CodeIgniter\Database\BaseBuilder
|
||||
*/
|
||||
public function getResourceForPdf($presupuesto_id = -1)
|
||||
{
|
||||
$builder = $this->db
|
||||
->table($this->table . " t1")
|
||||
->select(
|
||||
"t1.direccion AS direccion, t2.nombre AS pais,
|
||||
t1.municipio AS municipio, t1.provincia AS provincia, t1.cp AS cp, t1.telefono AS telefono,
|
||||
t1.cantidad AS cantidad"
|
||||
);
|
||||
|
||||
$builder->where('t1.presupuesto_id', $presupuesto_id);
|
||||
$builder->join("lg_paises t2", "t1.pais_id = t2.id", "left");
|
||||
|
||||
return $builder;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user