Prefer English food_desc for CarePlan dietary advice in FHIR bundle

This commit is contained in:
DevSoftTech Server 2026-10-17 02:49:28 +05:30
parent 8a0396a2c8
commit 0af2d557b2
2 changed files with 4 additions and 4 deletions

View File

@ -3607,9 +3607,9 @@ class AbdmGateway extends BaseController
$dietParts = [];
foreach ($foodRows as $fRow) {
$heading = trim((string) ($fRow['food_short'] ?? ''));
$line = trim((string) ($fRow['food_desc_lang'] ?? ''));
$line = trim((string) ($fRow['food_desc'] ?? ''));
if ($line === '') {
$line = trim((string) ($fRow['food_desc'] ?? ''));
$line = trim((string) ($fRow['food_desc_lang'] ?? ''));
}
if ($heading !== '' && $line !== '') {
$dietParts[] = $heading . ': ' . $line;

View File

@ -9612,9 +9612,9 @@ class Ipd_discharge extends BaseController
$dietParts = [];
foreach ($foodRows as $fRow) {
$heading = trim((string) ($fRow['food_short'] ?? ''));
$line = trim((string) ($fRow['food_desc_lang'] ?? ''));
$line = trim((string) ($fRow['food_desc'] ?? ''));
if ($line === '') {
$line = trim((string) ($fRow['food_desc'] ?? ''));
$line = trim((string) ($fRow['food_desc_lang'] ?? ''));
}
if ($heading !== '' && $line !== '') {
$dietParts[] = $heading . ': ' . $line;