- Issue created by @arne_hortell
Undefined variable $class_methods in views_pdf_form_view_preview_form_alter() (line 59 of /var/www/web/modules/contrib/views_pdf/views_pdf.module)
Changed the name of the variable to follow snake_case.
- πΈπͺSweden killua99
Hi thank both of you.
@lanayaMain could you please do a https://www.drupal.org/docs/develop/git/using-git-to-contribute-to-drupa... β
Also, could we try to reduce the amount of 'if' usage.
Yeah, sure.
Agree that patch has excessive amount of if's, so I've attached updated patch with interdiff. Think that will be enough to just check whether display_handler NULL or not.
BTW this error appears when we have view pdf display (from this module), and trying to create data export display.
- Status changed to RTBC
about 1 year ago 5:47pm 14 October 2023 - π¨π¦Canada leducdubleuet Chicoutimi QC
I can confirm the patch in comment #5 does the job!
Thanks!
- π¨π¦Canada teknocat
The patch in #5 is not really the correct solution. It prevents the error, but it doesn't make the code work correctly, which is to ensure that the live preview is disabled for the PDF display. I don't quite know why it still successfully disables the live preview, but the correct syntax should be as follows:
if ('pdf' === $view->getDisplay()->getPluginId()) {
I will create an issue fork and submit a merge request for this.
- Status changed to Needs review
about 1 year ago 12:43am 28 November 2023 - Status changed to RTBC
about 1 year ago 1:33pm 9 December 2023 - πΊπΈUnited States DamienMcKenna NH, USA
The merge request fixes the bug on a site where it started showing up, thank you.