API - several records from a database with postman

0

I try to query a database using EJB using eclipse oxygen. At the time of making the request, GET , in postman, always brings me a record.

When I consult SQL, it shows me the 3 existing records.

Do you need to make a pre-request script in postman to bring those 3 records? Or do a method that returns me a list of those 3 records?

@Override 
    public PdvdetMessage llamaConsultaDetalleTicket() throws Exception {
        try { 

            PdvdetType pdvdetType = new PdvdetType();

            pdvdetType.setSucursal("001");
            pdvdetType.setFechaOperacion("20031125");
            pdvdetType.setCaja("888");
            pdvdetType.setNumeroTra("    7");  


            PdvdetMessage im = PdvdetTO.getTO(this.getNpdvBean().consultaDetalleTicket(pdvdetType));

            return im;

        } catch (BLException ex) {
            log.error(ex);
            if (ex.getError() != null && ex.getError().getCode() > ErrorCodes.BL_BASE_CODE)
                ex.getError().setMessage("Internal Error");
            throw (ex);
        } catch (Exception ex) {
            log.error(ex);
            throw new BLException(ErrorCodes.BL_BASE_CODE, "Internal Error");
        }

    }
    
asked by lealceldeiro 20.08.2018 в 17:13
source

0 answers