3.9.3. Entity Inspector

The entity inspector enables working with any application objects without having to create dedicated screens. The inspector dynamically generates the screens to browse and edit the instances of the selected entity.

This gives the system administrator an opportunity to review and edit the data that is not accessible from standard screens due to their design, and to create the data model and main menu sections linked to the entity inspector only, at prototyping stage.

The entry point for the inspector is the com/haulmont/cuba/gui/app/core/entityinspector/entity-inspector-browse.xml screen.

If a String-type parameter named entity with an entity name has been passed to the screen, the inspector will show a list of entities with the abilities for filtering, selection and editing. The parameter can be specified when registering the screen in screens.xml, for example:


<screen id="sales$Product.lookup"
  <param name="entity"


<item id="sales$Product.lookup"/>

Screen identifier defined as {entity_name}.lookup allows PickerField and LookupPickerField components to use this screen within the PickerField.LookupAction standard action.

Generally, the screen may be called without any parameters. In this case, the top part will contain an entity selection field. In the cuba application component, the inspector screen is registered with the entityInspector.browse identifier, so it can be simply referenced in a menu item:

<item id="entityInspector.browse"/>
Export and Import Using the Entity Inspector

Using the Entity Inspector, you can export and import any of the simple entities, including the system entities(for example, scheduled tasks, locks).

After selecting the entity type, the Entity Inspector screen displays actions for exporting the selected entity instances as ZIP or JSON and importing them to the system (using the Export/Import buttons).

Keep in mind that when an entity is exported using the Entity Inspector, reference attributes with the one-to-many or many-to-many relationship type cannot be exported. Import and export using the Entity Inspector work for simple cases, but if you need to export complex object graphs, you’ll have to do in your application using the EntityImportExportService.