@@ -37,7 +37,6 @@ const GrafanaEventChart: React.FC<EventChartProps> = React.memo(props => {
37
37
console . log ( "uid: " , uid )
38
38
console . log ( "parsedName: " , parsedName )
39
39
40
- // make request to update dashboard
41
40
const handleSelectionChange = async ( event ) => {
42
41
setType ( [ ...type , graphType ] ) ;
43
42
await fetch ( 'http://localhost:1111/api/updateDashboard' , {
@@ -108,51 +107,30 @@ const TimeSeries = (uid, parsedName, graphType, timeFrame) => {
108
107
}
109
108
110
109
const BarChart = ( uid , parsedName , graphType , timeFrame ) => {
111
- < >
112
- return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
113
- < hr />
114
- </ >
110
+ return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
115
111
}
116
112
117
113
const Stat = ( uid , parsedName , graphType , timeFrame ) => {
118
- < >
119
- return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
120
- < hr />
121
- </ >
114
+ return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
122
115
}
123
116
124
117
const Gauge = ( uid , parsedName , graphType , timeFrame ) => {
125
- < >
126
- return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
127
- < hr />
128
- </ >
118
+ return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
129
119
}
130
120
131
121
const Table = ( uid , parsedName , graphType , timeFrame ) => {
132
- < >
133
- return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
134
- < hr />
135
- </ >
122
+ return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
136
123
}
137
124
138
125
const Histogram = ( uid , parsedName , graphType , timeFrame ) => {
139
- < >
140
- return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
141
- < hr />
142
- </ >
126
+ return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
143
127
}
144
128
145
129
const PieChart = ( uid , parsedName , graphType , timeFrame ) => {
146
- < >
147
- return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
148
- < hr />
149
- </ >
130
+ return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
150
131
}
151
132
152
133
const AlertList = ( uid , parsedName , graphType , timeFrame ) => {
153
- < >
154
- return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
155
- < hr />
156
- </ >
134
+ return < iframe src = { `http://localhost:32000/d-solo/${ uid } /${ parsedName } ?orgId=1&refresh=10s&from=now-${ timeFrame } &to=now&panelId=1${ graphType } ` } width = "800" height = "500" > </ iframe >
157
135
}
158
136
export default GrafanaEventChart ;
0 commit comments