fix: fixes to allergy card in patient summary (#6863)
[openemr.git] / src / Common / Layouts / LayoutsUtils.php
blobe12af1b6b69e38713ec7a6a2bf19aab63e1f4f5b
1 <?php
3 /**
4 * LayoutsUtils class.
6 * @package OpenEMR
7 * @link https://www.open-emr.org
8 * @author Brady Miller <brady.g.miller@gmail.com>
9 * @copyright Copyright (c) 2023 Brady Miller <brady.g.miller@gmail.com>
10 * @license https://github.com/openemr/openemr/blob/master/LICENSE GNU General Public License 3
13 namespace OpenEMR\Common\Layouts;
15 class LayoutsUtils
17 public static function getListItemTitle($list, $option)
19 $row = sqlQuery("SELECT `title` FROM `list_options` WHERE `list_id` = ? AND `option_id` = ? AND activity = 1", [$list, $option]);
20 if (empty($row['title'])) {
21 return $option;
23 return xl_list_label($row['title']);