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 »
  • APIs and Hooks (Moderator: Donald Lobo) »
  • civicrm_api3('participant', 'create', $p): registered_by_id is not valid : 78420
Pages: [1]

Author Topic: civicrm_api3('participant', 'create', $p): registered_by_id is not valid : 78420  (Read 1023 times)

Erich Schulz

  • I post frequently
  • ***
  • Posts: 142
  • Karma: 5
    • When no-one understands what you are going on about its time to start a blog
  • CiviCRM version: 4.4
  • CMS version: Drupal 7
  • MySQL version: 5.somthing
  • PHP version: 5.3.3
civicrm_api3('participant', 'create', $p): registered_by_id is not valid : 78420
March 09, 2015, 04:10:14 am
hey all, dumb question (in which I specialise)

I assumed registered_by_id was a contact ID

is it something else?

and where would I find the doco for it?

many thanks! you all rock!


Erik Hommel

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1773
  • Karma: 59
    • EE-atWork
  • CiviCRM version: all sorts
  • CMS version: Drupal
  • MySQL version: Ubuntu's latest LTS version
  • PHP version: Ubuntu's latest LTS version
Re: civicrm_api3('participant', 'create', $p): registered_by_id is not valid : 78420
March 10, 2015, 12:50:19 am
registered_by_id refers to the participant_id, and the particpant then has the contact_id. So if I as participant 23 also register another participant 24, the registered_by_id of participant 24 will contain 23
Consultant/project manager at EEatWork and CiviCooP (http://www.civicoop.org/)

Erich Schulz

  • I post frequently
  • ***
  • Posts: 142
  • Karma: 5
    • When no-one understands what you are going on about its time to start a blog
  • CiviCRM version: 4.4
  • CMS version: Drupal 7
  • MySQL version: 5.somthing
  • PHP version: 5.3.3
Re: civicrm_api3('participant', 'create', $p): registered_by_id is not valid : 78420
March 10, 2015, 06:05:34 am
Hey thanks Erik

Mmm so if you are not a participant you can't record that you registered someone? Ok.

Erik Hommel

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1773
  • Karma: 59
    • EE-atWork
  • CiviCRM version: all sorts
  • CMS version: Drupal
  • MySQL version: Ubuntu's latest LTS version
  • PHP version: Ubuntu's latest LTS version
Re: civicrm_api3('participant', 'create', $p): registered_by_id is not valid : 78420
March 11, 2015, 01:56:50 am
It seems to suggest that yes....but I could imagine a use case for a secretary registering while she is not a participant. There might be a need for some feature adding here?
Consultant/project manager at EEatWork and CiviCooP (http://www.civicoop.org/)

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: civicrm_api3('participant', 'create', $p): registered_by_id is not valid : 78420
March 12, 2015, 10:54:24 am
Agree this is a missing feature. With webforms you can have anyone register anyone else, but the registered_by_id is fairly useless in that case. Webform gets around this by simply not populating it (so the data on who registered whom just doesn't get stored). In other cases I've seen a custom field used for this purpose.
Try asking your question on the new CiviCRM help site.

Erik Hommel

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1773
  • Karma: 59
    • EE-atWork
  • CiviCRM version: all sorts
  • CMS version: Drupal
  • MySQL version: Ubuntu's latest LTS version
  • PHP version: Ubuntu's latest LTS version
Re: civicrm_api3('participant', 'create', $p): registered_by_id is not valid : 78420
March 13, 2015, 06:45:24 am
Yes, I have seen that too. And there seems to be a growing group of organizations that might want to sponsor an extension for 'Secretary Registration'. Is that something you would consider?
Consultant/project manager at EEatWork and CiviCooP (http://www.civicoop.org/)

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: civicrm_api3('participant', 'create', $p): registered_by_id is not valid : 78420
March 13, 2015, 06:52:10 am
Sure. Maybe the project would be as "simple" as modifying the schema so that registered_by_id was changed to the contact_id instead of the participant_id of the registering person.
Or maybe keep it and add a new field.
Try asking your question on the new CiviCRM help site.

Erik Hommel

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1773
  • Karma: 59
    • EE-atWork
  • CiviCRM version: all sorts
  • CMS version: Drupal
  • MySQL version: Ubuntu's latest LTS version
  • PHP version: Ubuntu's latest LTS version
Re: civicrm_api3('participant', 'create', $p): registered_by_id is not valid : 78420
March 13, 2015, 07:05:52 am
Hi Coleman,
not surprised  ;D
The question was mean for Erich Schulz, I should have been more specific  :P
Consultant/project manager at EEatWork and CiviCooP (http://www.civicoop.org/)

Erich Schulz

  • I post frequently
  • ***
  • Posts: 142
  • Karma: 5
    • When no-one understands what you are going on about its time to start a blog
  • CiviCRM version: 4.4
  • CMS version: Drupal 7
  • MySQL version: 5.somthing
  • PHP version: 5.3.3
Re: civicrm_api3('participant', 'create', $p): registered_by_id is not valid : 78420
March 15, 2015, 05:08:22 am
Heh, nice asking Erik!

sadly my organisation is very poor :-(

and also this is not critical - I notice there is a "source" field that enable some text value, so it is probably adequate.

I'm happy to update the doco somewhere if I got a pointer to where the data dictionary lives!

Erik Hommel

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1773
  • Karma: 59
    • EE-atWork
  • CiviCRM version: all sorts
  • CMS version: Drupal
  • MySQL version: Ubuntu's latest LTS version
  • PHP version: Ubuntu's latest LTS version
Re: civicrm_api3('participant', 'create', $p): registered_by_id is not valid : 78420
March 16, 2015, 12:49:17 am
No worries Erich, it was worth a try  :P

I would not use the source field, but create a custom field? The source field is used for other purposes (the source of a contact, for example specific webform) and in general it is better practise not to use core fields for other functional purposes.

Keep checking the available extensions, something for secretary is likely to pop up in the near future me thinks...
Consultant/project manager at EEatWork and CiviCooP (http://www.civicoop.org/)

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Developer Discussion »
  • APIs and Hooks (Moderator: Donald Lobo) »
  • civicrm_api3('participant', 'create', $p): registered_by_id is not valid : 78420

This forum was archived on 2017-11-26.