mirror of
https://git.imnavajas.es/jjimenez/safekat.git
synced 2025-07-25 22:52:08 +00:00
Merge branch 'main' into 'mod/tarifas_clientes'
Main See merge request jjimenez/safekat!422
This commit is contained in:
@ -313,7 +313,7 @@ class PapelGenericoModel extends \App\Models\BaseModel
|
||||
}
|
||||
|
||||
|
||||
public function getPapelCliente($tipo, $is_cubierta = false, $selected_papel_id = null, $tapa_dura = null, $papel_especial = false)
|
||||
public function getPapelCliente($tipo, $is_cubierta = false, $selected_papel_id = null, $tapa_dura = null, $papel_especial = false, $POD = null)
|
||||
{
|
||||
/*
|
||||
1.-> Tipo impresion
|
||||
@ -322,6 +322,13 @@ class PapelGenericoModel extends \App\Models\BaseModel
|
||||
4.-> papeles genericos que aparecen en esos papeles impresion
|
||||
*/
|
||||
|
||||
if ($POD == true && ($tipo == 'color' || $tipo == 'negro')) {
|
||||
if($tipo == 'color')
|
||||
$tipo = 'colorhq';
|
||||
else if($tipo == 'negro')
|
||||
$tipo = 'negrohq';
|
||||
}
|
||||
|
||||
if ($selected_papel_id != null) {
|
||||
$builder = $this->db
|
||||
->table($this->table . " t1")
|
||||
@ -404,6 +411,14 @@ class PapelGenericoModel extends \App\Models\BaseModel
|
||||
if ($tipo == 'colorhq' || $tipo == 'negrohq') {
|
||||
$builder->where("t2.rotativa", 0);
|
||||
}
|
||||
else{
|
||||
if($POD == false){
|
||||
$builder->where("t2.rotativa", 1);
|
||||
}
|
||||
else if ($POD == true){
|
||||
$builder->where("t2.rotativa", 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if ($selected_papel_id != null)
|
||||
|
||||
Reference in New Issue
Block a user