CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviReport (Moderator: Dave Greenberg) »
  • Unable to create report when no results found
Pages: [1]

Author Topic: Unable to create report when no results found  (Read 1095 times)

dkingofpa

  • I’m new here
  • *
  • Posts: 8
  • Karma: 0
Unable to create report when no results found
June 23, 2010, 02:25:23 pm
I'm trying to create a report from a template: Event Participant Report (List).  When I preview the report, there are no results.  Which is expected because I haven't made the event public yet.  I wanted to have the report ready to go for my customer before the event went public.

When there are no results, there is no "Create Report" link displayed.  As a result, I can't create a report from the template.  If I change the report to include participants from an earlier event, there is data listed and I can create the report from the template.  Unfortunately, I can't go and update the report criteria to show the participants for the actual event because previewing the search will just return no results and no ui element to update the report.

Is this a bug or does it "work as designed"?

petednz

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4899
  • Karma: 193
    • Fuzion
  • CiviCRM version: 3.x - 4.x
  • CMS version: Drupal 6 and 7
Re: Unable to create report when no results found
June 23, 2010, 02:26:27 pm
Yep - hit the same - seems like an oversight - i had to fire in a test participant to create the report
Sign up to StackExchange and get free expert advice: https://civicrm.org/blogs/colemanw/get-exclusive-access-free-expert-help

pete davis : www.fuzion.co.nz : connect + campaign + communicate

dkingofpa

  • I’m new here
  • *
  • Posts: 8
  • Karma: 0
Re: Unable to create report when no results found
June 23, 2010, 03:10:57 pm
Looked at the code more closely....I'm in drupal, so under the civicrm module:  templates/CRM/Report/Form/Fields.tpl is where they determine whether to show the "Create Report" link or not.  Line 19 includes reference to $rows:

Code: [Select]
{if ($instanceForm and $rows) OR $instanceFormError} {* settings section starts *}

So if there are no results, there won't be any rows and no Create Report link.  Removing $rows from that line of code makes the Create Report link display twice.  I haven't played around with it much or tested it.  Maybe this will help others.  Hopefully a civicrm dev will take notice and fix it.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviReport (Moderator: Dave Greenberg) »
  • Unable to create report when no results found

This forum was archived on 2017-11-26.