Changes between Version 4 and Version 5 of Drupal HowTo Write Cron Tasks for CiviCRM


Ignore:
Timestamp:
11/19/13 10:28:58 (11 years ago)
Author:
Richard Bramley
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Drupal HowTo Write Cron Tasks for CiviCRM

    v4 v5  
    1414The code is located in the ''genvasc_labels'' module and uses the CiviCRM API.  The process is as follows:
    1515
    16 1. Select all the cases for the
     161. Select all the cases with a type of 'Genvasc' that have a status of 'Recruited'.
     171. Load the activities for these cases.
     181. Disregard any case that does not have an activity of type 'Mark available for cohorting' that is due in the past.
     191. For the remain tasks carry out the following processing.
     201. Update the case status to 'Available for cohorting'.
     211. Add a new activity against the case of type 'Status Changed'.  The target contact is the case contact, and the source contact is the 'Cron System' user (see below).
     221. Update the 'Mark available for cohorting' activity status to be completed.
    1723
    1824== Note regarding Cron System ==