Skip to content

Feature search does not use the tooltip or reference relation descriptions in fields #4263

@SrNetoChan

Description

@SrNetoChan

Description

While Mergin Maps mobile shows map tooltips in the layer's feature list, the search functionality seems to ignore it and just search on searchable fields. If the tool tip is composed only by fields from that table this shouldn't be a problem, but when you have relation references to other layers, the tooltip can be composed by fields of the related layer (using represent_value()), and that's where it fails.

I will use the following image as an example.

Image

The tooltip for this layer is the following expression:

represent_value("ug_id") || ' - ' || concat("codigo", ' - ' || "nome_propriedade" )

If I search for "Cadoiços" the results list gets empty, because that string in the first feature actually comes from another table.

Search works if I search for strings in the "codigo" and "nome_propriedade" fields, and the ID number in the "ug_id", but not on the result of represent_value("ug_id") which returns the description from the existing relation reference with another table. Which becomes quite confusing for users.

The workaround I found was to create a virtual field with the expression represent_value("ug_id") and made it searchable. It would be more user frinedly if search functionality also search on the tooltip for results.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions