courtly
courtly
courtly
courtly

Upcoming Events

London user and administrator training
February 23rd, 2012
A comprehensive two day hands on training course covering the configuration, (more...)

CiviCRM Seminar - London
February 23rd, 2012
NfP Services free seminar

NYC CiviCRM MeetUp Thursday February 23, 2012
February 23rd, 2012
Reminder NYC CiviCRM meetup 5:30-7:30 Thursday, February 23.

CiviCRM London sprint Feb 2012
February 27th, 2012
Following the CiviCRM training here in London, we will have a CiviCRM code (more...)

Austin CiviCRM Meetup March 8, 2012 6:30pm
March 8th, 2012

Philadelphia - CiviCRM Meetup for Q1 2012
March 13th, 2012

UK South West - CiviCRM Meetup
March 20th, 2012
Come meet others from the Area who are interested in, using or developing for (more...)

[Bristol, UK] user and administrator training
March 21st, 2012
A comprehensive hands on training course covering the configuration, (more...)

San Francisco user and administrator training
March 29th, 2012
A comprehensive two day hands on training course covering the configuration, (more...)

CiviCRM Usability, Test and Code Sprint - San Francisco (March 2012)
March 29th, 2012
This usability, code and test sprint is targeted at CiviCRM users and (more...)

CiviCon 2012 San Francisco Bay Area - April 2nd 2012
April 2nd, 2012
CiviCon is THE annual event bringing together the people who use, develop, (more...)

CiviCRM Documentation, Test and Code Sprint - after CiviCon San Francisco (April 2012)
April 4th, 2012
This sprint is targeted at CiviCRM users and developers who want to work on (more...)

CiviCRM Components

Tools for engaging your supporters...

CiviContribute


CiviEvent


CiviMail


CiviMember


CiviReport


New Module for Drupal: CiviCRM Private Report

Not Just a Contact Database

These optional components give you more power to connect and engage your supporters.

  • civiCASE

  • Case management for clients and constituents.

  • civiEVENT

  • Online event registration and participant tracking.

  • civiMEMBER

  • Online signup and membership management.

  • civiMAIL

  • Personalized email blasts and newsletters.

  • civiREPORT

  • Report generation and template management.

January 9, 2012 - 10:02 — AllenShaw

A couple of weeks back I wrote here some thoughts about letting users manage and modify their own private collection of reports without actually having site-wide "administer reports" privileges. I've since gone ahead and written up the code to make this happen, and I would love to get feedback from the community on its usefulness and ways to improve it.

This code is available as a Drupal module for CiviCRM 3.4.x and 4.0.x, on Drupal.org by the project name CiviCRM Private Report. Following is a quick overview of how it works.

Key features

  • Each user has a private space for reports visible and editable by that user alone.
  • Users can copy any report that they can access into their own private report space.
  • CiviCRM's native listings of available reports do not show user-private reports, but do provide a link to the user's own list of private reports.
  • Any user-private report is accessible only by the user who created that report, with the exception of administrative users.
  • Administrative users can view any user-private report and may promote it to site-wide availability (that is, removing the private ownership status of the report).

Permissions

At this point the module essentially offers two classes of access. Basic functionality is available to users with CiviCRM's "Access Report Criteria" permission, plus this module's own "Administer own CiviCRM reports" permission. Administrative functions are granted to users with CiviCRM's "Administer Reports" permission.

Basic functionality: Creating and managing my private reports

Users with basic functionality can create a private copy of any CiviCRM report to which they have access. This is done in the new "Private Copy" section of options, which is added just below the "Report Criteria" section at the top of the report.

Here they just enter a new name and click "Save copy." The report is then saved as a new report instance, to which only that user has access.

The user now has access to a limited set of "Report Settings" form fields. At the moment this includes the General Settings but not Email Delivery Settings or Other Settings. I decided to hide those settings simply to save some complexity, and I'm considering adding support for them but haven't looked at that closely yet. There's an issue for adding them, here: http://drupal.org/node/1396878

Having created a private report, the user may expect to see it on the Reports Listing page. However, no private reports are listed there. Instead, the user is notified that he has private reports not displayed in the list, with a link to his own list of private reports.

The "My user-private reports" page lists all of the user's private reports, with links to view or delete any of them, in essentially the same format as CiviCRM's Report Listing page.

Administrative functions: Promoting private reports

Once a user has created and refined his own reports, it's conceivable that one or more of those reports could be useful to other users. In this case, a user with administrative access can promote the report to side-wide availability, which means simply that it's no longer a private report.

An administrative user can access the list of all private reports on the site, which is grouped by user.

From this listing the administrative user can open and review any user's private report. In the "Private Copy" section, the administrative user has access to a button labeled "Promote to site-wide report," which she can use to take the report out of the user's private collection, thus causing it to be treated like any other CiviCRM report.

With this, the report is now listed in CiviCRM's native Report Listing page.

Future improvements and feedback

There's surely room for improvement, and your feedback will be very helpful. (For example, lcdweb brought up the idea of peer-based sharing between users, which I think would be great to do. There's an issue for this new feature linked below.)

Please download the latest version for your own use and let me have your feedback. The Drupal issue queue is the best place for support requests and new feature requests. This module is also in use on a client's live 3.4.x site, so I'm expecting any improvements there to be worked back into the publicly available module.

( categories: )

Comments

Thanks!

Thanks for sharing your code Allen.

You may be interested in this thread on creating a CMS-independent module for CiviCRM. Since your code doesn't have anything to do with Drupal per-se, it would probably work great as a standalone module.

forum.civicrm.org/index.php/topic,22908.0.html

Good idea

It would take a little re-architecting on some points, but this module could be a good fit for that framework when it gets a little more stable.
 
(Along with that, it would be good to see a central online location for CiviCRM extensions, modules, etc. There is some appeal as a developer to work with d.o.)

Agreed

Actually there is such a place, but it needs a little love.

http://directory.civicrm.org/