Issue maintenance script brought in by PR#1081 seems to have a feature to reference related encounters(?) or a specific form. However the query silently fails as forms.issue_id table is missing.
... ... ... // Build html tab data for each visit form linked to this issue. $tabcontents = ''; if ($issue) { $vres = sqlStatement( "SELECT f.id, f.encounter, f.form_name, f.form_id, f.formdir, fe.date " . "FROM forms AS f, form_encounter AS fe WHERE " . "f.pid = ? AND f.issue_id = ? AND f.deleted = 0 AND " . "fe.pid = f.pid and fe.encounter = f.encounter " . "ORDER BY fe.date DESC, f.id DESC", array($thispid, $issue) ); while ($vrow = sqlFetchArray($vres)) { $formdir = $vrow['formdir']; ... ... ...
Any idea if the feature would be usable in standard code?