Reputation: 315
How can I get decimal tick labels on X axis
the decimal values should have only one decimal digit.
can I achieve it?
please suggest me
thank u
Upvotes: 0
Views: 4105
Reputation: 37061
You should use the extender
of the <p:barChart
, like this:
<p:barChart value="#{myBean.myModel}" widgetVar="myBarChart" extender="my_ext"/>
<script type="text/javascript">
function my_ext() {
this.cfg.axes.xaxis.tickOptions = {
formatString : '%#.1f'
};
}
</script>
Upvotes: 2