Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
CiviCRM Core
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container Registry
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Development
CiviCRM Core
Commits
1c46a84c
Commit
1c46a84c
authored
5 years ago
by
yashodha
Browse files
Options
Downloads
Patches
Plain Diff
(
#959
) Expose contribution page in Contribution Summary report
parent
f3171f18
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
CRM/Report/Form/Contribute/Summary.php
+21
-0
21 additions, 0 deletions
CRM/Report/Form/Contribute/Summary.php
with
21 additions
and
0 deletions
CRM/Report/Form/Contribute/Summary.php
+
21
−
0
View file @
1c46a84c
...
...
@@ -133,6 +133,9 @@ class CRM_Report_Form_Contribute_Summary extends CRM_Report_Form {
'required'
=>
TRUE
,
'no_display'
=>
TRUE
,
),
'contribution_page_id'
=>
array
(
'title'
=>
ts
(
'Contribution Page'
),
),
'total_amount'
=>
array
(
'title'
=>
ts
(
'Contribution Amount Stats'
),
'default'
=>
TRUE
,
...
...
@@ -157,6 +160,12 @@ class CRM_Report_Form_Contribute_Summary extends CRM_Report_Form {
'default'
=>
array
(
1
),
'type'
=>
CRM_Utils_Type
::
T_INT
,
),
'contribution_page_id'
=>
array
(
'title'
=>
ts
(
'Contribution Page'
),
'operatorType'
=>
CRM_Report_Form
::
OP_MULTISELECT
,
'options'
=>
CRM_Contribute_PseudoConstant
::
contributionPage
(),
'type'
=>
CRM_Utils_Type
::
T_INT
,
),
'currency'
=>
array
(
'title'
=>
ts
(
'Currency'
),
'operatorType'
=>
CRM_Report_Form
::
OP_MULTISELECT
,
...
...
@@ -215,6 +224,12 @@ class CRM_Report_Form_Contribute_Summary extends CRM_Report_Form {
'default'
=>
array
(
1
),
'type'
=>
CRM_Utils_Type
::
T_INT
,
),
'contribution_page_id'
=>
array
(
'title'
=>
ts
(
'Contribution Page'
),
'operatorType'
=>
CRM_Report_Form
::
OP_MULTISELECT
,
'options'
=>
CRM_Contribute_PseudoConstant
::
contributionPage
(),
'type'
=>
CRM_Utils_Type
::
T_INT
,
),
),
),
'civicrm_financial_trxn'
=>
array
(
...
...
@@ -847,6 +862,7 @@ ROUND(AVG({$this->_aliases['civicrm_contribution_soft']}.amount), 2) as civicrm_
public
function
alterDisplay
(
&
$rows
)
{
$entryFound
=
FALSE
;
$contributionStatus
=
CRM_Contribute_PseudoConstant
::
contributionStatus
();
$contributionPages
=
CRM_Contribute_PseudoConstant
::
contributionPage
();
foreach
(
$rows
as
$rowNum
=>
$row
)
{
// make count columns point to detail report
...
...
@@ -936,6 +952,11 @@ ROUND(AVG({$this->_aliases['civicrm_contribution_soft']}.amount), 2) as civicrm_
$entryFound
=
TRUE
;
}
if
(
$value
=
CRM_Utils_Array
::
value
(
'civicrm_contribution_contribution_page_id'
,
$row
))
{
$rows
[
$rowNum
][
'civicrm_contribution_contribution_page_id'
]
=
$contributionPages
[
$value
];
$entryFound
=
TRUE
;
}
// If using campaigns, convert campaign_id to campaign title
if
(
array_key_exists
(
'civicrm_contribution_campaign_id'
,
$row
))
{
if
(
$value
=
$row
[
'civicrm_contribution_campaign_id'
])
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment