Uploaded image for project: 'CiviVolunteer'
  1. CiviVolunteer
  2. VOL-123

For projects not associated with events, activity creation fails

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Critical
    • Resolution: Fixed/Completed
    • Affects Version/s: 2.0
    • Fix Version/s: 2.0
    • Labels:
      None
    • Documentation Required?:
      None
    • Sprint:
      Week 35

      Description

      Discovered when writing unit tests, where "EntityTable1" is supplied as the value for entity_table. Creation of volunteer activity via CRM_Volunteer_BAO_Assignment::createVolunteerActivity() fails with:

      CiviCRM_API3_Exception: API (EntityTable1, get) does not exist (join the API team and implement it!)

      The method helpfully tries to provide some default values if none are passed, but it does so rather clumsily, assuming that entity_table will always match the pattern civicrm_entity, where entity can be used in an API call:

      civicrm_api3(entity, 'getsingle', $params);

        Attachments

          Activity

            People

            • Assignee:
              pittstains Frank J. Gómez
              Reporter:
              pittstains Frank J. Gómez
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - 2 hours
                2h
                Remaining:
                Remaining Estimate - 2 hours
                2h
                Logged:
                Time Spent - Not Specified
                Not Specified