Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-20435

Don't use SQL in CRM_Activity_BAO_Activity::create() where DAO will suffice

    Details

    • Type: Extension Review Request
    • Status: Done/Fixed
    • Priority: Minor
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.7.18
    • Fix Version/s: 4.7.20
    • Component/s: Core CiviCRM
    • Labels:
    • Versioning Impact:
      Patch (backwards-compatible bug fixes)
    • Documentation Required?:
      None
    • Funding Source:
      Needs Funding
    • Verified?:
      No

      Description

      Replace direct SQL will DAO->save() operations.

      While working on an extension, I discovered that event civi.dao.postInsert fires for some but not all of the ActivityContacts created via api.Activity.create. Replacing the SQL will make the developer experience more consistent and the code more extensible.

        Attachments

          Activity

            People

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

              Dates

              • Created:
                Updated:
                Resolved: