mirror of
https://git.mirrors.martin98.com/https://github.com/SigNoz/signoz
synced 2025-08-15 20:35:55 +08:00
fix: the legend and value issue (#3789)
Co-authored-by: Palash Gupta <palashgdev@gmail.com>
This commit is contained in:
parent
c55be0e392
commit
176d01544e
@ -63,10 +63,6 @@ const getChartData = ({
|
|||||||
}),
|
}),
|
||||||
);
|
);
|
||||||
|
|
||||||
const allLabels = response
|
|
||||||
.map((e) => e.map((e) => e.label))
|
|
||||||
.reduce((a, b) => [...a, ...b], []);
|
|
||||||
|
|
||||||
const modifiedData = response
|
const modifiedData = response
|
||||||
.flat()
|
.flat()
|
||||||
.sort((a, b) => {
|
.sort((a, b) => {
|
||||||
@ -89,6 +85,8 @@ const getChartData = ({
|
|||||||
? modifiedData.slice(0, limit)
|
? modifiedData.slice(0, limit)
|
||||||
: modifiedData;
|
: modifiedData;
|
||||||
|
|
||||||
|
const allLabels = modifiedData.map((e) => e.label);
|
||||||
|
|
||||||
const updatedDataSet = updatedSortedData.map((e, index) => {
|
const updatedDataSet = updatedSortedData.map((e, index) => {
|
||||||
const datasetBaseConfig = {
|
const datasetBaseConfig = {
|
||||||
index,
|
index,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user