You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by GitBox <gi...@apache.org> on 2020/02/23 22:17:12 UTC

[GitHub] [incubator-echarts] toddtsic commented on issue #10854: Comma separator for thousand cannot shown on bar chart data.

toddtsic commented on issue #10854: Comma separator for thousand cannot shown on bar chart data.
URL: https://github.com/apache/incubator-echarts/issues/10854#issuecomment-590122894
 
 
   I'm having the same problem, and I believe my data is in the correct format...
   
   bar chart options:
   ```
   {
     "title": {
       "text": "Payments By Year-Month"
     },
     "tooltip": {
       "trigger": "axis"
     },
     "grid": {
       "left": "3%",
       "right": "4%",
       "containLabel": true
     },
     "toolbox": {
       "feature": {
         "saveAsImage": true
       }
     },
     "xAxis": {
       "type": "category",
       "axisTick": {
         "alignWithLabel": true
       },
       "data": [
         "2019-07",
         "2019-08",
         "2019-09",
         "2019-10",
         "2019-11",
         "2019-12",
         "2020-01"
       ]
     },
     "yAxis": {
       "type": "value",
       "axisLabel": {
         "formatter": "${value}"
       }
     },
     "series": [
       {
         "type": "bar",
         "data": [
           41700,
           39106.15,
           8322.9,
           52273.65,
           11095.4,
           5049.85,
           37690.22
         ],
         "label": {
           "normal": {
             "show": true,
             "formatter": "${c}"
           }
         }
       }
     ]
   }
   
   Resulting image:
   ![image](https://user-images.githubusercontent.com/9937583/75121232-55cb1880-564f-11ea-9561-56b142fdea50.png)
   
   the formatter for y-axis works fine, and formatter for bar label does add "$", but no commas in bar label number.
   
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org