javascript - Chart.js label value -


i have question, have idea, how change chart.js label value format?

screenshot: enter image description here

how change it, show not "acw (sec): 10" but "acw: 10sec"

code looks like:

var doughnutdataacw = [                 {                     value: <?php echo gmdate("s", $singleacw); ?>,                     color: "#35df6b",                     highlight: "#06cc45",                     label: "acw (sec)"                 } 

you can use tooltiptemplate option:

    tooltiptemplate: "acw: <%=value%>sec" 

if need acw part come label:

    tooltiptemplate: "<%=label%>: <%=value%>sec" 

Comments

Popular posts from this blog

ruby - Trying to change last to "x"s to 23 -

jquery - Clone last and append item to closest class -

c - Unrecognised emulation mode: elf_i386 on MinGW32 -