时间不传递的问题

courseware
dinglink 5 years ago
parent 486cb8a25c
commit d18f1dad2f

@ -133,11 +133,9 @@ class TPIContextProvider extends Component {
}) })
} }
componentWillMount () {
// 拦截判断是否离开当前页面
}
componentWillUnmount() { componentWillUnmount() {
this.costTimeInterval && window.clearInterval(this.costTimeInterval) this.costTimeInterval && window.clearInterval(this.costTimeInterval)
} }
componentDidMount() { componentDidMount() {
@ -195,6 +193,8 @@ class TPIContextProvider extends Component {
if (window.location.port == 3007) { if (window.location.port == 3007) {
testPath = 'http://test-newweb.educoder.net' testPath = 'http://test-newweb.educoder.net'
} }
// var url = `${testPath}/api/v1/games/${ game.identifier }/cost_time` // var url = `${testPath}/api/v1/games/${ game.identifier }/cost_time`
var url = `${testPath}/api/tasks/${ game.identifier }/cost_time${getRandomNumber()}` var url = `${testPath}/api/tasks/${ game.identifier }/cost_time${getRandomNumber()}`
window.$.ajax({ window.$.ajax({

@ -235,7 +235,8 @@ class Video extends Component {
className="showVideoModal" className="showVideoModal"
width={800 - 1} width={800 - 1}
> >
{videoId && <VideoPanel src={this.state.videourl===null?videoId.file_url:Base64.decode(videoId.file_url)} videoId={videoId.videoId} courseId={CourseId} logWatchHistory={logWatchHistory} />} {this.state.videourl===null?'':videoId &&<VideoPanel src={Base64.decode(videoId.file_url)} videoId={videoId.videoId} courseId={CourseId} logWatchHistory={logWatchHistory} />}
{/* {videoId && <VideoPanel src={Base64.decode(videoId.file_url)} videoId={videoId.videoId} courseId={CourseId} logWatchHistory={logWatchHistory} />} */}
{this.props.isAdmin()===false?'':<div className="df copyLine" style={{}}> {this.props.isAdmin()===false?'':<div className="df copyLine" style={{}}>
<Input value={_inputValue} <Input value={_inputValue}

Loading…
Cancel
Save