return executed;
}
@Override
public List<Voo> consultar(RequestParam request) {
Status status = request.enumParam(Status.class, "status");
DateTime partida = request.dateTimeParam("partida");
DateTime chegada = request.dateTimeParam("chegada");
String origem = request.stringParam("origem");
String destino = request.stringParam("destino");
Integer assento = request.intParam("assento");
return query()
.with("where 1 = 1")
.with("and VOO.STATUS = ?", status.ordinal())
.with("and VOO.DATA_PARTIDA >= ?", partida)
.with("and VOO.DATA_CHEGADA <= ?", chegada)
.with("and VOO.ORIGEM like concat ('%', ?, '%')", origem)
.with("and VOO.DESTINO like concat ('%', ?, '%')", destino)
.with("and VOO.ASSENTO_LIVRE > ?", assento)