<div>Hello! </div>
<div>In my servlet :</div>
<div> </div>
<div>
<pre class="_prettyXprint">
IRunAndRenderTask task = engine.createRunAndRenderTask(reportDoc);
task.setParameterValue("production",objectMap.get("numberbso"));
task.setParameterValue("dateInvoice", objectMap.get("dateinvoice"));
task.setParameterValue("list",objectMap.get("listitems"));
task.setRenderOption(option);
task.validateParameters();
</pre>
</div>
<div> </div>
<div>parameters
production and
dateInvoice rendered in report.</div>
<div>Parameter
list does't render ( </div>
<div> </div>
<div>in serviceImpl class map :</div>
<div> </div>
<div>
<pre class="_prettyXprint">
@SuppressWarnings("MagicConstant")
public <T extends WarehouseShippingWaybill> Map<String, Object> constructBirtReportGoodsWaybill(Class<T> c, Long id) {
// some code..
WarehouseShippingWaybill waybill = getDocument(WarehouseOutgoingGoodsWaybill.class, id);
DateFormat dateFormat = new SimpleDateFormat("dd.MM.yyyy");
root.put("dateinvoice", returnStringDateFormat(dateDocument));
root.put("organization", organization);
// some code..
List<TypeService> entryInternal = returnListTableGoodsInvoice(contract, waybill.getOperationEntries(), organization);
root.put("listitems", entryInternal);
// some code..
return root;
}</pre>
</div>
<div> </div>
<div>and there is method for
entryInternal </div>
<div> </div>
<div>
<pre class="_prettyXprint">
public List<TypeService> returnListTableGoodsInvoice(Contract contract, List<WarehouseDocumentOperationEntry> warehouseItems, Organization organization) {
List<TypeService> list = new ArrayList<>();
for (WarehouseDocumentOperationEntry warehouseItem : warehouseItems) {
TypeService service = new TypeService();
String countryTitle = "";
if (warehouseItem.getItemType().getCountry() != null) {
countryTitle = dictionaryService.get(Country.class, 500l).equals(warehouseItem.getItemType().getCountry()) ? "" : ", " + warehouseItem.getItemType().getCountry().getCode();
}
service.setName(warehouseItem.getItemType().getTitle()
+ countryTitle);
service.setUnit((warehouseItem.getItemType().getUnit() != null) ? warehouseItem.getItemType().getUnit().getDescription() : "");
service.setNumber(warehouseItem.getAmount());
BigDecimal vat = new BigDecimal(0);
// some code
service.setLoadWeight(warehouseItem.getAmount().multiply(warehouseItem.getItemType().getNetWeight()).setScale(3, RoundingMode.HALF_UP));
}
list.add(service);
}
return list;
}</pre>
</div>
<div> </div>
<div> </div>
<div>in report I'm trying get it with Report Parameters </div>
<div><img src="
http://i.imgur.com/BdtcfAQ.png" alt="BdtcfAQ.png"></div>
<div> </div>
<div>but something wrong and it's dose't work .</div>
<div> </div>