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

uf_field api wants "field_name" as required parameter for exiting fields.

    Details

    • Type: Improvement
    • Status: Done/Fixed
    • Priority: Blocker
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.4.3
    • Fix Version/s: 4.7
    • Component/s: CiviCRM API
    • Labels:
    • Documentation Required?:
      None
    • Funding Source:
      Contributed Code

      Description

      I can't test this out on 4.5 because the new api explorer doesn't have Create as an option for UFField. See http://screencast.com/t/REPidQJzh0I

      However, in the older versions, I would think that it should be possible to do something of the following

      civicrm_api3('uf_field', 'create', array( 'id' => 1, 'label' => 'My First Name'));

      This would rename the first name field in the "Name and Address" profile to be "My First Name".

      The outcome of the above code is instead and exception that reads: "Params must be a field_name-carrying array and a positive integer."

        Attachments

          Activity

            People

            • Assignee:
              dgg David Greenberg
              Reporter:
              generalredneck Allan Chappell
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: