fix(helpdesk): fix user-select empty options — use nested row structure fallback
DB::select with JOIN returns rows as $u['u']['field'] ?? $u['field']. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -79,9 +79,9 @@ $hasDiff = $fieldDiff !== [];
|
||||
<?php if ($readonly): ?> disabled<?php endif; ?>
|
||||
>
|
||||
<?php foreach ($tenantUsers as $u):
|
||||
$uId = (string) ($u['id'] ?? '');
|
||||
$uName = trim((string) ($u['display_name'] ?? ''));
|
||||
$uEmail = (string) ($u['email'] ?? '');
|
||||
$uId = (string) ($u['u']['id'] ?? $u['id'] ?? '');
|
||||
$uName = trim((string) ($u['u']['display_name'] ?? $u['display_name'] ?? ''));
|
||||
$uEmail = (string) ($u['u']['email'] ?? $u['email'] ?? '');
|
||||
$uLabel = $uName !== '' ? $uName : $uEmail;
|
||||
?>
|
||||
<option value="<?php e($uId); ?>"<?php if (in_array($uId, $selectedIds, true)): ?> selected<?php endif; ?>>
|
||||
|
||||
Reference in New Issue
Block a user