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 Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Relationships not expiring at end date
Pages: [1]

Author Topic: Relationships not expiring at end date  (Read 1094 times)

rjb

  • I post occasionally
  • **
  • Posts: 63
  • Karma: 2
  • CiviCRM version: 3.3.5
  • CMS version: Drupal 6
  • MySQL version: 5.1.44
  • PHP version: 5.3.1
Relationships not expiring at end date
January 20, 2011, 01:27:33 am
Hi, everyone.

Bit of an odd one - I'm currently configuring a test site and one thing's not quite working which I think ought to be. When I have two contacts where A is the employer of B and there is a consequential inherited membership, I would like the membership to be removed from B when the relationship expires. I believe this is expected functionality. However, if I set the relationship to end at a certain date...

a) The relationship continues and,
b) The membership inheritance remains.

I have noticed that, while the end date remains in the Edit Relationship screen, the time always disappears if I click Save Relationship then Edit Relationship again. Is this perhaps the reason that the relationship doesn't end? Regardless, even if the end date comes and goes (I ran an overnight test), the relationship continues.

I can force the relationship to end by manually setting the end date to a previous day but, obviously, I need this to be automated. And, as a further wrinkle on this issue, I notice that, even if the relationship is manually set to be inactive, the membership is still active and inherited.

It's a confusing one...

Do I need to set up cron jobs for this, perhaps? Or am I missing something really obvious?

Huge thanks in advance for your help,

Robin

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: Relationships not expiring at end date
January 20, 2011, 09:19:19 am

check:

http://wiki.civicrm.org/confluence/display/CRMDOC33/Membership+Types

Search for: Membership Status and Reminder Server Requirement

I'm not very sure if the script handles it nicely when the relationship expires. If not, please do consider investigating and contributing a patch and/or hiring a developer to do the needful

the script needs to be quite efficient also (for large dbs)

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

rjb

  • I post occasionally
  • **
  • Posts: 63
  • Karma: 2
  • CiviCRM version: 3.3.5
  • CMS version: Drupal 6
  • MySQL version: 5.1.44
  • PHP version: 5.3.1
Re: Relationships not expiring at end date
January 21, 2011, 02:01:28 am
Thanks for the help, Lobo.

I thought it may have something to do with that, but just wanted to check whether the cron job specified at that wiki page would also update relationship status. I guess it's a suck-it-and-see situation, but do you suspect that it will cover relationships or that a patch will definitely need to be written? It seems odd to have an expiry date there in the gui for relationships but no way to trigger an expiry as yet. That said, I'm always happy to find a hole if it means either we or someone else can patch it!

In the short term, how easy would it be to remove the to date and time fields from the edit relationship page? I'm keen not to have something there if it doesn't actually function as expected.

Many thanks again for all your incredible work (and that goes for the entire core team),

Robin

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: Relationships not expiring at end date
January 21, 2011, 06:57:09 am

u'll need to check and see it

you can remove the dates via:

http://wiki.civicrm.org/confluence/display/CRMDOC33/Customizing+CiviCRM+Screens

lobo

p.s> please do consider making a contribution to the 3.4 Make It Happen: http://civicrm.org/mih That sustains and helps grow the project
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

rjb

  • I post occasionally
  • **
  • Posts: 63
  • Karma: 2
  • CiviCRM version: 3.3.5
  • CMS version: Drupal 6
  • MySQL version: 5.1.44
  • PHP version: 5.3.1
Re: Relationships not expiring at end date
January 24, 2011, 02:07:36 am
That's great - thank you. I've commented out the end date section for now and, should our client require it, we'll definitely look into testing the cron and, if it's not working as expected, contributing some code. On a more personal note, I shall certainly make a contribution at some point.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Relationships not expiring at end date

This forum was archived on 2017-11-26.