dev_jupyter
杨树林 5 years ago
parent ad26a2dad2
commit 351958f411

@ -66,6 +66,9 @@ class Paperreview_single extends Component {
let {questions,totalscore,total,items} = this.state; let {questions,totalscore,total,items} = this.state;
let {objectsingle} =this.props; let {objectsingle} =this.props;
// //console.log(params); // //console.log(params);
const objectsingleid=objectsingle.id;
const objectsinglescore=`${objectsingle.score}分)`;
return ( return (
<div className="w100s borderwdswuh mt25 mb20 pd20 " style={{ <div className="w100s borderwdswuh mt25 mb20 pd20 " style={{
minHeight: "114px", minHeight: "114px",
@ -74,9 +77,9 @@ class Paperreview_single extends Component {
{/*顶部*/} {/*顶部*/}
<div className="w100s sortinxdirection "> <div className="w100s sortinxdirection ">
<div className=" sortinxdirection "> {/*<div className=" sortinxdirection ">*/}
<p className="cretitlecolrlis lh28">{objectsingle.id}</p><p className="cretitlecolrlisobj lh28">{objectsingle.score}</p> {/* <p className="cretitlecolrlis lh28">{objectsingleid}</p>、<p className="cretitlecolrlisobj lh28">{objectsinglescore}分)</p>*/}
</div> {/*</div>*/}
<style> <style>
{ {
` `
@ -95,38 +98,57 @@ class Paperreview_single extends Component {
` `
} }
</style> </style>
<div className=" lh28 listjihetixingstit markdown-body cretitlecolrlist" style={{wordBreak: "break-word"}} dangerouslySetInnerHTML={{__html: markdownToHTML(objectsingle&&objectsingle.name).replace(/▁/g, "▁▁▁")}}> <div className=" lh28 listjihetixingstit markdown-body cretitlecolrlist" style={{wordBreak: "break-word"}} dangerouslySetInnerHTML={{__html: markdownToHTML(objectsingleid+objectsinglescore+objectsingle.name).replace(/▁/g, "▁▁▁")}}>
</div> </div>
</div> </div>
{/*内容*/} {/*内容*/}
<div className="w100s sortinxdirection"> <div className="w100s sortinxdirection">
<p className="w100s listjihetixingstits sortinxdirection ">
{ {
objectsingle.item_type==="JUDGMENT"? objectsingle.item_type==="JUDGMENT"?
objectsingle === undefined ||objectsingle === null? "" : objectsingle.choices.map((object, index) => { <p className="w100s listjihetixingstits sortinxdirection ">
return ( {
<p className={index===1? "sortinxdirection ml10":"sortinxdirection " } > objectsingle === undefined ||objectsingle === null? "" : objectsingle.choices.map((object, index) => {
<Radio checked={object.is_answer}> return (
{object.choice_text} <p className={index===1? "sortinxdirection ml10":"sortinxdirection " } >
</Radio> <Radio checked={object.is_answer}>
</p> {object.choice_text}
) </Radio>
}) </p>
)
})
}
</p>
: :
objectsingle === undefined ||objectsingle === null? "" : objectsingle.choices.map((object, index) => { objectsingle.item_type==="PROGRAM"?
return ( <p className="w100s listjihetixingstitssy sortinxdirection ">
<p className="sortinxdirection " > <p className={"sortinxdirection mt15"} >
{tagArray[index]} <p style={{wordBreak: "break-word"}} dangerouslySetInnerHTML={{__html: markdownToHTML(objectsingle.program_attr.description).replace(/▁/g, "▁▁▁")}}></p>
<p style={{wordBreak: "break-word"}} dangerouslySetInnerHTML={{__html: markdownToHTML(object.choice_text).replace(/▁/g, "▁▁▁")}}></p>
</p> </p>
) </p>
}) :
<p className="w100s listjihetixingstits verticallayout ">
{
objectsingle === undefined ||objectsingle === null? "" : objectsingle.choices.map((object, index) => {
return (
<p className={index===0?"sortinxdirection":"sortinxdirection mt15"} >
{tagArray[index]}
<p style={{wordBreak: "break-word"}} dangerouslySetInnerHTML={{__html: markdownToHTML(object.choice_text).replace(/▁/g, "▁▁▁")}}></p>
</p>
)
})
}
</p>
} }
</p>
</div> </div>
</div>
</div>
) )
} }

@ -128,6 +128,8 @@ class Listjihe extends Component {
</p> </p>
} }
</div> </div>
<div className="w100s sortinxdirection mt10"> <div className="w100s sortinxdirection mt10">
<p className="listjihetixing">难度<span >{items.difficulty===1?"简单":items.difficulty===2?"适中":items.difficulty===3?"困难":""}</span></p> <p className="listjihetixing">难度<span >{items.difficulty===1?"简单":items.difficulty===2?"适中":items.difficulty===3?"困难":""}</span></p>
<p className="ml30 listjihetixing">题型<span >{items.item_type==="SINGLE"?"单选题":items.item_type==="MULTIPLE"?"多选题":items.item_type==="JUDGMENT"?"判断题":items.item_type==="PROGRAM"?"编程题":""}</span></p> <p className="ml30 listjihetixing">题型<span >{items.item_type==="SINGLE"?"单选题":items.item_type==="MULTIPLE"?"多选题":items.item_type==="JUDGMENT"?"判断题":items.item_type==="PROGRAM"?"编程题":""}</span></p>

Loading…
Cancel
Save