Open satyam20satyam opened 7 months ago
This is the request body.
{
"options": {
"lang": {
"thousandsSep": ",",
"month": [
" 1 月",
" 2 月",
" 3 月",
" 4 月",
" 5 月",
" 6 月",
" 7 月",
" 8 月",
" 9 月",
" 10 月",
" 11 月",
" 12 月"
],
"shortMonths": [
" 1 月",
" 2 月",
" 3 月",
" 4 月",
" 5 月",
" 6 月",
" 7 月",
" 8 月",
" 9 月",
" 10 月",
" 11 月",
" 12 月"
],
"weekdays": [
"星期日",
" 星期一",
" 星期二",
" 星期三",
" 星期四",
" 星期五",
" 星期六"
],
"shortWeekdays": [
"周日",
" 周一",
" 周二",
" 周三",
" 周四",
" 周五",
" 周六"
],
"decimalPoint": "."
},
"chart": {
"type": "area"
},
"title": {
"text": "设备总体趋势",
"useHTML": true,
"align": "center",
"style": {
"color": "#333333",
"fontSize": "16px",
"fontFamily": "Roboto",
"fontWeight": "bold",
"textTransform": "CAPITALIZE"
}
},
"yAxis": {
"lineWidth": 0,
"allowDecimals": false,
"title": {
"enabled": false
},
"opposite": true,
"labels": {
"format": "{value}"
}
},
"xAxis": {
"type": "datetime",
"tickPixelInterval": 1,
"dateTimeLabelFormats": {
"hour": "%I <br> %p",
"day": "%e <br> %b",
"month": "%b <br> %Y"
},
"lineWidth": 1,
"lineColor": "#C0C0C0",
"tickLength": 1,
"tickWidth": 1
},
"legend": {
"align": "center",
"verticalAlign": "bottom",
"layout": "horizontal",
"symbolWidth": 4,
"itemDistance": 30,
"symbolPadding": 10,
"symbolRadius": 0,
"itemStyle": {
"color": "#000000",
"fontWeight": "normal",
"fontFamily": "Roboto"
}
},
"plotOptions": {
"area": {
"stacking": "normal",
"lineColor": "#666666",
"lineWidth": 1,
"borderRadius": 0,
"marker": {
"lineWidth": 1,
"lineColor": "#666666"
},
"events": {}
}
},
"series": [
{
"name": "入站到客户",
"data": [
[
1677628800000,
16
],
[
1680307200000,
0
],
[
1682899200000,
47
]
],
"color": "#E66268",
"marker": {
"symbol": "square",
"radius": 4
}
},
{
"name": "操作中",
"data": [
[
1677628800000,
16
],
[
1680307200000,
10
],
[
1682899200000,
0
]
],
"color": "#005A82",
"marker": {
"symbol": "square",
"radius": 4
}
},
{
"name": "维修中",
"data": [
[
1677628800000,
96
],
[
1680307200000,
110
],
[
1682899200000,
47
],
[
1685577600000,
76
],
[
1688169600000,
93
],
[
1690848000000,
103
],
[
1693526400000,
151
],
[
1696118400000,
70
],
[
1698796800000,
91
],
[
1701388800000,
122
],
[
1704067200000,
75
],
[
1706745600000,
97
]
],
"color": "#333333",
"marker": {
"symbol": "square",
"radius": 4
}
}
],
"tooltip": {
"shared": true,
"dateTimeLabelFormats": {
"hour": "%I %p",
"day": "%b %e, %Y ",
"month": "%b %Y"
},
"useHTML": true,
"borderWidth": 1,
"borderColor": "#007CB0",
"style": {
"padding": 5
}
}
}
}
We are using npm package
highcharts-export-server
in our express based server. Axis label is not getting translated as per selected lang, this is same as https://github.com/highcharts/node-export-server/issues/434 which is fixed and released in 3.0.3 version but while we are using version 3.0.3 or above, we are getting error while starting the server. We drilled more into the code and found it is happening because coreScript is undefined.TypeError: Cannot read properties of undefined (reading 'map').
After that server got started with this above error and we tried to export the chart and got another error
This is the request body we are passing and below are the configurations.
The same configuration is working fine in npm
highcharts-export-server v3.0.1
with translation issue.Can someone please help me here to unblock me.