CRM-3530 Running bin/UpdateMembershipRecord.php creating scheduled meeting activity

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Major
    • Resolution: Fixed/Completed
    • Affects Version/s: 2.0, 2.1
    • Fix Version/s: 2.1
    • Component/s: CiviMember
    • Labels:
      None

      Description

      When running UpdateMembershipRecord.php I got a lot of scheduled activitys, for example I got scheduled meetings after running UpdateMembershipRecord.php with the same title as the online contribution. I also some times got sheduled mail or sms activity t ype.

      in api/Membership.php
      and
      function crm_update_contact_membership($params)

      // create activity record only if there is change in the statusID (CRM-2521).
      if ( $oldStatusID != $membershipBAO->status_id ) {
      $activityParams = array( 'source_contact_id' => $membershipBAO->contact_id,
      'source_record_id' => $membershipBAO->id,
      'activity_type_id' => $membershipBAO->status_id,
      'subject' => $activitySummary,
      'activity_date_time' => $params['join_date'],
      'is_test' => $membershipBAO->is_test,
      'status_id' => 1
      );

      the activity_type_id is set to the membershipBAO->status_id

      is that supposed to be like that?

      Talking to Kurund. Wanted me to do this change

      (11:41:04 AM) kurund: Can you make this change: activity_type_id' => CRM_Core_OptionGroup::getValue( 'activity_type', 'Membership Signup', 'name' ),

      I did that and try running the script agian now I got scheduled "Membership Signup" instead. With the date the contribution was recorded.

      Also the CRM_Utils_System::authenticateScript( true );

      dont seems to work with drupal 5.10 and the module "Secure Password Hash" ...

        Attachments

          Activity

          [CRM-3530] Running bin/UpdateMembershipRecord.php creating scheduled meeting activity
          Kiran Jagtap added a comment -

          //fixed in rev - 17036

          Amiteshwar Prasad added a comment -

          Checked with r18157.

          Sunny Sharma added a comment -

          tested in r19020

            People

            • Assignee:
              Sunny Sharma
              Reporter:
              Jonas Hagberg

              Dates

              • Created:
                Updated:
                Resolved: