This commit is contained in:
Dasc3er 2020-11-10 19:04:37 +01:00
parent a574112f4e
commit 606cd88857
1 changed files with 1 additions and 1 deletions

View File

@ -83,7 +83,7 @@ class Anagrafica extends Model
public static function fromTipo($type)
{
$tipologia = Tipo::where('descrizione', 'Tecnico')->first();
$tipologia = Tipo::where('descrizione', $type)->first();
$anagrafiche = self::whereHas('tipi', function ($query) use ($tipologia) {
$query->where('an_tipianagrafiche.idtipoanagrafica', '=', $tipologia->id);