diff --git a/public/react/src/modules/question/component/Listjihe.js b/public/react/src/modules/question/component/Listjihe.js index bec5835f5..a9322a74d 100644 --- a/public/react/src/modules/question/component/Listjihe.js +++ b/public/react/src/modules/question/component/Listjihe.js @@ -17,7 +17,10 @@ const tagArrays = [ 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z' ] +<<<<<<< HEAD +======= +>>>>>>> d0ddf91... 题库 class Listjihe extends Component { constructor(props) { super(props); @@ -97,6 +100,7 @@ class Listjihe extends Component { MULTIPLEkey = MULTIPLEkey + tagArrays[i]; } +<<<<<<< HEAD } } } @@ -111,10 +115,44 @@ class Listjihe extends Component { rightkey = i; break; } +======= + // 编程答案 + var rightkey=null + + if(items){ + if(items.item_type){ + if(items.item_type==="PROGRAM"){ + + }else{ + if(items.item_type==="JUDGMENT") { + + + if(items.choices){ + if(items.choices.length>0){ + var arr= items.choices; + for(let data of arr) { + if(data.is_answer===true){ + rightkey=data.choice_text; + break; +>>>>>>> d0ddf91... 题库 } } } } + }else { + if (items.choices) { + if (items.choices.length > 0) { + var arr = items.choices; + for (var i = 0; i < arr.length; i++) { + if (arr[i].is_answer === true) { + rightkey = i; + break; + } + } + } + } + + } } } @@ -196,6 +234,7 @@ class Listjihe extends Component { {/*内容*/}
+<<<<<<< HEAD {items.item_type === "JUDGMENT" ?

{ @@ -211,6 +250,23 @@ class Listjihe extends Component { }

: items.item_type === "PROGRAM" ? +======= + {items.item_type==="JUDGMENT"? +

+ { + items === undefined ||items === null? "" : items.choices.map((object, index) => { + return ( +

+ + {object.choice_text} + +

+ ) + }) + } +

: + items.item_type==="PROGRAM"? +>>>>>>> d0ddf91... 题库

{ @@ -401,6 +457,7 @@ class Listjihe extends Component {

+<<<<<<< HEAD
{ @@ -423,6 +480,21 @@ class Listjihe extends Component { dangerouslySetInnerHTML={{ __html: markdownToHTML("答案:" + rightkey).replace(/▁/g, "▁▁▁") }} >

+======= +
+ + { + items.item_type==="SINGLE" || items.item_type==="MULTIPLE"? +

+

+ : +

+

+>>>>>>> d0ddf91... 题库 }
diff --git a/public/react/src/modules/tpm/NewHeader.js b/public/react/src/modules/tpm/NewHeader.js index 60df25c5d..d0e16331e 100644 --- a/public/react/src/modules/tpm/NewHeader.js +++ b/public/react/src/modules/tpm/NewHeader.js @@ -992,15 +992,9 @@ class NewHeader extends Component { -<<<<<<< HEAD - -
-
- {/**/} -
- - 实训 - - -
- {/**/} - {/*搜索框*/} - {showSearchOpentype === true ?
this.hideshowSearchOpen(e)} onMouseLeave={() => this.setevaluatinghides()}> - this.onKeywordSearchKeyDowns()} - onSearch={(value) => this.onKeywordSearchKeyDown(value)} - // onPressEnter={this.onKeywordSearchKeyDown} - style={{ width: 300, height: 32 }} - autoFocus={true} - /> -
: ""} - - {/**/} - {/*/!**!/*/} - {/**/} - - {/**/} - {/* TODO 需要服务端接口提供最近搜索 +
+
+ {/**/} +
+ + 实训 + + +
+ {/**/} + {/*搜索框*/} + {showSearchOpentype === true ?
this.hideshowSearchOpen(e)} onMouseLeave={() => this.setevaluatinghides()}> + this.onKeywordSearchKeyDowns()} + onSearch={(value) => this.onKeywordSearchKeyDown(value)} + // onPressEnter={this.onKeywordSearchKeyDown} + style={{ width: 300, height: 32 }} + autoFocus={true} + /> +
: ""} + + {/**/} + {/*/!**!/*/} + {/**/} + + {/**/} + {/* TODO 需要服务端接口提供最近搜索
最近搜索
*/} +
-
{/* <%= link_to '登录', signin_path, :className => "mr5" %> <%= link_to '注册', user_join_path, :className => "ml5" %> */} - { - user === undefined ? - - this.educoderlogin()} className="mr5 color-white">登录 - - 注册 - : user.login === "" ? - this.educoderlogin()} className="mr5 color-white">登录 - - 注册 - : -
- - - - - +
+ } + {/*href="https://www.educoder.net/login"*/} +
+ {/*{ loadHeader()}*/} + {showSearchOpentype === true ? "" : this.props.user && this.props.user.main_site === true ? this.showSearchOpen(e)}> + {/*"/images/educoder/icon/search.svg" */} - - : ""} + + : ""} + + {/*
*/} +
+ + + + +
+
+ + {coursestypes === true && this.props.user && this.props.user.main_site === false ? "" : } +
+
+ + {this.props.user && this.props.user.main_site === true ?
+ {user === undefined ? "" : user.login === "" ? "" : -
- -
- : ""} - } -
-
+ + + {/*{this.props.Headertop===undefined?"":this.props.Headertop.unread_message_count > 99 ? '99+'*/} + {/*: this.props.Headertop===undefined?"":this.props.Headertop.unread_message_count}*/} + + + } - {this.props.user && this.props.user.main_site === true ?
- {user === undefined ? "" : user.login === "" ? "" : - - - {/*{this.props.Headertop===undefined?"":this.props.Headertop.unread_message_count > 99 ? '99+'*/} - {/*: this.props.Headertop===undefined?"":this.props.Headertop.unread_message_count}*/} - - - } +
: ""} -
: ""} - - -
-
-
    -
    -

    - {submitapplicationsvalue} -

    + +
    +
    +
      +
      +

      + {submitapplicationsvalue} +

      +
      +
    • + 取消 + 确定 +
    • + +
    -
  • - 取消 - 确定 -
  • - -
-
-
-
+
+ - +