@@ -7,6 +7,7 @@ import TimeSlider from "./TimeSlider";
77import LogTable from "./LogTable" ;
88import ToggleBar from "./ToggleBar" ;
99import TripLogs from "./TripLogs" ;
10+ import TaskLogs from "./TaskLogs" ;
1011import CloudLogging from "./CloudLogging" ;
1112import {
1213 uploadFile ,
@@ -59,7 +60,10 @@ class App extends React.Component {
5960 activeMenuIndex : null ,
6061 initialMapBounds : null ,
6162 selectedRowIndexPerDataset : [ - 1 , - 1 , - 1 , - 1 , - 1 ] ,
62- currentLogData : this . props . logData ,
63+ currentLogData : {
64+ ...this . props . logData ,
65+ taskLogs : new TaskLogs ( this . props . logData . tripLogs ) ,
66+ } ,
6367 dynamicMarkerLocations : { } ,
6468 visibleToggles : getVisibleToggles ( this . props . logData . solutionType ) ,
6569 } ;
@@ -454,12 +458,14 @@ class App extends React.Component {
454458 if ( this . state . activeDatasetIndex === index ) {
455459 log ( `handlePruneClick: Pruning active dataset ${ index } , updating state.` ) ;
456460 const tripLogs = new TripLogs ( data . rawLogs , data . solutionType ) ;
461+ const taskLogs = new TaskLogs ( tripLogs ) ;
457462
458463 this . setState (
459464 ( prevState ) => ( {
460465 currentLogData : {
461466 ...prevState . currentLogData ,
462467 tripLogs : tripLogs ,
468+ taskLogs : taskLogs ,
463469 solutionType : data . solutionType ,
464470 } ,
465471 } ) ,
@@ -697,6 +703,7 @@ class App extends React.Component {
697703 const data = await getUploadedData ( index ) ;
698704 if ( data && data . rawLogs && Array . isArray ( data . rawLogs ) && data . rawLogs . length > 0 ) {
699705 const tripLogs = new TripLogs ( data . rawLogs , data . solutionType ) ;
706+ const taskLogs = new TaskLogs ( tripLogs ) ;
700707 const newVisibleToggles = getVisibleToggles ( data . solutionType ) ;
701708
702709 let newToggleOptions = { ...this . state . toggleOptions } ;
@@ -720,6 +727,7 @@ class App extends React.Component {
720727 currentLogData : {
721728 ...prevState . currentLogData ,
722729 tripLogs : tripLogs ,
730+ taskLogs : taskLogs ,
723731 solutionType : data . solutionType ,
724732 } ,
725733 visibleToggles : newVisibleToggles ,
0 commit comments