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
19 KiB

webpackJsonp([20],{1509:function(e,t,n){"use strict";t.a=function(){var n=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};return function(e){return 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)}(t,r.Component),c(t,[{key:"componentDidMount",value:function(){var e=this;this.props.wrappedComponentRef&&this.props.wrappedComponentRef(this.refs.wrappedComponentRef),setTimeout(function(){u(n.parentSelector||".commentsDelegateParent").delegate(n.imgSelector||".J_Comment_Reply .comment_content img, .J_Comment_Reply .childrenCommentsView img","click",e.onDelegateClick)},1200)}},{key:"componentWillUnmount",value:function(){u(n.parentSelector||".commentsDelegateParent","click",this.onDelegateClick)}},{key:"render",value:function(){return this.MdifHasAnchorJustScorll(),a.a.createElement(a.a.Fragment,null,a.a.createElement(o.a,Object.assign({},this.state,{onImageLayerClose:this.onImageLayerClose})),a.a.createElement(e,Object.assign({},this.props,{ref:"wrappedComponentRef"})))}}]),t;function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var r=function(e,t){if(e)return!t||"object"!=typeof t&&"function"!=typeof t?e:t;throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.onDelegateClick=function(e){var t=e.target.src||e.target.getAttribute("src")||e.target.getAttribute("href"),n=e.target.innerHTML.trim();if(Object(s.V)(t.trim())||Object(s.V)(n)||"IMG"==e.target.tagName)return-1===t.indexOf("/images/avatars/User")&&-1===t.indexOf("kindeditor/plugins/emoticons")&&r.setState({showImage:!0,imageSrc:t}),e.stopPropagation(),e.preventDefault&&e.preventDefault(),e.originalEvent.preventDefault(),!1},r.onImageLayerClose=function(){r.setState({showImage:!1,imageSrc:""})},r.MdifHasAnchorJustScorll=function(){var e=decodeURI(r.props.location.hash).replace("#","");if(e){var t=document.getElementsByName(e);t&&0!=t.length&&t[t.length-1].scrollIntoView()}},r.state={showImage:!1,imageSrc:""},r}}};var r=n(0),a=n.n(r),o=n(334),s=n(5),c=function(e,t,n){return t&&i(e.prototype,t),n&&i(e,n),e};function i(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 u=window.$},744:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n.n(r),o=n(5),s=n(45),c=n(56),i=n(308),u=n.n(i),d=n(307),l=n(12),p=n.n(l),m=n(309),h=n(315),f=n(1509),g=n(293),b=(n.n(g),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)}}var _=u()({loader:function(){return n.e(31).then(n.bind(null,2256))},loading:d.a}),w=u()({loader:function(){return n.e(114).then(n.bind(null,3786))},loading:d.a}),O=(u()({loader:function(){return n.e(48).then(n.bind(null,3795))},loading:d.a}),u()({loader:function(){return n.e(241).then(n.bind(null,3796))},loading:d.a})),I=(u()({loader:function(){return n.e(102).then(n.bind(null,2221))},loading:d.a}),u()({loader:function(){return n.e(120).then(n.bind(null,3802))},loading:d.a})),j=u()({loader:function(){return n.e(73).then(n.bind(null,3808))},loading:d.a}),y=u()({loader:function(){return n.e(71).then(n.bind(null,3809))},loading:d.a}),k=(u()({loader:function(){return n.e(52).then(n.bind(null,2879))},loading:d.a}),u()({loader:function(){return n.e(63).then(n.bind(null,2872))},loading:d.a}),u()({loader:function(){return n.e(83).then(n.bind(null,1756))},loading:d.a})),v=u()({loader:function(){return n.e(82).then(n.bind(null,3810))},loading:d.a}),x=u()({loader:function(){return n.e(50).then(n.bind(null,3811))},loading:d.a}),S=(u()({loader:function(){return n.e(104).then(n.bind(null,2216))},loading:d.a}),u()({loader:function(){return n.e(116).then(n.bind(null,2886))},loading:d.a}),u()({loader:function(){return n.e(57).then(n.bind(null,2882))},loading:d.a}),u()({loader:function(){return n.e(109).then(n.bind(null,3812))},loading:d.a})),C=(u()({loader:function(){return n.e(58).then(n.bind(null,2226))},loading:d.a}),u()({loader:function(){return n.e(45).then(n.bind(null,3816))},loading:d.a})),N=(u()({loader:function(){return n.e(60).then(n.bind(null,2888))},loading:d.a}),u()({loader:function(){return n.e(46).then(n.bind(null,3827))},loading:d.a})),P=(u()({loader:function(){return n.e(113).then(n.bind(null,2215))},loading:d.a}),u()({loader:function(){return n.e(81).then(n.bind(null,3829))},loading:d.a})),D=u()({loader:function(){return n.e(162).then(n.bind(null,3830))},loading:d.a}),A=u()({loader:function(){return n.e(54).then(n.bind(null,3831))},loading:d.a}),R=(u()({loader:function(){return n.e(80).then(n.bind(null,1757))},loading:d.a}),u()({loader:function(){return n.e(51).then(n.bind(null,3840))},loading:d.a})),M=u()({loader:function(){return n.e(85).then(n.bind(null,3846))},loading:d.a}),T=u()({loader:function(){return n.e(88).then(n.bind(null,3847))},loading:d.a}),J=u()({loader:function(){return n.e(92).then(n.bind(null,2891))},loading:d.a}),L=(u()({loader:function(){return n.e(56).then(n.bind(null,2201))},loading:d.a}),u()({loader:function(){return n.e(53).then(n.bind(null,2871))},loading:d.a}),u()({loader:function(){return n.e(174).then(n.bind(null,3854))},loading:d.a})),q=u()({loader:function(){return n.e(173).then(n.bind(null,3855))},loading:d.a}),V=u()({loader:function(){return n.e(76).then(n.bind(null,3856))},loading:d.a}),H=u()({loader:function(){return n.e(75).then(n.bind(null,3857))},loading:d.a}),U=(u()({loader:function(){return n.e(101).then(n.bind(null,2911))},loading:d.a}),u()({loader:function(){return n.e(55).then(n.bind(null,3858))},loading:d.a})),B=(u()({loader:function(){return n.e(87).then(n.bind(null,2913))},loading:d.a}),u()({loader:function(){return n.e(93).then(n.bind(null,3862))},loading:d.a})),F=u()({loader:function(){return n.e(77).then(n.bind(null,3866))},loading:d.a}),G=u()({loader:function(){return n.e(78).then(n.bind(null,3867))},loading:d.a}),W=u()({loader:function(){return n.e(123).then(n.bind(null,3868))},loading:d.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)}(z,r.Component),b(z,[{key:"componentDidMount",value:function(){var t=this;this.historyArray=[window.location.pathname],this.props.history.listen(function(e){t.historyArray.unshift(window.location.pathname),t.historyArray.length=2})}},{key:"render",value:function(){var t=this,n={previousPathName:this.historyArray&&this.historyArray[1]};return a.a.createElement(s.e,this.props,a.a.createElement(s.d,{path:"/courses/:coursesId/ordering/:ordering_type/:main_id",render:function(e){return a.a.createElement(W,Object.assign({},t.props,e,t.state))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/file/:Id",exact:!0,render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/files/:main_id",render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{exact:!0,path:"/courses/:coursesId/boards/:boardId",render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/boards/:boardId",render:function(e){return a.a.createElement(O,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/graduation_topics/postwork/new",render:function(e){return a.a.createElement(j,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/graduation_topics/new",render:function(e){return a.a.createElement(y,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/graduation_topics/:topicId/edit",render:function(e){return a.a.createElement(y,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:course_id/graduation_topics/:graduation_topic_id/detail",render:function(e){return a.a.createElement(I,Object.assign({},t.props,e,t.state))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/graduation_topics/:Id",exact:!0,render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/graduation_tasks/:category_id/appraise",render:function(e){return a.a.createElement(B,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/graduation_tasks/:category_id/works/:task_Id/new",render:function(e){return a.a.createElement(F,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/graduation_tasks/:category_id/works/:work_Id/edit",render:function(e){return a.a.createElement(G,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/graduation_tasks/:category_id/detail/:task_Id",render:function(e){return a.a.createElement(U,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/graduation_tasks/:category_id/edit",render:function(e){return a.a.createElement(V,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/graduation_tasks/:category_id/new",render:function(e){return a.a.createElement(H,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/graduation_tasks/:Id",exact:!0,render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/teachers",render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/students",render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/course_groups/:course_group_id",render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/course_groups",render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/common_homeworks/:category_id",exact:!0,render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/group_homeworks/:category_id",exact:!0,render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/common_homeworks/",strict:!0,render:function(e){return a.a.createElement(L,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/group_homeworks/",strict:!0,render:function(e){return a.a.createElement(q,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/polls/:pollId/users/:login",render:function(e){return a.a.createElement(D,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/polls/:pollId/detail",render:function(e){return a.a.createElement(A,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/polls/:pollid/:news",render:function(e){return a.a.createElement(P,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/polls/:Id",render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{exact:!0,path:"/courses/:coursesId/exercises/:Id/users/:userId",render:function(e){return a.a.createElement(T,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{exact:!0,path:"/courses/:coursesId/exercises/new",render:function(e){return a.a.createElement(M,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{exact:!0,path:"/courses/:coursesId/exercises/:Id/edit",render:function(e){return a.a.createElement(M,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/exercises/:Id/student_exercise_list",render:function(e){return a.a.createElement(R,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/exercises/:Id/Studentshavecompletedthelist",render:function(e){return a.a.createElement(J,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/exercises/:Id",render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homeworks/:homeworkid/review_detail/:userid",render:function(e){return a.a.createElement(N,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homework/:homeworkid/review_detail/:userid",render:function(e){return a.a.createElement(N,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homeworks/:homeworkid/student_work",render:function(e){return a.a.createElement(x,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homework/:homeworkid/student_work",render:function(e){return a.a.createElement(x,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homeworks/:homeworkid/shixun_work_report",render:function(e){return a.a.createElement(C,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homework/:homeworkid/shixun_work_report",render:function(e){return a.a.createElement(C,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homeworks/:homeworkid/list",render:function(e){return a.a.createElement(x,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homework/:homeworkid/list",render:function(e){return a.a.createElement(x,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homeworks/:homeworkid/Page",render:function(e){return a.a.createElement(x,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homeworks/:homeworkid/settings",render:function(e){return a.a.createElement(x,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homework/:homeworkid/settings",render:function(e){return a.a.createElement(x,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homeworks/:id/commitsummary/:homeworkid",render:function(e){return a.a.createElement(S,Object.assign({},t.props,e,t.state))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homework/:id/commitsummary/:homeworkid",render:function(e){return a.a.createElement(S,Object.assign({},t.props,e,t.state))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homeworks/:homeworkid/questions",render:function(e){return a.a.createElement(x,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homework/:homeworkid/questions",render:function(e){return a.a.createElement(x,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/new",render:function(e){return a.a.createElement(k,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/news/:subjectid/newgold/:id",render:function(e){return a.a.createElement(v,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/newgolds/settings",render:function(e){return a.a.createElement(v,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/settings",render:function(e){return a.a.createElement(k,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homework/:category_id",render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/shixun_homeworks/:main_id",render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses/:coursesId/statistics",render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state))}}),a.a.createElement(s.d,{path:"/courses/:coursesId",render:function(e){return a.a.createElement(_,Object.assign({},t.props,e,t.state,n))}}),a.a.createElement(s.d,{path:"/courses",render:function(e){return a.a.createElement(w,Object.assign({},t.props,e,t.state,n))}}))}}]),z);function z(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,z);var i=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,(z.__proto__||Object.getPrototypeOf(z)).call(this,e));return i.coursesidsfun=function(e,t){i.setState({coursesids:e,coursesidtype:t})},i.updataleftNav=function(){var e=i.props.location.pathname,t=!1===i.state.isaloadtype,n=e.split("/"),r=parseInt(n[2]);if(!isNaN(r)){var a=i.props.location.search,o={};try{var s=i.foo(a);"{}"===JSON.stringify(s)?i.setState({dataquerys:{}}):(i.setState({dataquerys:s}),o=s)}catch(e){i.setState({dataquerys:{}})}var c="/courses/"+r+"/left_banner.json";p.a.get(c,{params:o}).then(function(e){null!=e&&e.data&&e.data&&(i.setState({course_modules:e.data.course_modules,hidden_modules:e.data.hidden_modules,is_teacher:e.data.is_teacher,isaloadtype:t}),i.locationNav(e.data.course_modules))})}},i.foo=function(e){var t,n={},r=/[\?\&](\w+)(=?)(\w*)/g;do{if(t=r.exec(e)){var a=t[1],o=t[3];t[2]||(o=void 0),n[a]=o}}while(t);return n},i.locationNav=function(e){if(e){var a=i.props.location.pathname,t=a.split("/"),o=parseInt(t[4]);e.forEach(function(n,r){a===n.category_url?(i.setState({indexs:r,mainurl:n.category_url}),i.coursesidsfun(n.id,"node")):null!=n.second_category&&0!=n.second_category.length&&n.second_category.forEach(function(e,t){a===e.second_category_url&&(parseInt(o)!==e.category_id&&parseInt(o)!==n.id||i.setState({indexs:r,url:a,mainurl:n.category_url}),i.coursesidsfun(n.id,"child"))})})}},i.unlocationNavfun=function(e){i.setState({indexs:e})},i.state={coursesids:void 0,coursesidsfun:i.coursesidsfun,updataleftNavfun:i.updataleftNav,course_modules:void 0,hidden_modules:[],is_teacher:!1,isaloadtype:!0,coursesidtype:void 0,locationNavfun:i.locationNav,unlocationNavfun:i.unlocationNavfun},i}t.default=Object(c.b)(Object(f.a)({imgSelector:".imageLayerParent img, .imageLayerParent .imageTarget",parentSelector:".newMain"})(Object(h.a)()(Object(o.w)()(Object(m.a)($)))))}});