'datetime', 'fecha_fin_vigencia' => 'datetime', ]; public static function selectList($c_estado, $c_localidad = false) { return self::select('c_localidad', 'descripcion') ->where('c_estado', $c_estado) ->when($c_localidad, function ($query) use ($c_localidad) { $query->where('c_localidad', $c_localidad); }) ->orderBy('descripcion') ->pluck('descripcion', 'c_localidad'); } }