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) »
  • Looking for code for renewal + pay later process
Pages: [1]

Author Topic: Looking for code for renewal + pay later process  (Read 1207 times)

SarahG (FountainTribe)

  • Ask me questions
  • ****
  • Posts: 782
  • Karma: 29
  • CiviCRM version: 4.4.7
  • CMS version: Drupal 6, Drupal 7
  • MySQL version: 5.5
  • PHP version: 5.3
Looking for code for renewal + pay later process
December 26, 2009, 11:12:52 am
I have a front-end facing Contribution Page that allows for membership signup/renewal and a "pay later" option.    I would like to write a batch program that triggers the "renew" + "pay later" action.   What file should I look at that takes care of this when the end-user triggers the renewal?

I have already been digging around under "<joomla root>/administrator/components/com_civicrm/civicrm/CRM/Contribute but cannot find what I need.

« Last Edit: December 26, 2009, 03:15:27 pm by sgladstone »
Did I help you? Please donate to the Civi-Make-It-Happen campaign  CiviCRM for mobile devices! 

Eileen

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4195
  • Karma: 218
    • Fuzion
Re: Looking for code for renewal + pay later process
December 26, 2009, 03:08:19 pm
Hi, this is just a superficial response as I don't know this code well but there is a renewMembership function in civicrm/CRM/member/BAO/membership.php
Make today the day you step up to support CiviCRM and all the amazing organisations that are using it to improve our world - http://civicrm.org/contribute

SarahG (FountainTribe)

  • Ask me questions
  • ****
  • Posts: 782
  • Karma: 29
  • CiviCRM version: 4.4.7
  • CMS version: Drupal 6, Drupal 7
  • MySQL version: 5.5
  • PHP version: 5.3
Re: Looking for code for renewal + pay later process
December 26, 2009, 06:54:12 pm
That file and function renewMembership are just what I am looking for. Would you happen to know where I could find a sample call to the "renewMembership" fuction so I know what parms to pass?

I am planning to copy that function to create a new "renewOnly" functions for membership types that I set as "auto-renew" ( using a custom field on the membership type )
Did I help you? Please donate to the Civi-Make-It-Happen campaign  CiviCRM for mobile devices! 

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: Looking for code for renewal + pay later process
December 26, 2009, 09:33:57 pm

check:

CRM/Member/BAO/Membership.php

and search for renewMembership

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

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Developer Discussion (Moderator: Donald Lobo) »
  • Looking for code for renewal + pay later process

This forum was archived on 2017-11-26.