问卷:q_position

dev_forum
caishi 6 years ago
parent 28b21e7cd6
commit 32c678ed3b

@ -200,7 +200,7 @@ class HomeworkModal extends Component{
{this.props.modaltype===undefined||this.props.modaltype===2||this.props.modaltype===4 {this.props.modaltype===undefined||this.props.modaltype===2||this.props.modaltype===4
|| !course_groups || course_groups.length == 0 || !course_groups || course_groups.length == 0
|| this.props.usingCheckBeforePost ?"":<ul className="upload_select_box fl clearfix mt20 mb30" || this.props.usingCheckBeforePost ?"":<ul className="upload_select_box fl clearfix mt20 mb30"
style={{"overflow-y":"auto"}} style={{"overflow-y":"auto",padding:"10px 0px"}}
id="search_not_members_list" id="search_not_members_list"
// onScroll={this.contentViewScroll} // onScroll={this.contentViewScroll}
@ -221,8 +221,8 @@ class HomeworkModal extends Component{
{ {
course_groups.map((item,key)=>{ course_groups.map((item,key)=>{
return( return(
<div className="clearfix edu-txt-center lineh-40 bor-bottom-greyE" key={key}> <div className="clearfix edu-txt-center lineh-40" key={key}>
<li style={{ width: '100%'}}> <li style={{ width: '100%',padding: "0px 10px"}}>
<Checkbox <Checkbox
className="task-hide edu-txt-left" className="task-hide edu-txt-left"
name="shixun_homework[]" name="shixun_homework[]"

@ -660,7 +660,7 @@ class ExerciseReviewAndAnswer extends Component{
return( return(
<div className="bor-top-greyE pt30 pb30" id={"Anchor_"+parseInt(key+1)}> <div className="bor-top-greyE pt30 pb30" id={"Anchor_"+parseInt(key+1)}>
<p className="clearfix font-16 pl30 pr30"> <p className="clearfix font-16 pl30 pr30">
<span className="color-blue mr5">{exercise_questions.q_position}{type[item.question_type]}</span><span className="color-grey-9 mr5">({item.question_score})</span> <span className="color-blue mr5">{item.q_position}{type[item.question_type]}</span><span className="color-grey-9 mr5">({item.question_score})</span>
<span className="fr"> <span className="fr">
{ {
// 填空(一直都有调分),和简答题调分:老师身份 已经评分的才能出现调分按钮 // 填空(一直都有调分),和简答题调分:老师身份 已经评分的才能出现调分按钮

@ -65,7 +65,7 @@ class fillEmpty extends Component{
if(array[i].value ==""){ count++; } if(array[i].value ==""){ count++; }
} }
let k = count==array.length ? 0 : 1; let k = count==array.length ? 0 : 1;
this.props.changeQuestionStatus && this.props.changeQuestionStatus(parseInt(this.props.questionType.question_number)-1,k); this.props.changeQuestionStatus && this.props.changeQuestionStatus(parseInt(this.props.questionType.q_position)-1,k);
} }
}).catch((error)=>{ }).catch((error)=>{
console.log(error); console.log(error);
@ -115,11 +115,11 @@ class fillEmpty extends Component{
<input value={item.value} className="input-100-35" style={{backgroundColor: "#F5F5F5",cursor:"default"}} placeholder={ isStudent && item.value ? `请输入填空${key+1}的答案` : "" } readOnly/> <input value={item.value} className="input-100-35" style={{backgroundColor: "#F5F5F5",cursor:"default"}} placeholder={ isStudent && item.value ? `请输入填空${key+1}的答案` : "" } readOnly/>
: :
<DMDEditor <DMDEditor
ref={`md${questionType.question_number}${key}`} ref={`md${questionType.q_position}${key}`}
toMDMode={this.toMDMode} toShowMode={this.toShowMode} toMDMode={this.toMDMode} toShowMode={this.toShowMode}
height={150} className={'optionMdEditor'} watch={false} noStorage={true} height={150} className={'optionMdEditor'} watch={false} noStorage={true}
mdID={item.q_id +"_"+ key} placeholder={`输入填空${key+1}的答案`} onChange={(value) => this.onOptionContentChange(value, key)} mdID={questionType.question_id +"_"+ key} placeholder={`输入填空${key+1}的答案`} onChange={(value) => this.onOptionContentChange(value, key)}
initValue={item.value} onCMBlur={()=>this.onBlurEmpty(key,questionType.question_number)} initValue={item.value} onCMBlur={()=>this.onBlurEmpty(key,questionType.q_position)}
></DMDEditor> ></DMDEditor>
} }
</div> </div>

@ -25,7 +25,7 @@ class Multiple extends Component{
}else{ }else{
k=0; k=0;
} }
this.props.changeQuestionStatus && this.props.changeQuestionStatus(parseInt(this.props.questionType.question_number)-1,k); this.props.changeQuestionStatus && this.props.changeQuestionStatus(parseInt(this.props.questionType.q_position)-1,k);
} }
}).catch((error)=>{ }).catch((error)=>{
console.log(error); console.log(error);
@ -39,6 +39,7 @@ class Multiple extends Component{
user_exercise_status user_exercise_status
}=this.props }=this.props
let isStudent =this.props.isStudent(); let isStudent =this.props.isStudent();
console.log(questionType);
return( return(
<div className="pl30 pr30"> <div className="pl30 pr30">
<Checkbox.Group disabled={ user_exercise_status == 1 ? true : false } onChange={this.saveId} defaultValue={questionType.user_answer}> <Checkbox.Group disabled={ user_exercise_status == 1 ? true : false } onChange={this.saveId} defaultValue={questionType.user_answer}>

@ -30,7 +30,7 @@ class simpleAnswer extends Component{
// simpleValue:undefined // simpleValue:undefined
// }) // })
let k= simpleAnswer == "" ? 0 :1; let k= simpleAnswer == "" ? 0 :1;
this.props.changeQuestionStatus && this.props.changeQuestionStatus(parseInt(this.props.questionType.question_number)-1,k); this.props.changeQuestionStatus && this.props.changeQuestionStatus(parseInt(this.props.questionType.q_position)-1,k);
} }
}).catch((error)=>{ }).catch((error)=>{
console.log(error); console.log(error);

@ -308,7 +308,7 @@ class Infos extends Component{
: :
<div className="inline"> <div className="inline">
<a href="javascript:void(0);" onClick={this.followPerson} className="user_default_btn user_watch_btn user_private_btn fl mr20">{followed ? "取消关注":"关注"}</a> <a href="javascript:void(0);" onClick={this.followPerson} className="user_default_btn user_watch_btn user_private_btn fl mr20">{followed ? "取消关注":"关注"}</a>
<a href={`/users/${login}/message_detail?user_id=${id}`} className="user_default_btn user_private_btn fl">私信</a> <a href={`${this.props.Headertop && this.props.Headertop.old_url}/users/${login}/message_detail?user_id=${id}`} className="user_default_btn user_private_btn fl">私信</a>
</div> </div>
} }
</div> </div>

@ -122,7 +122,7 @@ class InfosProject extends Component{
<div className="square-list clearfix"> <div className="square-list clearfix">
{ {
!isStudent && page == 1 && !category && is_current && !isStudent && page == 1 && !category && is_current &&
<Create href={"/projects/new"} name={"新建项目"} index="4"></Create> <Create href={`${this.props.Headertop && this.props.Headertop.old_url}/projects/new`} name={"新建项目"} index="4"></Create>
} }
{ {
(!data || data.projects.length==0) && (isStudent || category) && <NoneData></NoneData> (!data || data.projects.length==0) && (isStudent || category) && <NoneData></NoneData>
@ -130,7 +130,7 @@ class InfosProject extends Component{
{ {
data && data.projects && data.projects.map((item,key)=>{ data && data.projects && data.projects.map((item,key)=>{
return( return(
<div className="square-Item" onClick={()=>this.turnToCourses(`/projects/${item.id}`,item.can_visited)} style={{"cursor": "pointer"}}> <div className="square-Item" onClick={()=>this.turnToCourses(`${this.props.Headertop && this.props.Headertop.old_url}/projects/${item.id}`,item.can_visited)} style={{"cursor": "pointer"}}>
{ {
item.is_public==1 && item.is_public==1 &&
<React.Fragment> <React.Fragment>

Loading…
Cancel
Save