杨树林 5 years ago
commit 896cc174cc

@ -150,7 +150,9 @@ class CommonWorkDetailIndex extends Component{
]}></CBreadcrumb> ]}></CBreadcrumb>
<div style={{ width:'100%',height:'52px'}} > <div style={{ width:'100%',height:'52px'}} >
<span className=" fl color-black summaryname" title={`${homework_name && homework_name.length > 36 ? homework_name : ''}`}> <span className=" fl color-black summaryname" title={`${homework_name && homework_name.length > 36 ? homework_name : ''}`}
style={{height: 'auto'}}
>
{homework_name} {homework_name}
{/* <Link to={"/courses/"+courseId+"/graduation"+"/graduation_tasks/"}>{homework_name}</Link> */} {/* <Link to={"/courses/"+courseId+"/graduation"+"/graduation_tasks/"}>{homework_name}</Link> */}
</span> </span>

@ -70,7 +70,7 @@ function buildColumns(that, student_works) {
render: (text, record, index) => { render: (text, record, index) => {
return ( return (
<span style={{ minWidth: '50px', display: 'inline-block', textAlign: 'center' }} > <span style={{ minWidth: '50px', display: 'inline-block', textAlign: 'center' }} >
{record.isMine == true ? '我' : (that.state.page - 1) * PAGE_SIZE + index + 1} {record.isMine == true && (student_works && student_works.length) ? '我' : (that.state.page - 1) * PAGE_SIZE + index + 1}
</span> </span>
)}, )},
}, { }, {

@ -92,8 +92,16 @@ class CommonWorkPost extends Component{
} else { } else {
axios.get(url).then((response)=>{ axios.get(url).then((response)=>{
if(response.data.course_id){ if(response.data.course_id){
const mine = {
user_id: response.data.user_id,
user_name: response.data.user_name,
student_id: response.data.user_student_id,
group_name: response.data.group_name,
}
this.setState({ this.setState({
...response.data, ...response.data,
selectmemberslist: [mine],
memberNumMin: response.data.min_num, memberNumMin: response.data.min_num,
memberNumMax: response.data.max_num, memberNumMax: response.data.max_num,
}) })
@ -102,30 +110,6 @@ class CommonWorkPost extends Component{
console.log(error) console.log(error)
}) })
} }
return
const responseData = {
"course_id": 1309,
"course_name": "计算机开发实战课-示例",
"category": {
"category_id": 11551,
"category_name": "分组作业"
},
"homework_status": [
"申诉中"
],
"homework_name": "小米便签的功能改进",
"homework_id": 7013,
"homework_type": "group",
"user_id": 15582,
"user_name": "胡莎莎",
"user_student_id": null,
"group_name": "示例A班"
}
this.setState({
...responseData
})
} }
@ -420,84 +404,6 @@ class CommonWorkPost extends Component{
}).catch((error)=>{ }).catch((error)=>{
console.log(error) console.log(error)
}) })
return
const member = {
"members": [
{
"user_id": 8686,
"user_name": "陈晓婷",
"group_name": "未分班",
"student_id": "2018201801106004",
"commit_status": false
},
{
"user_id": 46220,
"user_name": "刘恩",
"group_name": "未分班",
"student_id": "173139241573",
"commit_status": false
},
{
"user_id": 57106,
"user_name": "曾啸笛",
"group_name": "未分班",
"student_id": "184962010005",
"commit_status": false
},
{
"user_id": 57110,
"user_name": "王玉龙",
"group_name": "未分班",
"student_id": "184962710013",
"commit_status": false
},
{
"user_id": 57280,
"user_name": "陈涛",
"group_name": "未分班",
"student_id": "184962020046",
"commit_status": false
},
{
"user_id": 57341,
"user_name": "何仁杰",
"group_name": "未分班",
"student_id": "18496232002036",
"commit_status": false
},
{
"user_id": 57386,
"user_name": "王震东",
"group_name": "未分班",
"student_id": "1849620100012",
"commit_status": false
},
{
"user_id": 58337,
"user_name": "李游",
"group_name": "未分班",
"student_id": null,
"commit_status": false
},
{
"user_id": 58787,
"user_name": "彭然",
"group_name": "未分班",
"student_id": null,
"commit_status": false
},
{
"user_id": 59553,
"user_name": "李明霞",
"group_name": "未分班",
"student_id": null,
"commit_status": false
}
]
}
this.setState({
members: member.members
})
} }

@ -97,7 +97,7 @@ class WorkDetailPageHeader extends Component{
]}></CBreadcrumb> ]}></CBreadcrumb>
<div style={{ width:'100%',height:'52px'}} > <div style={{ width:'100%',height:'52px'}} >
<span className=" fl color-black summaryname" style={{}}> <span className=" fl color-black summaryname" style={{height: 'auto'}}>
{homework_name} {homework_name}
{/* <Link to={"/courses/"+courseId+"/graduation"+"/graduation_tasks/"}>{homework_name}</Link> */} {/* <Link to={"/courses/"+courseId+"/graduation"+"/graduation_tasks/"}>{homework_name}</Link> */}
</span> </span>

Loading…
Cancel
Save