Looking for some help on getting $params to be passed on from the scheduled job -> GUI page -> into my scheduled job; so:

function civicrm_api3_job_ecocalculate($params) {

I'd like to be able to pass in e.g.

enter image description here

But when I try this I just get $params = null in my function;

What am I missing?


This is what I have: enter image description here

(I know you can read it :-)

And in my code:

function civicrm_api3_note_Migrate($params) {
  // param migrate_type determines what will be selected, defaulted to contact
  $validTypes = array('contact', 'contribution', 'participant', 'relationship');
  if (!isset($params['migrate_type'])) {
    $entityTable = 'civicrm_contact';
  } else {
    if (in_array($params['migrate_type'], $validTypes)) {
      $entityTable = 'civicrm_'.$params['migrate_type'];
    } else {
      $entityTable = 'civicrm_contact';

But I am not sure if that is what you mean?

| improve this answer | |
  • 1
    Why does this work for you and not for me? Niet eerlijk! – KarinG - Semper IT Oct 25 '17 at 20:27
  • 1
    Ah - is working now! Perhaps I had my jobs mixed up; In any case - helemaal goed; – KarinG - Semper IT Oct 26 '17 at 1:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.