Situation
I’ve developed a custom form (nieuw_consult
) in OpenEMR that saves data correctly and appears in the UI as expected. However, the form summary view fails with the following recurring error:
pgsql
CopyEdit
OpenEMR\COMMON\Forms\FormReportRenderer->renderReport() form is missing report function {"formdir":"nieuw_consult","formId":"X"}
Even though the report()
function is defined in report.php
, and return true;
is placed at the end of the file (outside any function), the system does not recognize it. I have confirmed there is no HTML or output outside the report()
function. Permissions are set correctly (644
, owned by www-data
), and the form is enabled and registered.
The issue persists even after clearing browser cache and reloading OpenEMR. I’m wondering if this may be due to internal caching, missing re-registration, or another requirement not documented in the form development guide.
Could the team clarify:
- Are there hidden requirements for OpenEMR to recognize
report()
in custom forms? - Does a modified
report.php
require manual re-registration of the form? - Are there logs or diagnostics specific to
FormReportRenderer
that I can check?
OpenEMR Version
I’m using OpenEMR version: 7.0.2-dev (latest master as of May 2025)
Browser
I’m using: Google Chrome Version 124.0.6367.61 (Official Build) (64-bit)
Operating System
I’m using: Ubuntu 22.04 LTS (Running locally on Apache with PHP 8.1)
Search
Yes, I searched the forum and GitHub issues for similar cases. I found references to report()
but no clear solution to this exact issue.
Logs
Yes, I checked the logs. Here’s the relevant error:
css
CopyEdit
[2025-05-05T19:29:09.147064+00:00] OpenEMR.ERROR: OpenEMR\Common\Forms\FormReportRenderer->renderReport() form is missing report function {"formdir":"nieuw_consult","formId":"30"}
Let me know if there’s any additional diagnostic I should enable or if you need my full report.php
for context. I’d appreciate any guidance or clarification.
Best regards,
Henry Wielzen
Urology Resident