@@ -27,7 +27,7 @@ import AceEditor from "react-ace";
2727import UAParser from "ua-parser-js" ;
2828import MarkdownRenderer from "./MarkdownRenderer" ;
2929import { useRecoilValue } from "recoil" ;
30- import { appsState , endpointsState } from "../../data/atoms" ;
30+ import { appsState } from "../../data/atoms" ;
3131import { axios } from "../../data/axios" ;
3232import { ReactComponent as DiscordIcon } from "../../assets/images/icons/discord.svg" ;
3333import { ReactComponent as SlackIcon } from "../../assets/images/icons/slack.svg" ;
@@ -155,11 +155,10 @@ const ExpandedRowItem = ({ label, value, content_type = null }) => {
155155 ) ;
156156} ;
157157
158- const FilterBar = ( { apps, sessions, endpoints , users, onFilter } ) => {
158+ const FilterBar = ( { apps, sessions, users, onFilter } ) => {
159159 const [ selectedApp , setSelectedApp ] = useState ( null ) ;
160160 const [ selectedSession , setSelectedSession ] = useState ( null ) ;
161161 const [ selectedUser , setSelectedUser ] = useState ( null ) ;
162- const [ selectedEndpoint , setSelectedEndpoint ] = useState ( null ) ;
163162
164163 return (
165164 < Stack
@@ -279,57 +278,6 @@ const FilterBar = ({ apps, sessions, endpoints, users, onFilter }) => {
279278 setSelectedUser ( value ) ;
280279 } }
281280 />
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- />
333281 < Button
334282 type = "primary"
335283 style = { {
@@ -341,7 +289,7 @@ const FilterBar = ({ apps, sessions, endpoints, users, onFilter }) => {
341289 app_uuid : selectedApp ?. uuid || null ,
342290 session_key : selectedSession ?. name || null ,
343291 request_user_email : selectedUser ?. name || null ,
344- endpoint_uuid : selectedEndpoint ?. uuid || null ,
292+ endpoint_uuid : null ,
345293 } ) ;
346294 } }
347295 >
@@ -354,7 +302,6 @@ const FilterBar = ({ apps, sessions, endpoints, users, onFilter }) => {
354302export function AppRunHistoryTimeline ( props ) {
355303 const { filter, filteredColumns, showFilterBar } = props ;
356304 const apps = useRecoilValue ( appsState ) ;
357- const endpoints = useRecoilValue ( endpointsState ) ;
358305 const [ rows , setRows ] = useState ( [ ] ) ;
359306 const [ expandedRows , setExpandedRows ] = useState ( { } ) ;
360307 const [ loading , setLoading ] = useState ( false ) ;
@@ -375,10 +322,7 @@ export function AppRunHistoryTimeline(props) {
375322 apps . find ( ( app ) => app . uuid === row . app_uuid ) ?. name || "Deleted App"
376323 ) ;
377324 }
378- return (
379- endpoints . find ( ( ep ) => ep . uuid === row . endpoint_uuid ) ?. name ||
380- "Playground"
381- ) ;
325+ return "Playground" ;
382326 } else if ( column . id === "type" ) {
383327 return (
384328 < Tooltip title = { row . app_uuid !== null ? "App" : "Endpoint" } >
@@ -534,7 +478,6 @@ export function AppRunHistoryTimeline(props) {
534478 . map ( ( row ) => row . request_user_email ) ,
535479 ) ,
536480 ) . map ( ( request_user_email ) => ( { name : request_user_email } ) ) }
537- endpoints = { endpoints }
538481 onFilter = { ( filters ) => setFilters ( { ...filters , ...{ page : 1 } } ) }
539482 />
540483 < Divider />
0 commit comments