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 CiviMember (Moderator: Deepak Srivastava) »
  • Changing Contributions to "Completed" changes member end dates
Pages: [1]

Author Topic: Changing Contributions to "Completed" changes member end dates  (Read 1346 times)

Lionsharz

  • I post occasionally
  • **
  • Posts: 76
  • Karma: 0
    • www.ulearnschool.com
  • CiviCRM version: 4.4.4
  • CMS version: Drupal 7
  • PHP version: 5.3 / 5.4
Changing Contributions to "Completed" changes member end dates
October 07, 2013, 03:59:27 am
Hi

Steps to reproduce:

1) New Contact
2) Create New Membership; Start Date = Monday next week & Finish Date = Friday next week
3) Click checkbox to record payment and enter contribution details as "pending" (I entered the date 07/10/2013)
4) Save and exit membership
4) Go to Contributions tab
5) Update the contribution from "pending" to "completed" and add todays date as the "Receive Date" (as would happen regularly in our case where we accept part payments from Students)

Then save and exit. Return to membership. All Membership Dates have now changed automatically to today's date (see attached screen shot)

QUESTIONS:
1) What's the relationship between the Contribution Receive Date and the membership dates?
2) Any ideas on why this is happening?

Any help much appreciated!

Thanks
www.ulearnschool.com

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Changing Contributions to "Completed" changes member end dates
October 07, 2013, 02:24:09 pm
The current design assumes that a new membership doesn't "start" until it's paid for. This means that the membership start date for a Pending membership is automatically set (reset) to TODAY when the pending contribution is updated to completed. It looks like this is actually true even if the contribution Receive Date is modified to be a date other than TODAY (which is arguably a bug).

The most common use case for Pending memberships is self-service signup via online contribution pages. In that scenario, NO membership start date is set when the membership is created. Then when receipt of payment is recorded in the back-office, the membership "begins".
Protect your investment in CiviCRM by  becoming a Member!

Lionsharz

  • I post occasionally
  • **
  • Posts: 76
  • Karma: 0
    • www.ulearnschool.com
  • CiviCRM version: 4.4.4
  • CMS version: Drupal 7
  • PHP version: 5.3 / 5.4
Re: Changing Contributions to "Completed" changes member end dates
October 08, 2013, 08:52:00 am
Ok. So using "In Progress" seems to be one around it when tracking part payments for memberships. However, there is no checkbox for this in the Advanced Search (we only see Completed, Pending, Cancelled and Failed).

Is there any way to expose this as a checkbox in the advanced search?
www.ulearnschool.com

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Changing Contributions to "Completed" changes member end dates
October 11, 2013, 05:50:14 am
I think that status is only intended for Pledges (pretty sure this was fixed in 4.3 so it's not exposed to contributions).
Protect your investment in CiviCRM by  becoming a Member!

Lionsharz

  • I post occasionally
  • **
  • Posts: 76
  • Karma: 0
    • www.ulearnschool.com
  • CiviCRM version: 4.4.4
  • CMS version: Drupal 7
  • PHP version: 5.3 / 5.4
Re: Changing Contributions to "Completed" changes member end dates
October 11, 2013, 06:38:04 am
OK - in our case we need to use it as part of a smart group search. Do you know where this code is for the Advanced Search page? I might hack a line in to include it as a checkbox....
www.ulearnschool.com

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Changing Contributions to "Completed" changes member end dates
October 12, 2013, 05:57:50 am

might want to check: http://developer.civicrm.org/

there are a few tips and tricks to get to the code from the url documented there

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Changing Contributions to "Completed" changes member end dates
October 14, 2013, 12:49:49 pm
Link above seems invalid ??? Try this one:
http://book.civicrm.org/developer/

... and developer sections on the wiki:
http://wiki.civicrm.org/confluence/display/CRMDOC/Develop
Protect your investment in CiviCRM by  becoming a Member!

Lionsharz

  • I post occasionally
  • **
  • Posts: 76
  • Karma: 0
    • www.ulearnschool.com
  • CiviCRM version: 4.4.4
  • CMS version: Drupal 7
  • PHP version: 5.3 / 5.4
Re: Changing Contributions to "Completed" changes member end dates
October 14, 2013, 01:02:04 pm
Thanks Dave! You wouldn't happen to have a pointer in the direction of the file(s) that produce the Advanced Search..?
www.ulearnschool.com

Lionsharz

  • I post occasionally
  • **
  • Posts: 76
  • Karma: 0
    • www.ulearnschool.com
  • CiviCRM version: 4.4.4
  • CMS version: Drupal 7
  • PHP version: 5.3 / 5.4
Re: Changing Contributions to "Completed" changes member end dates
October 17, 2013, 03:43:47 am
I don't know what it means that In Progress is only for pledges. Aren't pledges contributions? Is there any way to search on this term?
www.ulearnschool.com

Lionsharz

  • I post occasionally
  • **
  • Posts: 76
  • Karma: 0
    • www.ulearnschool.com
  • CiviCRM version: 4.4.4
  • CMS version: Drupal 7
  • PHP version: 5.3 / 5.4
Re: Changing Contributions to "Completed" changes member end dates
October 17, 2013, 06:29:52 am
I don't know if this will break other things but here is what I did. File sites/all/modules/civicrm/CRM/Contribute/BAO/Query.php @ line 762, I commented out the unset of those contribution status'

    $statusValues = CRM_Core_OptionGroup::values("contribution_status");
    // Remove status values that are only used for recurring contributions or pledges (In Progress, Overdue).
    unset($statusValues['5']);
    unset($statusValues['6']);

To:

    $statusValues = CRM_Core_OptionGroup::values("contribution_status");
    // Remove status values that are only used for recurring contributions or pledges (In Progress, Overdue).
    //unset($statusValues['5']);
    //unset($statusValues['6']);
www.ulearnschool.com

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Changing Contributions to "Completed" changes member end dates
October 17, 2013, 11:22:02 am
In terms of CiviCRM semantics, pledges are a promise of a contribution. The pledge payments are the contributions.

Your modification probably is fine for your usage, altho you'll need to maintain thru upgrades. At some point hopefully there will be more generalized support for partial payments on memberships, events, etc.
Protect your investment in CiviCRM by  becoming a Member!

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviMember (Moderator: Deepak Srivastava) »
  • Changing Contributions to "Completed" changes member end dates

This forum was archived on 2017-11-26.