cuba-platform / reports

CUBA Reports Addon
https://www.cuba-platform.com/
Apache License 2.0
9 stars 4 forks source link

NPE occurs after running the table report for the Role type #245

Closed MikhailSilk closed 4 years ago

MikhailSilk commented 4 years ago

Environment

Description of the bug or enhancement

  1. Create any role
  2. Start to create a new report for the Role entity
  3. Select the table template type and click Next
  4. Select the Role.type attribute and save the report
  5. Run the report for the created role from the previous step

AR: NPE occurs

java.lang.NullPointerException
at com.haulmont.chile.core.datatypes.impl.EnumerationImpl.parse(EnumerationImpl.java:58)
at com.haulmont.chile.core.datatypes.impl.EnumerationImpl.parse(EnumerationImpl.java:27)
at com.haulmont.cuba.core.entity.KeyValueEntity.getValue(KeyValueEntity.java:105)
at com.haulmont.chile.core.model.utils.InstanceUtils.getValueEx(InstanceUtils.java:134)
at com.haulmont.chile.core.model.impl.AbstractInstance.getValueEx(AbstractInstance.java:172)
at com.haulmont.cuba.gui.components.data.table.DatasourceTableItems.getItemValue(DatasourceTableItems.java:119)
at com.haulmont.cuba.web.gui.components.table.TableItemWrapper.getPropertyValue(TableItemWrapper.java:74)
at com.haulmont.cuba.web.gui.components.table.TableItemPropertyWrapper.getValue(TableItemPropertyWrapper.java:34)
at com.haulmont.cuba.web.gui.components.WebAbstractTable.formatCellValue(WebAbstractTable.java:1162)
at com.haulmont.cuba.web.widgets.CubaTable.formatPropertyValue(CubaTable.java:344)
at com.haulmont.cuba.web.widgets.CubaTable.getPropertyValue(CubaTable.java:260)
at com.vaadin.v7.ui.Table.parseItemIdToCells(Table.java:2355)
at com.vaadin.v7.ui.Table.getVisibleCellsNoCache(Table.java:2203)
at com.vaadin.v7.ui.Table.refreshRenderedCells(Table.java:1746)
at com.haulmont.cuba.web.widgets.CubaGroupTable.refreshRenderedCells(CubaGroupTable.java:751)
at com.vaadin.v7.ui.Table.attach(Table.java:4260)
at com.vaadin.server.AbstractClientConnector.attach(AbstractClientConnector.java:643)
at com.vaadin.ui.AbstractComponent.attach(AbstractComponent.java:670)
at com.vaadin.server.AbstractClientConnector.attach(AbstractClientConnector.java:643)
at com.vaadin.ui.AbstractComponent.attach(AbstractComponent.java:670)
at com.vaadin.server.AbstractClientConnector.attach(AbstractClientConnector.java:643)
at com.vaadin.ui.AbstractComponent.attach(AbstractComponent.java:670)
at com.vaadin.server.AbstractClientConnector.attach(AbstractClientConnector.java:643)
at com.vaadin.ui.AbstractComponent.attach(AbstractComponent.java:670)
at com.vaadin.server.AbstractClientConnector.attach(AbstractClientConnector.java:643)
at com.vaadin.ui.AbstractComponent.attach(AbstractComponent.java:670)
at com.vaadin.ui.AbstractComponent.setParent(AbstractComponent.java:571)
at com.vaadin.ui.Window.setParent(Window.java:182)
at com.vaadin.ui.UI.attachWindow(UI.java:561)
at com.vaadin.ui.UI.addWindow(UI.java:550)
NikitaShchienko commented 4 years ago

Fixed in #237