@@ -37,7 +37,6 @@ const GrafanaEventChart: React.FC<EventChartProps> = React.memo(props => {
3737 console . log ( "uid: " , uid )
3838 console . log ( "parsedName: " , parsedName )
3939
40- // make request to update dashboard
4140 const handleSelectionChange = async ( event ) => {
4241 setType ( [ ...type , graphType ] ) ;
4342 await fetch ( 'http://localhost:1111/api/updateDashboard' , {
@@ -108,51 +107,30 @@ const TimeSeries = (uid, parsedName, graphType, timeFrame) => {
108107}
109108
110109const 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 >
115111}
116112
117113const 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 >
122115}
123116
124117const 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 >
129119}
130120
131121const 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 >
136123}
137124
138125const 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 >
143127}
144128
145129const 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 >
150131}
151132
152133const 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 >
157135}
158136export default GrafanaEventChart ;
0 commit comments