forked from Open-CT/openscore
fix:self problem arbitration in group
This commit is contained in:
parent
1830168a9e
commit
7ff4b16300
|
@ -1 +1 @@
|
|||
{"C:\\Users\\chen\\go\\src\\open-ct\\controllers":1632587620127206100}
|
||||
{"C:\\Users\\yang\\Desktop\\阅卷系统\\controllers":1632588181225521900}
|
|
@ -17,7 +17,8 @@ export default class index extends Component {
|
|||
state = {
|
||||
questionList: [],
|
||||
tableData: [],
|
||||
count: undefined
|
||||
count: 0,
|
||||
questionIndex:0
|
||||
}
|
||||
|
||||
questionList = () => {
|
||||
|
@ -137,12 +138,15 @@ export default class index extends Component {
|
|||
index = i
|
||||
}
|
||||
}
|
||||
this.setState({
|
||||
questionIndex:index
|
||||
})
|
||||
this.tableData(this.state.questionList[index].QuestionId)
|
||||
}
|
||||
// 选择区
|
||||
|
||||
paperMark =() => {
|
||||
this.props.history.push('/home/group/markTasks/1')
|
||||
this.props.history.push('/home/group/markTasks/1/'+this.state.questionList[this.state.questionIndex].QuestionId)
|
||||
}
|
||||
render() {
|
||||
return (
|
||||
|
|
|
@ -25,10 +25,15 @@ export default class index extends Component {
|
|||
markScore: [],
|
||||
keyTest: [],
|
||||
sampleList: [],
|
||||
samplePaper: []
|
||||
samplePaper: [],
|
||||
QuestionId: undefined,
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
console.log(this.props.match.params)
|
||||
this.setState({
|
||||
QuestionId: parseInt(this.props.match.params.QuestionId)
|
||||
})
|
||||
if (this.props.match.params.type === "1") {
|
||||
this.setState({
|
||||
type: '仲裁卷'
|
||||
|
@ -49,7 +54,7 @@ export default class index extends Component {
|
|||
|
||||
// 仲裁卷
|
||||
getArbitrationTestId = () => {
|
||||
group.arbitrationTestId({ supervisorId: "2" })
|
||||
group.arbitrationTestId({ supervisorId: "2",questionId:parseInt(this.props.match.params.QuestionId) })
|
||||
.then((res) => {
|
||||
if (res.data.status == "10000") {
|
||||
let currentTestId = res.data.data.arbitramentUnmarkListVOList[0].TestId
|
||||
|
@ -67,7 +72,7 @@ export default class index extends Component {
|
|||
|
||||
// 问题卷
|
||||
getProblemTestId = () => {
|
||||
group.problemTestId({ supervisorId: "2" })
|
||||
group.problemTestId({ supervisorId: "2",questionId:parseInt(this.props.match.params.QuestionId) })
|
||||
.then((res) => {
|
||||
if (res.data.status == "10000") {
|
||||
let currentTestId = res.data.data.ProblemUnmarkVOList[0].TestId
|
||||
|
@ -85,12 +90,12 @@ export default class index extends Component {
|
|||
|
||||
// 自评卷
|
||||
getSelfTestId = () => {
|
||||
group.selfTestId({ supervisorId: "2" })
|
||||
group.selfTestId({ supervisorId: "2",questionId:parseInt(this.props.match.params.QuestionId) })
|
||||
.then((res) => {
|
||||
if (res.data.status == "10000") {
|
||||
let currentTestId = res.data.data.ProblemUnmarkVOList[0].TestId
|
||||
let currentTestId = res.data.data.selfUnmarkVOList[0].TestId
|
||||
this.setState({
|
||||
count: res.data.data.ProblemUnmarkVOList.length,
|
||||
count: res.data.data.selfUnmarkVOList.length,
|
||||
currentTestId
|
||||
})
|
||||
this.getCurrentPaper();
|
||||
|
|
|
@ -17,7 +17,8 @@ export default class index extends Component {
|
|||
state = {
|
||||
questionList: [],
|
||||
tableData: [],
|
||||
count: 0
|
||||
count: 0,
|
||||
questionIndex:0
|
||||
}
|
||||
|
||||
questionList = () => {
|
||||
|
@ -102,12 +103,15 @@ export default class index extends Component {
|
|||
index = i
|
||||
}
|
||||
}
|
||||
this.setState({
|
||||
questionIndex:index
|
||||
})
|
||||
this.tableData(this.state.questionList[index].QuestionId)
|
||||
}
|
||||
// 选择区
|
||||
|
||||
paperMark =() => {
|
||||
this.props.history.push('/home/group/markTasks/3')
|
||||
this.props.history.push('/home/group/markTasks/3/'+this.state.questionList[this.state.questionIndex].QuestionId)
|
||||
}
|
||||
render() {
|
||||
return (
|
||||
|
|
|
@ -38,7 +38,8 @@ export default class index extends Component {
|
|||
state = {
|
||||
questionList: [],
|
||||
tableData: [],
|
||||
count: undefined
|
||||
count: 0,
|
||||
questionIndex:0
|
||||
}
|
||||
|
||||
questionList = () => {
|
||||
|
@ -107,12 +108,15 @@ export default class index extends Component {
|
|||
index = i
|
||||
}
|
||||
}
|
||||
this.setState({
|
||||
questionIndex:index
|
||||
})
|
||||
this.tableData(this.state.questionList[index].QuestionId)
|
||||
}
|
||||
// 选择区
|
||||
|
||||
paperMark =() => {
|
||||
this.props.history.push('/home/group/markTasks/2')
|
||||
this.props.history.push('/home/group/markTasks/2/'+this.state.questionList[this.state.questionIndex].QuestionId)
|
||||
}
|
||||
render() {
|
||||
return (
|
||||
|
|
|
@ -273,7 +273,7 @@ export default class index extends Component {
|
|||
<Route path="/home/group/arbitration" component={arbitration} exact></Route>
|
||||
<Route path="/home/group/marking" component={marking}></Route>
|
||||
<Route path="/home/group/problem" component={problem} exact></Route>
|
||||
<Route path="/home/group/markTasks/:type" component={markTasks} exact></Route>
|
||||
<Route path="/home/group/markTasks/:type/:QuestionId" component={markTasks} exact></Route>
|
||||
|
||||
<Route path="/home/management/question" component={question} exact></Route>
|
||||
<Route path="/home/management/paper" component={paper}></Route>
|
||||
|
|
Loading…
Reference in New Issue