Merge branch 'dev_aliyun' of https://bdgit.educoder.net/Hjqreturn/educoder into dev_aliyun

dev_forum
hjm 5 years ago
commit 204fa93e09

@ -136,7 +136,7 @@ class CommonWorkDetailIndex extends Component{
DownloadMessageval:undefined
})
}
bindRef = ref => { this.child = ref };
render() {
@ -171,8 +171,10 @@ class CommonWorkDetailIndex extends Component{
let params = {}
if (isListModule) {
// TODO
// params = this.refs.commonWorkList._getRequestParams()
params =this.child._getRequestParams()!==undefined?this.child._getRequestParams():{};
}
// console.log("普通作业176176176");
// console.log(params);
let exportUrl = `/homework_commons/${workId}/works_list.zip?${queryString.stringify(params)}`
let exportResultUrl = `/homework_commons/${workId}/works_list.xlsx?${queryString.stringify(params)}`
return (
@ -356,7 +358,7 @@ class CommonWorkDetailIndex extends Component{
{/* 作品列表 */}
<Route exact path="/courses/:coursesId/common_homeworks/:workId/list"
render={
(props) => (<CommonWorkList ref="commonWorkList" {...this.props} {...props} {...this.state} {...commonHandler}/>)
(props) => (<CommonWorkList ref="commonWorkList" triggerRef={this.bindRef} {...this.props} {...props} {...this.state} {...commonHandler}/>)
}
></Route>

@ -401,7 +401,7 @@ class CommonWorkList extends Component{
this.fetchList()
on('commonwork_fetch_all', this.fetchAllListener)
$("html").animate({ scrollTop: $('html').scrollTop() - 100 })
this.props.triggerRef(this);
}
componentWillUnmount() {
off('commonwork_fetch_all', this.fetchAllListener)

Loading…
Cancel
Save