Skip to content

extractValueFromColumn should respect custom ValueProvider return value, even if null #182

@brunoagretti

Description

@brunoagretti

Describe the bug

Currently, if a custom ValueProvider is defined for a column (by calling gridExporter.setExportValue(...)) but returns null, extractValueFromColumn(...) continues trying to obtain a value from other sources (e.g. bean properties or renderers).
This prevents intentional null values used, for example, to export a blank cell in Excel from being respected.

Expected behavior

If a custom ValueProvider is present, its result should be used as is, even if it is null. The method should not fall back to other value sources.

Minimal reproducible example

No response

Add-on Version

2.5.2

Vaadin Version

24.6.6

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions