@@ -27,7 +27,7 @@ import AceEditor from "react-ace";
27
27
import UAParser from "ua-parser-js" ;
28
28
import MarkdownRenderer from "./MarkdownRenderer" ;
29
29
import { useRecoilValue } from "recoil" ;
30
- import { appsState , endpointsState } from "../../data/atoms" ;
30
+ import { appsState } from "../../data/atoms" ;
31
31
import { axios } from "../../data/axios" ;
32
32
import { ReactComponent as DiscordIcon } from "../../assets/images/icons/discord.svg" ;
33
33
import { ReactComponent as SlackIcon } from "../../assets/images/icons/slack.svg" ;
@@ -155,11 +155,10 @@ const ExpandedRowItem = ({ label, value, content_type = null }) => {
155
155
) ;
156
156
} ;
157
157
158
- const FilterBar = ( { apps, sessions, endpoints , users, onFilter } ) => {
158
+ const FilterBar = ( { apps, sessions, users, onFilter } ) => {
159
159
const [ selectedApp , setSelectedApp ] = useState ( null ) ;
160
160
const [ selectedSession , setSelectedSession ] = useState ( null ) ;
161
161
const [ selectedUser , setSelectedUser ] = useState ( null ) ;
162
- const [ selectedEndpoint , setSelectedEndpoint ] = useState ( null ) ;
163
162
164
163
return (
165
164
< Stack
@@ -279,57 +278,6 @@ const FilterBar = ({ apps, sessions, endpoints, users, onFilter }) => {
279
278
setSelectedUser ( value ) ;
280
279
} }
281
280
/>
282
- < Autocomplete
283
- id = "endpoint-selector"
284
- sx = { { width : 250 } }
285
- options = { endpoints . filter ( ( ep ) => ! ep . is_app && ep . version > 0 ) }
286
- autoHighlight
287
- getOptionLabel = { ( option ) => option . name || "" }
288
- renderInput = { ( params ) => (
289
- < TextField
290
- { ...params }
291
- size = "small"
292
- label = "Endpoint"
293
- inputProps = { {
294
- ...params . inputProps ,
295
- autoComplete : "new-password" ,
296
- } }
297
- />
298
- ) }
299
- groupBy = { ( option ) => option . parent_uuid }
300
- renderGroup = { ( params ) => [
301
- < Typography
302
- key = { params . key }
303
- sx = { {
304
- fontWeight : 600 ,
305
- fontSize : "0.8rem" ,
306
- color : "#666" ,
307
- padding : "10px" ,
308
- } }
309
- >
310
- { endpoints . find ( ( ep ) => ep . uuid === params . group ) ?. name }
311
- </ Typography > ,
312
- params . children ,
313
- ] }
314
- renderOption = { ( props , option ) => (
315
- < Box
316
- component = "li"
317
- sx = { {
318
- fontSize : 14 ,
319
- "& > span" : {
320
- marginRight : 2 ,
321
- fontSize : 18 ,
322
- } ,
323
- } }
324
- { ...props }
325
- >
326
- { option . version } : { option . description }
327
- </ Box >
328
- ) }
329
- onChange = { ( event , value ) => {
330
- setSelectedEndpoint ( value ) ;
331
- } }
332
- />
333
281
< Button
334
282
type = "primary"
335
283
style = { {
@@ -341,7 +289,7 @@ const FilterBar = ({ apps, sessions, endpoints, users, onFilter }) => {
341
289
app_uuid : selectedApp ?. uuid || null ,
342
290
session_key : selectedSession ?. name || null ,
343
291
request_user_email : selectedUser ?. name || null ,
344
- endpoint_uuid : selectedEndpoint ?. uuid || null ,
292
+ endpoint_uuid : null ,
345
293
} ) ;
346
294
} }
347
295
>
@@ -354,7 +302,6 @@ const FilterBar = ({ apps, sessions, endpoints, users, onFilter }) => {
354
302
export function AppRunHistoryTimeline ( props ) {
355
303
const { filter, filteredColumns, showFilterBar } = props ;
356
304
const apps = useRecoilValue ( appsState ) ;
357
- const endpoints = useRecoilValue ( endpointsState ) ;
358
305
const [ rows , setRows ] = useState ( [ ] ) ;
359
306
const [ expandedRows , setExpandedRows ] = useState ( { } ) ;
360
307
const [ loading , setLoading ] = useState ( false ) ;
@@ -375,10 +322,7 @@ export function AppRunHistoryTimeline(props) {
375
322
apps . find ( ( app ) => app . uuid === row . app_uuid ) ?. name || "Deleted App"
376
323
) ;
377
324
}
378
- return (
379
- endpoints . find ( ( ep ) => ep . uuid === row . endpoint_uuid ) ?. name ||
380
- "Playground"
381
- ) ;
325
+ return "Playground" ;
382
326
} else if ( column . id === "type" ) {
383
327
return (
384
328
< Tooltip title = { row . app_uuid !== null ? "App" : "Endpoint" } >
@@ -534,7 +478,6 @@ export function AppRunHistoryTimeline(props) {
534
478
. map ( ( row ) => row . request_user_email ) ,
535
479
) ,
536
480
) . map ( ( request_user_email ) => ( { name : request_user_email } ) ) }
537
- endpoints = { endpoints }
538
481
onFilter = { ( filters ) => setFilters ( { ...filters , ...{ page : 1 } } ) }
539
482
/>
540
483
< Divider />
0 commit comments