Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-6704

Allow statistics on custom fields in CiviReport

    Details

    • Type: Improvement
    • Status: Done/Fixed
    • Priority: Major
    • Resolution: Won't Fix
    • Affects Version/s: 3.2.1
    • Fix Version/s: 3.3.alpha
    • Component/s: CiviReport
    • Labels:
      None

      Description

      Currently it's very difficult to run statistics on custom fields (similar to the total_amount statistics in the donor summary report). This is because when the CRM_Report_Form constructor adds custom field groups, it clobbers any statistic fields you may have setup in the custom report class. But you can't set it up after that constructor runs because it also creates the template variables for which fields show up in the report criteria, etc.

      I've attached a simple patch that fixes this issue. It won't clobber any existing custom fields added to the _columns array. This change was necessary to implement the UK Green Party custom reports. It would be great if it could go into core so we don't have to maintain a delta and so others can pull this off in the future.

      Patch is diffed against trunk on Aug. 22, 2010.

        Attachments

          Activity

            People

            • Assignee:
              rajan Rajan P Mayekar
              Reporter:
              cap10morgan Wes Morgan
            • Votes:
              1 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: