There is no option for formatting the date in horizontal axis in bar component in Report module.
I want to show only yyyy/DD/MM and hide time section. How can I do this?
I have the same problem. I would also like to rotate the date 45° or 90°.
I enabled scripting and put this code into the def configureChart(data, chart) script:
plot = chart.getPlot() axis = plot.getDomainAxis() axis.setCategoryLabelPositions(CategoryLabelPositions.UP_45)
According to JFreeChart this should work but it doesn’t.
from org.jfree.chart.axis import CategoryLabelPositions
and then it worked
I formatted my date in my SQL query. Hopefully the rotate angle script will help you get to date formatting.