|
|
@ -89,7 +89,7 @@ const handleUpdatePaper = async (rules_id: number, paper_uuid: number, paper_id:
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
const handleRemoveTempQuestion = async (paper_uuid: number, question_ids: [{question_id: number}]) => {
|
|
|
|
const handleRemoveTempQuestion = async (paper_uuid: number, question_ids: [{question_id: number}]) => {
|
|
|
|
const hide = message.loading('正在删除');
|
|
|
|
const hide = message.loading('正在删除');
|
|
|
|
console.log('uuidPaper', paper_uuid)
|
|
|
|
//console.log('uuidPaper', paper_uuid)
|
|
|
|
if (!question_ids || !paper_uuid) return true;
|
|
|
|
if (!question_ids || !paper_uuid) return true;
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
const {code, msg} = await delTempQuestion({
|
|
|
|
const {code, msg} = await delTempQuestion({
|
|
|
@ -139,6 +139,7 @@ const handleExchangeSortNum = async (paper_uuid: number, question_ids: string, r
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
const labels = ['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K']
|
|
|
|
const labels = ['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K']
|
|
|
|
|
|
|
|
|
|
|
|
// 模拟考试规则维护
|
|
|
|
// 模拟考试规则维护
|
|
|
|
export default () => {
|
|
|
|
export default () => {
|
|
|
|
|
|
|
|
|
|
|
@ -488,11 +489,12 @@ export default () => {
|
|
|
|
headerBordered
|
|
|
|
headerBordered
|
|
|
|
>
|
|
|
|
>
|
|
|
|
<Space direction="vertical" style={{ width: '100%', padding: '24px 48px' }}>
|
|
|
|
<Space direction="vertical" style={{ width: '100%', padding: '24px 48px' }}>
|
|
|
|
|
|
|
|
{console.log('questions:::', questionType)}
|
|
|
|
{questions && questions.map((item, idx) => (
|
|
|
|
{questions && questions.map((item, idx) => (
|
|
|
|
item &&
|
|
|
|
item &&
|
|
|
|
<div style={{ border: 'none' }}>
|
|
|
|
<div style={{ border: 'none' }}>
|
|
|
|
<Typography style={{ marginBottom: 16, fontSize: 14, padding: '15px 15px 0 15px' }}>
|
|
|
|
<Typography style={{ marginBottom: 16, fontSize: 14, padding: '15px 15px 0 15px' }}>
|
|
|
|
{idx + 1}. {item?.question_stem}
|
|
|
|
{idx + 1}. ({questionType?.filter(t=>(Number(t?.code) === item?.question_type))[0]?.name}, 分值 {scoreData?.filter(val=>(val.question_type === Number(item?.question_type)))[0]?.score}) {item?.question_stem}
|
|
|
|
</Typography>
|
|
|
|
</Typography>
|
|
|
|
{(item?.question_type === 0) && // 单选题
|
|
|
|
{(item?.question_type === 0) && // 单选题
|
|
|
|
<div style={{ padding: '0 15px 15px 15px' }}>
|
|
|
|
<div style={{ padding: '0 15px 15px 15px' }}>
|
|
|
@ -581,7 +583,7 @@ export default () => {
|
|
|
|
<Divider style={{ margin: '6px 0', opacity: 0.5 }} />
|
|
|
|
<Divider style={{ margin: '6px 0', opacity: 0.5 }} />
|
|
|
|
<Space direction="vertical">
|
|
|
|
<Space direction="vertical">
|
|
|
|
{questionType.map((item) => {
|
|
|
|
{questionType.map((item) => {
|
|
|
|
return <Typography>{item?.name} 共 {typeQuestionCount[Number(item.code)]} 题 {scoreData?.filter(val=>(val.question_type === Number(item?.code)))[0]?.score} 分</Typography>
|
|
|
|
return <Typography>{item?.name} 共 {typeQuestionCount[Number(item.code)]} 题, 共 {typeQuestionCount[Number(item.code)] * scoreData?.filter(val=>(val.question_type === Number(item?.code)))[0]?.score} 分</Typography>
|
|
|
|
}
|
|
|
|
}
|
|
|
|
)}
|
|
|
|
)}
|
|
|
|
</Space>
|
|
|
|
</Space>
|
|
|
@ -742,6 +744,7 @@ export default () => {
|
|
|
|
//console.log('paper', paper)
|
|
|
|
//console.log('paper', paper)
|
|
|
|
// setUuidPaper(paper?.paper_uuid)
|
|
|
|
// setUuidPaper(paper?.paper_uuid)
|
|
|
|
// message.success('提交成功');
|
|
|
|
// message.success('提交成功');
|
|
|
|
|
|
|
|
runScore({rules_id: rulesId}) //
|
|
|
|
handleScoreModalVisible(false)
|
|
|
|
handleScoreModalVisible(false)
|
|
|
|
return true;
|
|
|
|
return true;
|
|
|
|
}}
|
|
|
|
}}
|
|
|
|