There's a couple things that will cause the Panels IPE to re-render a pane or the whole Panels display via AJAX:

  1. Editing a particular pane will re-render that pane via AJAX
  2. Saving will re-render the whole Panels display via AJAX

However, when rendering via AJAX, menu blocks will disappear. The reason they disappear is because they are figuring out the menu to display from the current path, and when rendering via AJAX, the current path is to the AJAX end-point -- not the original page.

When re-rendering a pane or a whole display via the Panels IPE, we should be minimally setting up Drupal's state to think it's at the original page so that menu blocks continue to render correctly.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

dsnopek created an issue. See original summary.

dsnopek’s picture

Status: Active » Needs work
FileSize
1.87 KB

Here's a patch that solves the problem when saving in the IPE. The problem still happens when editing the menu block in the IPE.

dsnopek’s picture

cboyden’s picture

cboyden’s picture

Status: Needs review » Reviewed & tested by the community

We've been using this patch for the past few months, and it's working fine.

DamienMcKenna’s picture

joseph.olstad’s picture

retriggered tests

joelpittet’s picture

Status: Reviewed & tested by the community » Fixed

Thanks @dsnopek, I've committed this to the dev branch for the next release.

  • joelpittet committed 5627b5d on 7.x-3.x authored by dsnopek
    Issue #2897658 by dsnopek: Menu blocks disappear when editing/saving in...
ron_s’s picture

FYI, this patch has introduced a new bug in 7.x-3.10. Please review: https://www.drupal.org/project/panels/issues/3157925

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

joelpittet’s picture

@dsnopek Could you have a peak at @ron_s issue in #3157925?