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

Custom Data Groups created while logging is disabled break changelogs when logging re-enabled

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 4.6.11
    • Fix Version/s: Unscheduled
    • Component/s: Core CiviCRM
    • Labels:
      None
    • Versioning Impact:
      Patch (backwards-compatible bug fixes)
    • Documentation Required?:
      None
    • Funding Source:
      Needs Funding

      Description

      Steps to Reproduce:

      1. Enable Logging
      2. Disable Logging
      3. Create a Custom Data Group for Contacts with at least one field.
      4. Re-Enable Logging
      5. Edit a contact, change your custom field.
      6. Check contact's changelog, look at "Update" action for new changelog entry.

      Expected Results:

      Changed field information is displayed.

      Actual Results:

      Sorry but we are not able to provide this at the moment.
      One of parameters (value: ) is not of the type Integer

      Backtrace shows that this is due to CRM_Logging_Differ->titlesAndValuesForCustomDataTable assuming that an attempt to find the custom data group in log_civicrm_custom_group will succeed.
      This is not true if the Group was created after log_civicrm_custom_group, but while logging was disabled.

      The following code appears to make the same assumption about log_civicrm_custom_field.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              agileware Agileware
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: