COF #10011 / IDEMPIERE-4033 - avoiding NPE in ZkJRViewer

This commit is contained in:
matheus.marcelino 2019-08-22 11:19:40 -03:00
parent 2c051e5de8
commit 87703ab73a
1 changed files with 1 additions and 1 deletions

View File

@ -134,7 +134,7 @@ public class ZkJRViewer extends Window implements EventListener<Event>, ITabOnCl
private void init() {
final boolean isCanExport=MRole.getDefault().isCanExport();
defaultType = jasperPrint.getProperty("IDEMPIERE_REPORT_TYPE");
defaultType = jasperPrint == null ? null : jasperPrint.getProperty("IDEMPIERE_REPORT_TYPE");
if (Util.isEmpty(defaultType)) {
defaultType = MSysConfig.getValue(MSysConfig.ZK_REPORT_JASPER_OUTPUT_TYPE, "PDF",
Env.getAD_Client_ID(Env.getCtx()), Env.getAD_Org_ID(Env.getCtx()));//It gets default Jasper output type