-
-
Notifications
You must be signed in to change notification settings - Fork 825
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
CRM-21125 allow class assignment on report row links #10922
Conversation
<td class="crm-report-{$field}{if $header.type eq 1024 OR $header.type eq 1 OR $header.type eq 512} report-contents-right{elseif $row.$field eq 'Subtotal'} report-label{/if}"> | ||
{if $row.$fieldLink} | ||
<a title="{$row.$fieldHover}" href="{$row.$fieldLink}"> | ||
<a title="{$row.$fieldHover}" href="{$row.$fieldLink}" {if $row.$fieldClass} class="{$row.$fieldClass}"{/if}> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@eileenmcnaughton won't there always be $row.$fieldClass
so to omit IF condition, as we are already ensuring the fieldName to be present at L115?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmm but if empty it would be class="" - would that be ok?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if empty then we don't have that link at all
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So the data would look like this
$row => array(
'financial_type_id' => 'Donation',
'financial_type_id_link' => 'https....',
'contact_type' => 'Individual',
'contact_type_link' => 'https....',
'contact_type_hover' => 'Click to popup contact',
'contact_type_class' => 'crm-pop-up',
);
Tested, working fine |
thanks @monishdeb |
Assists with dedupe analysis as I am using this to provide pop-ups on analysis reports rather than forcing click throughs to see more. civicrm#10922 Change-Id: I5369a58035fef294b58c2dd1a89519c069d46443
Overview
Allows report writers to assign a class when defining a link on a cell
Before
Not possible to assign a link
After
Possible, but no change in any existing reports / behaviour. Extra steps are required in the reports themselves to leverage
Technical Details
an example usage is on JIRA