diff --git a/SAS/TMSS/frontend/tmss_webapp/src/routes/Task/view.js b/SAS/TMSS/frontend/tmss_webapp/src/routes/Task/view.js index 3b30d66c487fb9b070ccf587998e2da8c68c5b81..8a5fe8ea36ca313089e04a5154f7d7899a37d83b 100644 --- a/SAS/TMSS/frontend/tmss_webapp/src/routes/Task/view.js +++ b/SAS/TMSS/frontend/tmss_webapp/src/routes/Task/view.js @@ -71,11 +71,8 @@ export class TaskView extends Component { } componentDidMount() { - // const taskId = this.props.location.state?this.props.location.state.id:this.state.taskId; - // let taskType = this.props.location.state?this.props.location.state.type:this.state.taskType; - // taskType = taskType?taskType:'draft'; const taskId = this.props.location.state?this.props.location.state.id:this.state.taskId; - let taskType = this.props.location.state?this.props.location.state.type:this.state.taskType; + let taskType = this.props.location.state && this.props.location.state.type?this.props.location.state.type:this.state.taskType; taskType = taskType?taskType:'draft'; if (taskId && taskType) {