diff --git a/controllers/receiveds.php b/controllers/receiveds.php index a50d0c6..bb2854f 100755 --- a/controllers/receiveds.php +++ b/controllers/receiveds.php @@ -67,6 +67,16 @@ global $db; $now = new DateTime(); $receiveds = $db->getReceivedsSince($now->format('Y-m-d')); + + foreach ($receiveds as $key => $received) + { + if (!$contacts = $db->getFromTableWhere('contacts', ['number' => $received['send_by']])) + { + continue; + } + + $receiveds[$key]['send_by'] = $contacts[0]['name'] . ' (' . $received['send_by'] . ')'; + } $nbReceiveds = count($receiveds);