Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ->addSelect('v')
- ->distinct()
- ->from('Entidades:Viaje', 'v')
- ->innerJoin('v.estadoViaje', 'ev')
- ->innerJoin('v.trayectos', 't')
- ->innerJoin('t.datosTrayecto', 'dt')
- ->innerJoin('dt.estadoTrayecto', 'et')
- //->innerJoin('v.viajesRutaEmpresa', 'vre')
- ->innerJoin('v.rutaEmpresa', 're')
- ->innerJoin('re.empresaSeccion', 'es')
- ->innerJoin('re.ruta', 'r')
- ->innerJoin('t.origen', 'l')
- ->where('es.id = :idEmpresaSeccion')
- ->andWhere('l.id = :idLugar')
- ->andWhere('ev.codigo <> :finalizado')
- ->andWhere('ev.codigo <> :cancelado')
- ->andWhere('et.codigo <> :carretera')
- ->andWhere('v.codigo LIKE :filtroViaje')
- ->andWhere('r.nombre LIKE :filtroRuta')
- ->setParameter('idEmpresaSeccion', $idEmpresaSeccion)
- ->setParameter('idLugar', $idLugar)
- ->setParameter('finalizado', "finalizado")
- ->setParameter('cancelado', "cancelado")
- ->setParameter('carretera', "carretera")
- ->setParameter('filtroViaje', "%" . $filtroViaje . "%")
- ->setParameter('filtroRuta', "%" . $filtroRuta . "%")
- ->orderBy("ev.codigo","ASC")
- ->addOrderBy("v.id", "ASC")
Add Comment
Please, Sign In to add comment