CiviCRM
  1. CiviCRM
  2. CRM-6640

API input functions should accept the return values of output functions

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Won't Fix
    • Affects Version/s: 3.1.5, 3.1.6, 3.2
    • Fix Version/s: 4.3.0
    • Component/s: CiviCRM API
    • Labels:
      None

      Description

      This is a meta issue of which CRM-6639 is one example.

      The arrays returns by most CIviCRM API 'get' or 'search' functions are not valid parameters for the corresponding add/create functions. Frequently this is because date formats are different. Sometimes key names are different. Sometimes there is inconsistency whether a numeric ID or string label is expected.

      The result is that large amount of 'massaging code' is required to do things like copying an existing record.

      Similar inconsistencies exist with the 'objects' (sometimes arrays) passed to the pre/post hooks. E.g., the Contribution array passed to hook_civicrm_pre for a contrbituion is not a valid array for civicrm_contribute_create().

        Activity

        Hide
        Donald A. Lobo added a comment -
        These 448 issues have not been worked on for the past 18 months.

        Doing a bulk close of old issues to make the issue queue more manageable. We should do this on a periodic basis.
        Show
        Donald A. Lobo added a comment - These 448 issues have not been worked on for the past 18 months. Doing a bulk close of old issues to make the issue queue more manageable. We should do this on a periodic basis.

          People

          • Assignee:
            Donald A. Lobo
            Reporter:
            Matt Chapman
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development