[Tutorial] Script Report / Chart

AWESOME! :partying_face:
Thank you @EugeneP!!!

1 Like

Thanks for your time, effort and Helpfull Contribution towards community. Appreciate :+1::+1:


This is super cool, and the details are extremely helpful.

It’s also possible to do most things on the client-side without a custom app. There are a few limitations regarding the available python functions, but it’s been amazing to see how developer-friendly Frappe continues to become:

1 Like

Due to the great response this topic has had, I’ve been updating it frequently as I myself learn more. Should you uncover something yourself then please share that.

Last but certainly not least, thanks for the likes and words of encouragement. It’s good to know you found benefit from reading it.


Thanks @EugeneP for the excellent write up!
Can this be done also on sites hosted on Frappe Cloud or only for self-hosted sites?

1 Like

I’m not sure. I presume not, since you have to have access to the file system.

1 Like

Yes, you can. Frappe cloud allows you to install arbitrary apps hosted on GitHub to your bench.

Thanks @peterg! Are you referring to this: https://frappecloud.com/docs/bench/install-custom-app?
I am fairly new to ERPnext and Frappe Cloud. Do you have any links at hand that would describe the process of wrapping what @EugeneP has described above into a custom app?

Yes, exactly. You need to create an app on a development bench (instructions here), then follow EugeneP’s excellent instructions. Then, follow those instructions to deploy to frappe cloud.

Alternately, it’s possible you can do what you need client side. See the link I posted a few messages back for details.

1 Like

Thanks @peterg! I’ll check that out.

I’ve updated the tutorial with additional content as I’ve learned more myself and added a section on advanced filters. I hope it’ll come in handy to someone…


this post is actual documentation of script report


Thanks for this @EugeneP. Just found it. It lools cool.

I am going to start working through this. My aim ?

  1. The existing P&L report handles account 5118 Expenses included in valutaion incorrectly
    ( in my view anyway ).
  2. The pie charts on some of the existing reports shows “group” accounts, which is
    not correct in my view. You cant have a pie-chart with “parent” (group) and “child”
    info in one chart.

So I am hoping to address this with my own report perhaps.


@EugeneP Thanks for taking time into this and sharing with the community. Really appreciate the effort. :heart:

1 Like

Thanks a lot for your sharing effort to explain these report details to the community. It’s really awesome to have contributors like you. Profile - EugeneP - ERPNext Forum

1 Like

Thank you sir, it is pretty awesome what u have given to the community

1 Like

Can you explain How to achieve Selectable rows in script report. e.g

Is there any way to remove the truncated from the names of the chart-legend? Lots of wasted space.

Eugene, your document is spectacular and greatly appreciated.

This is a big long-term maintenance problem.

Have you found a way to include Script Reports into backups, for example?

A symlink into the private files directory would work, I think.

1 Like

You can store report files in your custom apps folder. Play with the “Is Standart” and “Module” settings. Then the files will be stored in your custom app’s folder.

1 Like