[GNC] Hard-Copy Report Output
rsbrux
rsbrux at yahoo.com
Mon Jun 12 14:02:10 EDT 2023
> On Jun 11, 2023, at 9:56 AM, Adrien Monteleone <adrien.monteleone at lusfiber.net> wrote:
>Is this a completely custom report or just a saved configuration? If completely custom, you may want to try the -dev list.
This is a report I assembled from the options available in the GC GUI (like the pie chart you successfully tested).
Unfortunately, I am not competent to use the programming facilities behind GC's report generation.
> On Jun 11, 2023, John Ralls <jralls at ceridwen.us> wrote:
>It's most likely a javascript problem. Open the javascript console in your browser and see if there's an error finding Chart.bundle.min.js.
>The correct location is <prefix>/share/gnucash/chartjs/Chart.bundle.min.js where <prefix> is where GnuCash is installed: /usr for a Linux package manager installation, /Applications/Gnucash.app/Contents/Resources for a macOS bundle, C:\Program Files (x86)\gnucash for Windows, etc.
>
>You can fix the link by editing the html file in your favorite text editor.
I have tried opening the exported HTML reports in Firefox on Ubuntu and in Edge and Firefox on Windows. Although the browser consoles show errors, I don't see any pertaining to " Chart.bundle.min.js", nor do I find any critical errors pertinent to the report content.
The new HTML reports are looking for Chart.bundle.min.js in /app/share/gnucash/chartjs/, but no such directory exists on the Ubuntu system where GnuCash is installed. In fact, there isn't even an /app/ directory. Perhaps this is due to GC being installed as a flatpak.
Chart.bundle.min.js does not seem to exist on either system, so I edited the HTML as you suggested, replacing the local path with "https://cdnjs.cloudflare.com/ajax/libs/Chart.js/4.3.0/chart.min.js" but this did not improve matters.
However, my previously saved HTML reports from GC 2.xx also don't display correctly, even though they contain no references to Chart.bundle.min.js. This suggests a more fundamental problem and reveals my presumption that the HTML files could be used as archives as naive.
I have a previously saved PDF file, which is, of course still usable. This will be my method going forward, although the lack of a "scale to fit" option in the GC print dialog requires a bit of trial and error to get a satisfactory PDF.
Many thanks to both of you for your support!
More information about the gnucash-user
mailing list