The render method of the panels_views_plugin_row_fields class modifies the value of $view->field value, that causes other modules to not be able to work as expected (e.g. views_slideshow).

Actually I think it is only errors in variable names, because the code tries to restore the original value of $view->field.

Comments

b-prod’s picture

The patch below corrects the described bug.

osopolar’s picture

Status: Active » Needs review
StatusFileSize
new1.02 KB

The patch from #1 seems to be correct. I applied the same changes to the panels 7.x-3.x-dev. This fixes my problem in #1116648: Pager doesn't work with Panel Fields. Would be nice to have some more reviews.

d7 version of above patch!

osopolar’s picture

Status: Needs review » Active
StatusFileSize
new1.02 KB

Fixed typo in #2, changed patch name to be more clear, that it is fr d7.

d7 version of patch in #1!

osopolar’s picture

Letharion’s picture

Assigned: Unassigned » merlinofchaos
Status: Active » Needs review

Assigning to merlin for review.

mandreato’s picture

Status: Needs review » Reviewed & tested by the community

#1 worked for me with Panels 6.x-3.x-dev

mandreato’s picture

#3 worked for me with Panels 7.x-3.x-dev

Please commit both.

mandreato’s picture

Version: 6.x-3.x-dev » 7.x-3.x-dev
Status: Reviewed & tested by the community » Needs review
StatusFileSize
new822 bytes

Latest 7.x-3.x-dev fixes a part of the problem:

-    $view->field = $fields;
+    $this->view->field = $fields;
 

It remains the part of the foreach loop, which I fixed with the attached patch.

b-prod’s picture

Priority: Normal » Critical
Status: Needs review » Reviewed & tested by the community

This is a very old issue, that can be easily fixed, so I set it as critical.

Patch tested successfully with Views Slideshow module, because this module uses the rendered fields in its theme function.

To clearly identify the bug, here are the steps to reproduce:

  1. install both Panels and Views Slideshow modules;
  2. create a new view that uses slideshow display and panel fields as row plugin;
  3. add some fields;
  4. update the display options: activate the slideshow pager option and affect some fields;
  5. save the view.

When displaying the view, you get a lot of error messages (depending of the number of fields set in the pager), caused by the pager fields not available in the $view->field array.

japerry’s picture

Issue summary: View changes
Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

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

b-prod’s picture

@japerry: for your information, there are some basic rules about commit messages:
https://drupal.org/node/52287

osopolar’s picture

@B-Prod: Wondering what is wrong with japerry's commit message.

japerry’s picture

lol I was wondering the same. I think I missed a comma? Oh well.... ;)

  • Commit f253afb on 7.x-3.x, 8.x-3.x by japerry:
    Issue #1262074 by B-Prod, osopolar mandreato: Panels view row plugin...