splitbrain / dokuwiki-plugin-dw2pdf

A fork of Luigi Micco's PDF export plugin for DokuWiki
http://www.dokuwiki.org/plugin:dw2pdf
55 stars 68 forks source link

Struct data in DW2PDF produces unexpected results #504

Open cjohnsonuk opened 7 months ago

cjohnsonuk commented 7 months ago

I have a namespace full of documents relating to business continuity. Struct data is associated with this name space with details such as owner, sponsor, last review date, next review date, published status etc. Each page has its own meta data that is displayed at the top of the page using

==== Document information ====
^This document status   |{{$doc_data.status}}  |
^This document is owned by   |{{$doc_data.owner}}  |
^This document is sponsored by   |{{$doc_data.sponsor}}  |
^This document was last reviewed by   |{{$doc_data.reviewed_by}} on {{$doc_data.reviewed_date}} |
^This document next review date is   |{{$doc_data.next_review}}  |
^This document should be reviewed every  |{{$doc_data.review_period}}  |

If I use dw2pdf to print an individual page, eg using the icon in the tool bar on the right of the page then the page's metadata is included in the page.

I use DW2PDF to create a "hard copy" of the all documents in this namespace and periodically (and automatically) email it to senior staff so they all have a copy of all the docs.

I use this link

https://<mydomain>/policies/bcp/start?do=export_pdfns&book_ns=policies:bcp&book_title=BCP%20and%20DR%20Planning&toc=1&toclevels=0-1&book_order=date&watermark=CONFIDENTIAL&excludes[]=policies:bcp:scenarios:i_template&excludes[]=policies:bcp:bcp_bia_questionnaire&excludes[]=policies:bcp:schools_business_continuity_plan_guidance

but the meta data included in the PDF appears to be the meta data from the start page in the namespace detailed in &book_ns= and its the same meta data that appears for every page added to the PDF

I've tried changing the link to be the start page for the whole wiki where there is no struct allocation:

https://<mydomain>/start?do=export_pdfns&book_ns=policies:bcp&book_title=BCP%20and%20DR%20Planning&toc=1&toclevels=0-1&book_order=date&watermark=CONFIDENTIAL&excludes[]=policies:bcp:scenarios:i_template&excludes[]=policies:bcp:bcp_bia_questionnaire&excludes[]=policies:bcp:schools_business_continuity_plan_guidance

but I get the same results with every individual page included in the PDF displaying the data of the start page in the namespace.

Am I missing something obvious or is this a bug??