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) »
  • Developer Discussion (Moderator: Donald Lobo) »
  • Membership Summary for Previous Months
Pages: [1]

Author Topic: Membership Summary for Previous Months  (Read 1510 times)

swartik

  • Guest
Membership Summary for Previous Months
January 24, 2008, 07:09:26 am
Hi,

Our organization's membership secretary likes the tabular information she gets from the civi member page (i.e., the url http://.../civicrm/member?reset=1). She likes it so much she wants to be able to retrieve it for past months too.

What's the best way to implement this? I was thinking of extending some existing civi classes to override relevant methods -- e.g., extend CRM_Member_Page_DashBoard and override the preProcess() function, extend CRM_Member_BAO_Membership and override getMembershipSummary() -- and creating a new template to use instead of CRM/Member/Page/DashBoard.tpl. Is this a good approach, or would the best experts advise another way?

Thanks for any and all help!

Steve Wartik

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Membership Summary for Previous Months
January 25, 2008, 03:30:43 pm
Hi Steve - Lobo and I chatted about this last night and had the following thoughts:
* Enhancing the component dashboards (esp CiviMember and CiviContribute) with the abilty to show tabular results for a user-defined range of months seems like a valuable extension.

* So... rather than creating a new template - how about implementing the alternative view as a URL parameter-driven conditional. Depending on your use case and how complicated you want to make it - the parameter could be a simple boolean to show past 12 months (or whatever additional set of columns seems useful). Or you could start and end date params....

* In order to make this a bit easier - your first step might be to just modify ("hack") the existing template and getMembershipSummary() method to do what you need. Then see what it would take to parameterize the alternatives. A simple pair of links on the page could be used to switch "views".

Feel free to grab us on IRC if you want to discuss further.
Protect your investment in CiviCRM by  becoming a Member!

swartik

  • Guest
Re: Membership Summary for Previous Months
January 29, 2008, 08:49:54 am
Dave,

I think I've got something useful hacked together... unfortunately I'm on a business trip at a site that blocks IRC chats. Stay tuned....

Steve

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Developer Discussion (Moderator: Donald Lobo) »
  • Membership Summary for Previous Months

This forum was archived on 2017-11-26.