Skip to content

Photo from camera or gallery not displayed in the app when photo name contains an existing field value — project created in QGIS 4.0 #4421

@IvaKuklica

Description

@IvaKuklica

Description
When a project is created in QGIS 4.0 and downloaded to a mobile device, recording a new feature and attaching a photo (from camera or gallery) results in the photo not being displayed in the mobile application. The issue is specifically linked to the photo filename being configured to include an existing field value from the feature form. The photo appears to be attached but is not rendered/displayed to the user.

Environment
[ ] Staging [x] PROD

Application (+ app version, build, operating system)
Mergin Maps Mobile App
iOS version: 26.3.881711
QGIS 4.0

Steps to reproduce

  1. In QGIS 4.0, create a project with a survey layer that includes:
    • A text or value map field (e.g. notes) with predefined values.
    • A photo attachment field configured so that the photo filename expression includes the value of the notes field (e.g. @project_folder + '/Photos/' + "notes").
  2. Save and sync the project to the server via the Mergin Maps plugin.
  3. On the mobile device, download and open the project.
  4. Create a new feature, select a value for the notes field.
  5. Attach a photo using the camera or gallery.
  6. Save the feature.
  7. Observe whether the photo is displayed in the feature form.

Actual results
The photo is not displayed in the mobile application after saving the feature. The photo field appears empty or the image is not rendered, even though a photo was attached during recording. The issue occurs when the photo filename is configured to include an existing field value from the feature form.

Expected results
The attached photo should be displayed correctly in the feature form after saving, regardless of whether the photo filename expression includes a field value. Behaviour should be consistent with projects created in QGIS 3.xx.

Screenshots or logs

ScreenRecording_03-25-2026.12-34-06_1.mp4

Conclusion
Created by Claude and supervised by a human test analyst.

Metadata

Metadata

Assignees

No one assigned

    Labels

    QGIS 4bugcameraTask relates to cameraformsrelated to attribute forms

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions