You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1 line
25 KiB

This file contains invisible Unicode characters!

This file contains invisible Unicode characters that may be processed differently from what appears below. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to reveal hidden characters.

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

webpackJsonp([153],{1265:function(e,t,n){"use strict";n.d(t,"e",function(){return r}),n.d(t,"a",function(){return a}),n.d(t,"c",function(){return o}),n.d(t,"b",function(){return i}),n.d(t,"d",function(){return s}),n.d(t,"f",function(){return c});var r=0,a=2,o=3,i=4,s=5,c=["单选题","多选题","判断题","填空题","简答题","实训题"]},1384:function(e,t,n){"use strict";var r=n(162),a=(n.n(r),n(161)),d=n.n(a),o=n(287),i=(n.n(o),n(283)),s=n.n(i),c=n(30),l=(n.n(c),n(31)),p=n.n(l),u=n(65),m=(n.n(u),n(66)),f=n.n(m),h=n(0),b=n.n(h),y=n(12),_=(n.n(y),n(1265)),g=n(5),x=function(e,t,n){return t&&E(e.prototype,t),n&&E(e,n),e};function E(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}f.a.TextArea,p.a.confirm,window.$,s.a.Option;var w=(function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(A,h.Component),x(A,[{key:"render",value:function(){var e=this,t=this.props,n=t.question_title,r=t.question_score,a=t.question_type,o=(t.question_choices,t.standard_answer,t.question_id),i=(t.question_number,t.index),s=t.displayCount,c=t.topRight,l=t.showActionButton,p=t.exerciseIsPublish,u=(this.props.isAdmin(),this.props.match.params.coursesId,this.isEdit,_.f[a]);return b.a.createElement(b.a.Fragment,null,b.a.createElement("div",{className:"new_li"},b.a.createElement("style",null,"\n .actionBtns {\n height: 28px\n }\n "),b.a.createElement("div",{className:"font-16 fl"},b.a.createElement("span",{className:"color-blue"},i+1,"、",u),b.a.createElement("span",{className:"color-grey-9"},"",r,"分)")),b.a.createElement("div",{className:"fr actionBtns"},c,0!=l&&b.a.createElement(b.a.Fragment,null,!p&&b.a.createElement("a",{className:"mr30",onClick:function(){return e.props.onQestionDelete(o)}},b.a.createElement(d.a,{title:"删除"},b.a.createElement("i",{className:"color-grey-cd font-16 iconfont icon-shanchu"}))),0===i?"":b.a.createElement("a",{className:"mr30",onClick:function(){return e.props.onSortUp(i,o)}},b.a.createElement(d.a,{title:"上移"},b.a.createElement("i",{className:"color-green font-18 iconfont icon-xiangshangyi"}))),i===s-1?"":b.a.createElement("a",{className:"mr30",onClick:function(){return e.props.onSortDown(i,o)}},b.a.createElement(d.a,{title:"下移"},b.a.createElement("i",{className:"color-green font-18 iconfont icon-xiangxiayi"}))),!p&&b.a.createElement("a",{className:"mr30",onClick:function(){return e.props.addQuestion(o,a)}},b.a.createElement(d.a,{title:"(向下插入"+u+")"},b.a.createElement("i",{className:"color-green font-18 iconfont icon-roundaddfill"}))),b.a.createElement("a",{onClick:function(){return e.props.editQestion(i)}},b.a.createElement(d.a,{title:"编辑"},b.a.createElement("i",{className:"color-green font-18 iconfont icon-bianjidaibeijing"})))))),n&&b.a.createElement(g.s,{content:n,selector:"qtitle_"+(i+1),style:{display:"inline-block",width:"100%",margin:"10px 0px 15px"}}))}}]),A);function A(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,A);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(A.__proto__||Object.getPrototypeOf(A)).call(this,e));return t.componentDidMount=function(){},t.state={},t}t.a=w},1618:function(e,t,n){var r=n(1706);"string"==typeof r&&(r=[[e.i,r,""]]);var a={hmr:!1,transform:void 0};n(281)(r,a);r.locals&&(e.exports=r.locals)},1706:function(e,t,n){(e.exports=n(280)(!0)).push([e.i,".editorWrapDiv{border:1px solid #4cacff;padding:6px 10px}.questionSection{border-bottom:1px solid #eaeaea;padding:8px 0}.questionSection:last-child{border-bottom:none}.judge-item.option-item{display:inline-block;margin-bottom:8px;width:52px}.addAnswerButton{background:#f8f8f8;text-align:center;color:#4cacff;height:40px;line-height:40px;cursor:pointer}.nullChildEditor{width:100%;display:inline-block}.singleDisplay .options .markdown-body{max-width:1116px}.singleDisplay .ant-checkbox-wrapper span:last-child,.singleDisplay .ant-radio-wrapper span:last-child{padding-right:0}","",{version:3,sources:["/Users/yangshuming/Desktop/new__educode/educoder/public/react/src/modules/courses/exercise/new/common.css"],names:[],mappings:"AAAA,eACI,yBAA0B,AAC1B,gBAAkB,CACrB,AACD,iBACI,gCAAiC,AACjC,aAAiB,CACpB,AACD,4BACI,kBAAoB,CACvB,AAGD,wBACI,qBAAsB,AACtB,kBAAmB,AACnB,UAAY,CACf,AAGD,iBACI,mBAAgC,AAChC,kBAAmB,AACnB,cAAe,AACf,YAAa,AACb,iBAAkB,AAClB,cAAgB,CACnB,AACD,iBACI,WAAY,AACZ,oBAAsB,CACzB,AAED,uCACI,gBAAkB,CACrB,AACD,uGAEI,eAAmB,CACtB",file:"common.css",sourcesContent:[".editorWrapDiv {\r\n border: 1px solid #4CACFF;\r\n padding: 6px 10px;\r\n}\r\n.questionSection {\r\n border-bottom: 1px solid #EAEAEA;\r\n padding: 8px 0px;\r\n}\r\n.questionSection:last-child {\r\n border-bottom: none;\r\n}\r\n\r\n/* 判断题编辑器item样式 */\r\n.judge-item.option-item {\r\n display: inline-block;\r\n margin-bottom: 8px;\r\n width: 52px;\r\n}\r\n\r\n/* 填空题新增按钮 */\r\n.addAnswerButton {\r\n background: rgba(248,248,248,1);\r\n text-align: center;\r\n color: #4CACFF;\r\n height: 40px;\r\n line-height: 40px;\r\n cursor: pointer;\r\n}\r\n.nullChildEditor {\r\n width: 100%;\r\n display: inline-block;\r\n}\r\n\r\n.singleDisplay .options .markdown-body {\r\n max-width: 1116px;\r\n}\r\n.singleDisplay .ant-radio-wrapper span:last-child\r\n , .singleDisplay .ant-checkbox-wrapper span:last-child {\r\n padding-right: 0px;\r\n}"],sourceRoot:""}])},1840:function(e,t,n){"use strict";var r=n(284),a=(n.n(r),n(282)),i=n.n(a),o=n(166),s=(n.n(o),n(165)),c=n.n(s),l=n(287),p=(n.n(l),n(283)),u=n.n(p),d=n(30),m=(n.n(d),n(31)),f=n.n(m),h=n(65),b=(n.n(h),n(66)),y=n.n(b),_=n(0),g=n.n(_),x=n(12),E=(n.n(x),n(1384)),w=n(5),A=function(e,t,n){return t&&v(e.prototype,t),n&&v(e,n),e};function v(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}y.a.TextArea,f.a.confirm,window.$,u.a.Option;var C=["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"],O=(function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(q,_.Component),A(q,[{key:"render",value:function(){var e=this.props,r=(e.question_title,e.question_score,e.question_type),t=e.question_choices,n=(e.standard_answer,e.question_id),a=(e.question_number,e.index),o=(e.displayCount,e.showActionButton,this.props.isAdmin(),this.props.match.params.coursesId,this.isEdit,"question_"+a);return g.a.createElement("div",{className:"bor-bottom-greyE padding20-30 singleDisplay",id:o,_id:n},g.a.createElement("style",null,"\n .optionMdEditor {\n flex: 0 0 800px\n }\n .optionRow {\n margin: 2px;\n }\n .actionBtns {\n height: 28px\n }\n "),g.a.createElement(E.a,this.props),g.a.createElement("div",{className:"options"},t.map(function(e,t){var n;return n=C[t]+".",0==r?g.a.createElement("div",{className:"mb10 clearfix",key:t},g.a.createElement(c.a,{disabled:!0,className:"fl lineh-25",checked:e.standard_boolean},n),g.a.createElement(w.s,{content:e.choice_text,selector:"single_"+(a+1)+(t+1),style:{float:"left",display:"inline-block"}})):g.a.createElement("div",{className:"mb10 clearfix",key:t},g.a.createElement(i.a,{disabled:!0,className:"fl lineh-25 mr8",checked:e.standard_boolean},n),g.a.createElement(w.s,{content:e.choice_text,selector:"single_"+(a+1)+(t+1),style:{float:"left",display:"inline-block"}}))})))}}]),q);function q(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,q);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(q.__proto__||Object.getPrototypeOf(q)).call(this,e));return t.componentDidMount=function(){var e=t.props.match.params.Id;if(t.isEdit=!!e,e);},t.state={question_choices:["","","",""],standard_answers:[!1,!1,!1,!1]},t}t.a=O},1841:function(e,t,n){"use strict";var r=n(166),a=(n.n(r),n(165)),i=n.n(a),o=n(287),s=(n.n(o),n(283)),c=n.n(s),l=n(30),p=(n.n(l),n(31)),u=n.n(p),d=n(65),m=(n.n(d),n(66)),f=n.n(m),h=n(0),b=n.n(h),y=n(12),_=(n.n(y),n(1265)),g=n(5),x=n(1384),E=function(e,t,n){return t&&w(e.prototype,t),n&&w(e,n),e};function w(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}f.a.TextArea,u.a.confirm,window.$,c.a.Option;var A=(function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(v,h.Component),E(v,[{key:"render",value:function(){var e=this.props,t=(e.question_title,e.question_score,e.question_type),n=e.question_choices,r=(e.standard_answer,e.question_id),a=(e.question_number,e.index),o=(e.displayCount,this.props.isAdmin(),this.props.match.params.coursesId,this.isEdit,"question_"+a);return _.f[t],b.a.createElement("div",{className:"bor-bottom-greyE padding20-30",id:o,_id:r},b.a.createElement("style",null,"\n .optionMdEditor {\n flex: 0 0 800px\n }\n .optionRow {\n margin: 2px;\n }\n .actionBtns {\n height: 28px\n }\n \n "),b.a.createElement(x.a,this.props),b.a.createElement("div",{className:"options clearfix"},n.map(function(e,t){return b.a.createElement("div",{key:t,className:"fl mr30 df"},b.a.createElement(i.a,{disabled:!0,className:"lineh-25",checked:e.standard_boolean}),b.a.createElement(g.s,{content:e.choice_text,selector:"judge_"+(a+1)+t,className:""}))})))}}]),v);function v(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,v);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(v.__proto__||Object.getPrototypeOf(v)).call(this,e));return t.componentDidMount=function(){var e=t.props.match.params.Id;if(t.isEdit=!!e,e);},t.state={question_choices:["","","",""],standard_answers:[!1,!1,!1,!1]},t}t.a=A},1842:function(e,t,n){"use strict";var r=n(287),a=(n.n(r),n(283)),o=n.n(a),i=n(30),s=(n.n(i),n(31)),c=n.n(s),l=n(65),p=(n.n(l),n(66)),u=n.n(p),d=n(0),m=n.n(d),f=n(12),h=(n.n(f),n(1265)),b=n(5),y=n(1384),_=function(e,t,n){return t&&g(e.prototype,t),n&&g(e,n),e};function g(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}u.a.TextArea,c.a.confirm,window.$,o.a.Option;var x=(function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(E,d.Component),_(E,[{key:"render",value:function(){var e=this.props,t=(e.question_title,e.question_score,e.question_type),n=(e.question_choices,e.standard_answer),r=e.question_id,a=(e.question_number,e.index),o=(e.displayCount,e.multi_count,this.props.isAdmin(),this.props.match.params.coursesId,this.isEdit,"question_"+a);return h.f[t],m.a.createElement("div",{className:"bor-bottom-greyE padding20-30",id:o,_id:r},m.a.createElement("style",null,"\n .answers {\n flex: 1;\n display: inline-block;\n }\n .answers .answer {\n background: #EDEDED;\n color: #C5C5C5;\n \n display: inline-block;\n line-height: 16px;\n padding:12px 10px;\n margin-bottom:10px;\n border-radius:2px;\n width: 1024px;\n word-break: break-all;\n }\n .answerRow { \n padding: 1px 0;\n }\n .answers .markdown-body > p{\n line-height:20px;\n }\n "),m.a.createElement(y.a,this.props),m.a.createElement("div",{className:"options"},n.map(function(e,n){return m.a.createElement("div",{className:"df answerRow",key:n},m.a.createElement("span",{className:"lineh-40"},"答案(填空",n+1,""),m.a.createElement("div",{className:"answers"},e.answer_text.map(function(e,t){return m.a.createElement(b.s,{className:"answer",key:t,content:e,selector:"null_"+(a+1)+(n+1)+(t+1)})})))})))}}]),E);function E(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,E);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(E.__proto__||Object.getPrototypeOf(E)).call(this,e));return t.componentDidMount=function(){var e=t.props.match.params.Id;if(t.isEdit=!!e,e);},t.state={question_choices:["","","",""],standard_answers:[!1,!1,!1,!1]},t}t.a=x},1843:function(e,t,n){"use strict";var r=n(287),a=(n.n(r),n(283)),o=n.n(a),i=n(30),s=(n.n(i),n(31)),c=n.n(s),l=n(65),p=(n.n(l),n(66)),u=n.n(p),d=n(0),m=n.n(d),f=n(12),h=(n.n(f),n(1265)),b=n(5),y=n(1384),_=function(e,t,n){return t&&g(e.prototype,t),n&&g(e,n),e};function g(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}u.a.TextArea,c.a.confirm,window.$,o.a.Option;var x=(function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(E,d.Component),_(E,[{key:"render",value:function(){var e=this.props,t=(e.question_title,e.question_score,e.question_type),n=e.standard_answer,r=e.question_id,a=(e.question_number,e.index),o=(e.displayCount,this.props.isAdmin(),this.props.match.params.coursesId,this.isEdit,"question_"+a);return h.f[t],m.a.createElement("div",{className:"bor-bottom-greyE padding20-30",id:o,_id:r},m.a.createElement("style",null,"\n .optionMdEditor {\n flex: 0 0 800px\n }\n .optionRow {\n margin: 2px;\n }\n .actionBtns {\n height: 28px\n }\n \n "),m.a.createElement(y.a,this.props),n[0]&&m.a.createElement(m.a.Fragment,null,m.a.createElement("div",{style:{color:"#05101A"},className:"font-16 mb5 font-bd"},"参考答案:"),m.a.createElement(b.s,{content:n[0],selector:"answer_"+o,className:""})))}}]),E);function E(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,E);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(E.__proto__||Object.getPrototypeOf(E)).call(this,e));return t.componentDidMount=function(){},t.state={},t}t.a=x},1844:function(e,t,n){"use strict";var r=n(287),a=(n.n(r),n(283)),o=n.n(a),i=n(30),s=(n.n(i),n(31)),c=n.n(s),l=n(65),p=(n.n(l),n(66)),u=n.n(p),d=n(0),m=n.n(d),f=(n(45),n(12)),h=(n.n(f),n(1265)),b=n(5),y=n(1384),_=function(e,t,n){return t&&g(e.prototype,t),n&&g(e,n),e};function g(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}u.a.TextArea,c.a.confirm,window.$,o.a.Option;var x=(function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(E,d.Component),_(E,[{key:"render",value:function(){var e=this.props,t=e.question_title,n=(e.question_score,e.question_type),r=(e.standard_answer,e.question_id),a=(e.question_number,e.index),o=(e.displayCount,e.shixun_name),i=e.shixun,s=(e.shixun_id,e.shixun_identifier),c=(this.props.isAdmin(),this.props.match.params.coursesId,this.isEdit,"question_"+a);return h.f[n],m.a.createElement("div",{className:"bor-bottom-greyE padding20-30",id:c,_id:r},m.a.createElement("style",null,"\n\n .mainQuestionDisplay {\n margin-bottom:15px;\n }\n \n "),m.a.createElement(y.a,Object.assign({},this.props,{question_title:o,topRight:m.a.createElement("a",{target:"_blank",href:"/shixuns/"+s+"/challenges",className:"mr30",style:{color:"#4CACFF"}},"实训详情")})),m.a.createElement("div",{className:"mainQuestionDisplay color-grey-9 markdown-body",dangerouslySetInnerHTML:{__html:Object(b.W)(t)}}),i.map(function(e,t){return m.a.createElement("div",null,"第"+(t+1)+"关"," ",e.challenge_name," ",e.challenge_score,"分")}))}}]),E);function E(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,E);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(E.__proto__||Object.getPrototypeOf(E)).call(this,e));return t.componentDidMount=function(){},t.state={},t}t.a=x},2895:function(e,t,n){"use strict";var r=n(287),a=(n.n(r),n(283)),o=n.n(a),i=n(30),s=(n.n(i),n(31)),c=n.n(s),l=n(65),p=(n.n(l),n(66)),u=n.n(p),d=n(0),m=n.n(d),f=n(12),h=n.n(f),b=(n(5),n(1840)),y=n(1841),_=n(1842),g=n(1843),x=n(1844),E=n(1618),w=(n.n(E),function(e,t,n){return t&&A(e.prototype,t),n&&A(e,n),e});function A(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}u.a.TextArea,c.a.confirm,window.$,o.a.Option;var v=(function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(C,d.Component),w(C,[{key:"_getRequestParams",value:function(){var e=this.state,t=e.order,n=e.exercise_group_id,r=e.searchtext;return{page:e.page,search:r,order:t,limit:e.limit,group_id:n}}},{key:"_getRequestParams",value:function(){var e=this.state,t=e.order,n=e.exercise_group_id,r=e.searchtext;return{page:e.page,search:r,order:t,limit:e.limit,group_id:n}}},{key:"render",value:function(){var n=this,e=this.state,r=e.exercise_questions,t=e.exercise,a=e.exercise_types,o={};return m.a.createElement("div",{className:"edu-back-white"},m.a.createElement("div",{className:" padding20-30"},m.a.createElement("style",null,"\n .center{\n text-align: center;\n }\n .edu-back-white>.bor-bottom-greyE:last-child {\n border-bottom: none !important;\n }\n "),m.a.createElement("div",{className:"font-18 center"},t&&t.exercise_name),m.a.createElement("div",{className:"font-14 color-grey-9"},t&&t.exercise_description)),m.a.createElement("div",{className:" padding20-30 newContainer"},m.a.createElement("p",{className:" clearfix"},a&&0<a.q_singles&&m.a.createElement("span",{className:"color-grey-9 mr15"},"单选题 ",a.q_singles," 题,共 ",a&&a.q_singles_scores," 分"),a&&0<a.q_doubles&&m.a.createElement("span",{className:"color-grey-9 mr15"},"多选题 ",a.q_doubles," 题,共 ",a&&a.q_doubles_scores," 分"),a&&0<a.q_judges&&m.a.createElement("span",{className:"color-grey-9 mr15"},"判断题 ",a.q_judges," 题,共 ",a&&a.q_judges_scores," 分"),a&&0<a.q_nulls&&m.a.createElement("span",{className:"color-grey-9 mr15"},"填空题 ",a.q_nulls," 题,共 ",a&&a.q_nulls_scores," 分"),a&&0<a.q_mains&&m.a.createElement("span",{className:"color-grey-9 mr15"},"简答题 ",a.q_mains," 题,共 ",a&&a.q_mains_scores," 分"),a&&0<a.q_shixuns&&m.a.createElement("span",{className:"color-grey-9 mr15"},"实训题 ",a.q_shixuns," 题,共 ",a&&a.q_shixuns_scores," 分"),m.a.createElement("span",{className:"color-grey-3 fr"},"共",m.a.createElement("span",{className:"color-orange-tip"}," ",a&&a.q_scores," "),"分"),m.a.createElement("span",{className:"color-grey-3 fr"},"合计",m.a.createElement("span",{className:"color-blue"}," ",a&&a.q_counts," "),"题:"))),r.map(function(e,t){return 0==e.question_type||1==e.question_type?m.a.createElement(b.a,Object.assign({},n.props,e,{index:t},o,{displayCount:r.length,showActionButton:!1,key:t})):2==e.question_type?m.a.createElement(y.a,Object.assign({showActionButton:!1,key:t},n.props,e,{index:t},o)):3==e.question_type?m.a.createElement(_.a,Object.assign({showActionButton:!1,key:t},n.props,e,{index:t},o)):4==e.question_type?m.a.createElement(g.a,Object.assign({showActionButton:!1,key:t},n.props,e,{index:t},o)):5==e.question_type?m.a.createElement(x.a,Object.assign({Testpapersettinghomepage:!0,showActionButton:!1,key:t},n.props,e,{index:t},o)):m.a.createElement("div",null)}))}}]),C);function C(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,C);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(C.__proto__||Object.getPrototypeOf(C)).call(this,e));return n.componentDidMount=function(){var e=n.props.match.params.Id;if(e){var t="/"+(n.props.urlPath||"exercises")+"/"+e+".json";h.a.get(t).then(function(e){e.data.exercise&&(e.data.exercise.exercise_description=e.data.exercise.exercise_description||e.data.exercise.description,e.data.exercise.exercise_name=e.data.exercise.exercise_name||e.data.exercise.name,e.data.exercise.exercise_status=null==e.data.exercise.exercise_status?1:e.data.exercise.exercise_status,n.setState(Object.assign({},e.data))),n.props.detailFetchCallback&&n.props.detailFetchCallback(e)}).catch(function(e){console.log(e)})}try{n.props.triggerRef(n)}catch(e){}},n.state={exercise_questions:[],exercise_group_id:[],page:1,limit:10,searchtext:"",order:"end_at"},n}t.a=v},3931:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n.n(r),o=n(12),i=(n.n(o),n(2895)),s=function(e,t,n){return t&&c(e.prototype,t),n&&c(e,n),e};function c(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var l=(function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(p,r.Component),s(p,[{key:"render",value:function(){return this.state.pollDetail,a.a.createElement("div",null,a.a.createElement(i.a,Object.assign({},this.props,this.state,{urlPath:"exercise_banks",detailFetchCallback:this.detailFetchCallback})))}}]),p);function p(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,p);var a=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(p.__proto__||Object.getPrototypeOf(p)).call(this,e));return a.componentDidMount=function(){},a.detailFetchCallback=function(e){var t=a.props.match.params.Id,n={title:e.data.exercise&&e.data.exercise.name,is_public:e.data.exercise&&e.data.exercise.is_public,crumbArray:[{content:"详情"}]},r={tab:"0",menuArray:[{to:"/banks/exercise/"+t+"/"+a.props.match.params.type+"?tab=0",content:"内容详情"}],category:"exercise",tos:"/banks/exercise/"+t+"/edit/"+a.props.match.params.type,id:t,is_public:e.data.exercise&&e.data.exercise.is_public,type:a.props.match.params.type,authorize:e&&e.data&&e.data.authorize};a.props.initPublic(n,r,e.data)},a.state={},a}t.default=l}});