jmix-framework / jmix

Jmix framework
https://www.jmix.io
Apache License 2.0
559 stars 118 forks source link

Problem with creating dynamic attribute of 'entity' type #3632

Open fractal3000 opened 1 month ago

fractal3000 commented 1 month ago

Environment

Jmix version: 2.3.2

Bug Description

There is a problem with creating dynamic attribute of "Entity" type with default value. There is an unexpected error when user is trying to set up the visibility settings for attribute.

Steps To Reproduce

  1. Create project with two entities (FirstEntity and SecondEntity)
  2. Create list and detail views for both of them
  3. Add Dynamic Attributes Facet to all views of FirstEntity
  4. Create some objects of SecondEntity
  5. Create dynamic attribute of "Entity" type for FirstEntity
  6. Select SecondEntity as a class for the attribute and SecondEntity.list screen as a lookup screen.
  7. Select default value for the attribute image

In addition it is necessary to check case with setting SecondEntity(the same as base entity with attributes) as a class for "Entity" attribute.

  1. Go to visibility tab.

Current Behavior

An anexpected error is encountered. image

Expected Behavior

Ability to set up screens for attribute is available.

Sample Project

DynamicAttirubeSample_2_3_999.zip

Gavrilov-Ivan commented 1 month ago

Maybe the same root cause - https://github.com/jmix-framework/jmix/issues/3636