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

Undefined index: group_type in views_handler_field->query()

    Details

      Description

      This issue has already been reported at http://issues.civicrm.org/jira/browse/CRM-9322 (and not fixed) but I couldn't figure out how to re-open it.

      Whenever I create a view of contacts or events where I displayed the address, I would get these errors on display:

      Notice: Undefined index: group_type in views_handler_field->query() (line 84 of views/handlers/views_handler_field.inc).
      Notice: Undefined index: element_wrapper_class in views_handler_field->options_form() (line 607 of views/handlers/views_handler_field.inc).

      I also received this error when adding the full street address field to the view:

      Notice: Undefined index: alter in views_handler_field->options_form() (line 1039 of views/handlers/views_handler_field.inc).

      I spent quite a while trying to track this down and then found that the "parent::construct();" line was missing from the 'function construct()

      {...}

      ' in the civicrm_handler_field_location.inc file. Adding this line in fixed the error. I also found other handlers where this line was also missing and fixed those too.

      Patch for these changes attached.

      FYI, I'm using Drupal 7 with Views 7.x-3.3. I also updated the Views ticket at http://drupal.org/node/1349546 with the patch in case anyone searches for it there too.

        Attachments

          Activity

            People

            • Assignee:
              kurund Kurund Jalmi
              Reporter:
              stella Stella Power
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: