Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix fatal error on inline profile block #145

Merged
merged 1 commit into from
Jun 4, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 2 additions & 5 deletions templates/CRM/Contactlayout/Form/Inline/ProfileBlock.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,9 @@
{strip}
<table class="form-layout-compressed">
<tr>
{* sort by fails for option per line. Added a variable to iterate through the element array*}
{assign var="index" value="1"}
{foreach name=outer key=key item=item from=$form.$n}
{if $index < 10}
{assign var="index" value=$index+1}
{else}
{* There are both numeric and non-numeric keys mixed in here, where the non-numeric are metadata that aren't arrays with html members. *}
{if is_array($item) && array_key_exists('html', $item)}
<td class="labels font-light">{$form.$n.$key.html}</td>
{if $count == $field.options_per_line}
</tr>
Expand Down