I have the following foreach in the controller
for(Paquete p: listaPaquetes){
entregablePaquete = entregableDao.listaEntregablePaquete(p.getIdPaquete());
map.put("entregablePaquete"+p.getIdPaquete(), entregablePaquete);
}
and I have problems accessing the object "deliverablePackage" + p.getIdPackage () from the view, I have tried to do it in the following way in the view
<c:forEach var="paquetes" items="${listaPaquetes}" varStatus="status">
<c:set var="id" value="${paquetes.idPaquete}"/>
<c:forEach var="entregable" items="${entregablePaquete}${id}" varStatus="status">
${entregable.nombre}
</c:forEach>
</c:forEach>
but it results in keeping "deliverable" simply the value of the id and does not access the other elements, the only way in which I can do it correctly is defining the value of the id in foreach items, which is not viable because it does not I'm going to know that id always
<c:forEach var="entregable" items="${entregablePaquete18}" varStatus="status">
${entregable.nombre}
</c:forEach>