Commit 6c1d62be by dazhou

resolve conflict

parent 2cbf5e70
(this["webpackJsonpmr-julyedu"]=this["webpackJsonpmr-julyedu"]||[]).push([[2],{1025:function(e,t,a){},1026:function(e,t,a){},1028:function(e,t,a){},1029:function(e,t,a){},1030:function(e,t,a){},515:function(e,t,a){"use strict";var n=a(3),s=a(5),r=a(6),c=a(7),o=a(0),i=a.n(o),l=(a(579),function(e){Object(r.a)(a,e);var t=Object(c.a)(a);function a(e){var s;return Object(n.a)(this,a),(s=t.call(this,e)).startCountDown=function(e){if(e){var t=1e3*e,a=0,n=0,r=0;setInterval((function(){t-=1e3,a="".concat(parseInt(t/36e5)).padStart(2,0),n="".concat(parseInt((t-36e5*a)/6e4)).padStart(2,0),r="".concat(parseInt((t-36e5*a-6e4*n)/1e3)).padStart(2,0),s.setState({countdown:"".concat(a,"\u65f6").concat(n,"\u5206").concat(r,"\u79d2\u540e\u7ed3\u675f")})}),1e3)}},s.state={countdown:""},s}return Object(s.a)(a,[{key:"componentDidMount",value:function(){var e=this.props.time;this.startCountDown(e)}},{key:"componentWillReceiveProps",value:function(e){var t=e.time;this.props.time!=t&&this.startCountDown(t)}},{key:"render",value:function(){var e=this.props,t=e.image,a=e.toCourse,n=e.id,s=this.state.countdown;return i.a.createElement("div",{className:"course-container"},i.a.createElement("div",{className:"course__cover"},s&&i.a.createElement("p",{className:"course__time"},s),i.a.createElement("img",{src:t,alt:"cover",onClick:function(){return a(n)}})),this.props.children)}}]),a}(o.Component));t.a=l},516:function(e,t,a){"use strict";a.d(t,"a",(function(){return l}));var n=a(3),s=a(5),r=a(6),c=a(7),o=a(0),i=a.n(o),l=(a(1029),function(e){Object(r.a)(a,e);var t=Object(c.a)(a);function a(){return Object(n.a)(this,a),t.apply(this,arguments)}return Object(s.a)(a,[{key:"render",value:function(){var e=this.props.id;return i.a.createElement("div",{className:"common_container",id:e},i.a.createElement("div",{className:"container_top"}),i.a.createElement("div",{className:"container_content"},this.props.title&&i.a.createElement("div",{className:"title_container"},i.a.createElement("i",null),i.a.createElement("p",null,this.props.title),i.a.createElement("i",null)),i.a.Children.map(this.props.children,(function(e){return i.a.createElement(i.a.Fragment,null,e)}))),i.a.createElement("div",{className:"container_bottom"}))}}]),a}(o.Component))},579:function(e,t,a){},581:function(e,t,a){"use strict";a(36);var n=a(10),s=a.n(n),r=a(3),c=a(5),o=a(6),i=a(7),l=a(0),u=a.n(l),m=a(1),p=(a(1025),a(25)),d=a(8),g=Object(d.a)((function(){return a.e(44).then(a.bind(null,1135))})),h=function(e){Object(o.a)(a,e);var t=Object(i.a)(a);function a(){var e;Object(r.a)(this,a);for(var n=arguments.length,c=new Array(n),o=0;o<n;o++)c[o]=arguments[o];return(e=t.call.apply(t,[this].concat(c))).closeIcon="https://cdn.julyedu.com/newyear20/H5/close-btn.png",e.state={prizes:[],notices:[],rule:[],unfoldList:!1},e.getPrizes=function(){m.f.get("".concat(API.home,"/sys/prize_data")).then((function(t){var a=t.data,n=a.code,r=a.data,c=a.msg;200==n?e.setState({prizes:r.prize_data,notices:r.notices,rule:r.rule}):s.a.info(c,2,null,!1)}))},e.showRules=function(){Object(p.h)({title:"\u7ec4\u961f\u5f00\u5b9d\u7bb1\u6d3b\u52a8\u89c4\u5219",className:"landing-treasure-rules",content:u.a.createElement("div",{dangerouslySetInnerHTML:{__html:e.state.rule}}),closeIcon:e.closeIcon})},e.showMore=function(){e.setState((function(t){if(e.state.unfoldList)e.bg.style=e.innerBox.style=e.prizeBox.style="";else{var a=parseFloat(getComputedStyle(e.prizeBox,":before").getPropertyValue("height")),n=parseFloat(getComputedStyle(e.prizeBox,":after").getPropertyValue("height")),s=e.prizeList.scrollHeight,r=a+s-.12458*a-.595*n+n;e.prizeBox.style.height="".concat(r+27,"px"),e.innerBox.style.height="".concat(s,"px"),e.bg.style.height="".concat(s-n+.12458*a+27,"px")}return{unfoldList:!t.unfoldList}}))},e}return Object(c.a)(a,[{key:"componentDidMount",value:function(){this.getPrizes()}},{key:"render",value:function(){var e=this,t=this.props.showSystemNotices,a=this.state.notices;return u.a.createElement(u.a.Fragment,null,t&&a&&a.length?u.a.createElement(g,{bullets:a}):null,u.a.createElement("div",{className:"prizes-box",ref:function(t){return e.prizeBox=t}},u.a.createElement("a",{href:"javascript:;",className:"rule-btn",onClick:this.showRules},"\u6d3b\u52a8\u89c4\u5219 >"," "),u.a.createElement("div",{className:"bg",ref:function(t){return e.bg=t}}),u.a.createElement("div",{className:"inner-box",ref:function(t){return e.innerBox=t}},u.a.createElement("ul",{className:"prize-list",ref:function(t){return e.prizeList=t}},this.state.prizes.map((function(e,t){return u.a.createElement("li",{key:t},e.img_name?u.a.createElement("i",{className:"prize-list__image",style:{backgroundImage:"url(".concat(e.img_name,")")}}):u.a.createElement("i",{className:"prize-list__image"}),0!=e.is_captain&&u.a.createElement("span",{className:"captain top-tag"},"\u961f\u957f\u4e13\u5c5e"),2===e.mode&&u.a.createElement("span",{className:"stage top-tag"},"\u7b2c",e.stage_no,"\u4e2a\u5fc5\u4e2d"),e.grant_max?u.a.createElement("div",{className:"bottom-bar"},u.a.createElement("div",{className:"progress-bar"},u.a.createElement("span",{className:"progress",style:{width:"".concat(e.surplus/e.grant_max*100,"%")}})),u.a.createElement("span",null,"\u9650\u91cf",e.grant_max,"\u4efd")):u.a.createElement("span",{className:"no-limit"},"\u4e0d\u9650\u91cf"))})),u.a.createElement("li",null,u.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/prize-placeholder.png",alt:""})))),u.a.createElement("div",{className:"show-more",onClick:this.showMore},this.state.unfoldList?u.a.createElement("div",null,"\u6536\u8d77",u.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/fold-icon.png",alt:""})):u.a.createElement("div",null,"\u67e5\u770b\u5168\u90e8\u5956\u54c1",u.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/unfold-icon.png",alt:""})))))}}]),a}(l.Component);t.a=h},582:function(e,t,a){"use strict";var n=a(73),s=a(3),r=a(5),c=a(58),o=a(6),i=a(7),l=a(0),u=a.n(l),m=a(1),p=a(139),d=(a(205),a(1026),function(e){Object(o.a)(a,e);var t=Object(i.a)(a);function a(){var e;Object(s.a)(this,a);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return(e=t.call.apply(t,[this].concat(o))).state={bulletScreenData:[]},e.initializeBulletScreen=function(){var t=Object(c.a)(e),a=Object(n.a)(Array(19).keys()),s=!1;e.swiper=new p.a(".swiper-container",{direction:"vertical",allowTouchMove:!1,autoplay:!0,on:{transitionEnd:function(){var e=this;this.slides.length>20&&(this.removeSlide(0),this.autoplay.start()),this.activeIndex!==this.slides.length-1||s||(this.autoplay.stop(),t.getBulletScreenData().then((function(n){s=!0,e.removeSlide(a),e.appendSlide(t.getSlides(n)),setTimeout((function(){e.autoplay.start(),s=!1}))})))}}})},e.getSlides=function(e){return e.map((function(e){return'\n <li class="swiper-slide">\n <img class="avatar" src="'.concat(e.avatar_file,'" alt="">\n <span>').concat(e.user_name," ").concat(e.msg,"</span>\n </li>\n ")}))},e.getBulletScreenData=function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return m.f.get("".concat(API.home,"/sys/barrage_data")).then((function(a){var n=a.data,s=n.data;if(200===n.code){if(!t)return s;e.setState({bulletScreenData:s},(function(){e.initializeBulletScreen()}))}}))},e}return Object(r.a)(a,[{key:"componentDidMount",value:function(){this.getBulletScreenData(!0)}},{key:"componentWillUnmount",value:function(){this.swiper&&this.swiper.destroy()}},{key:"render",value:function(){var e=this.state.bulletScreenData;return u.a.createElement("div",{id:"user-bullet-screen",className:"swiper-container"},u.a.createElement("ul",{className:"swiper-wrapper"},e.length&&e.map((function(e,t){return u.a.createElement("li",{className:"swiper-slide",key:t},u.a.createElement("img",{src:e.avatar_file,alt:"",className:"avatar"}),u.a.createElement("span",null,e.user_name," ",e.msg))}))))}}]),a}(l.Component));t.a=d},583:function(e,t,a){"use strict";a.d(t,"a",(function(){return l}));var n=a(3),s=a(5),r=a(6),c=a(7),o=a(0),i=a.n(o),l=(a(1030),function(e){Object(r.a)(a,e);var t=Object(c.a)(a);function a(){var e;Object(n.a)(this,a);for(var s=arguments.length,r=new Array(s),c=0;c<s;c++)r[c]=arguments[c];return(e=t.call.apply(t,[this].concat(r))).computedStyle=function(){return{top:"".concat(e.props.top,"px"),width:"".concat(e.props.width,"px")}},e.closePopup=function(){e.props.mark&&e.props.closePopup()},e}return Object(s.a)(a,[{key:"render",value:function(){return i.a.createElement("div",{className:"popup__container",onClick:this.closePopup},i.a.createElement("div",{className:"content__container",style:this.computedStyle(),onClick:function(e){e.stopPropagation()}},i.a.createElement("img",{className:"close__btn",onClick:this.props.closePopup,src:"https://cdn.julyedu.com/newyear20/H5/close-btn.png",alt:""}),i.a.Children.map(this.props.children,(function(e){return i.a.createElement(i.a.Fragment,null,e)}))))}}]),a}(o.Component))},650:function(e,t,a){"use strict";a(36);var n,s=a(10),r=a.n(s),c=a(4),o=a(3),i=a(5),l=a(58),u=a(6),m=a(7),p=a(0),d=a.n(p),g=(a(1028),a(1)),h=a(516),E=a(515),f=a(28),b=a(583),y=a(419),v=a.n(y),_=a(20),N=Object(_.b)((function(e){return{user:e.user}}))(n=function(e){Object(u.a)(a,e);var t=Object(m.a)(a);function a(e){var n;return Object(o.a)(this,a),(n=t.call(this,e)).getLength=function(){var e=Object(l.a)(n);g.f.get("".concat(API.home,"/activity/wish_sum")).then((function(t){var a=t.data,n=a.code,s=a.data;200===n&&e.setState({sum:s.sum})}))},n.fetchBigCourse=function(){var e=n.state.bigcourse;g.f.get("".concat(API.home,"/activity/preheat_data")).then((function(t){var a=t.data,s=a.code,r=a.data;200===s&&n.setState({bigcourse:Object.assign({},e,{isMore:!1,course:r,courseList:r})})}))},n.fetchFreeCourse=function(){var e=n.state.freecourse;g.f.get("".concat(API["base-api"],"/assistance/detail")).then((function(t){var a=t.data,s=a.errno,r=a.data;200===s&&n.setState({freecourse:Object.assign({},e,{isMore:r.course_info.length>4,course:r.course_info.length>4?r.course_info.filter((function(e,t){return t<4})):r.course_info,courseList:r.course_info})})}))},n.fetchGroupCourse=function(){var e=n.state.groupcourse;g.f.get("".concat(API.home,"/activity/excellent_course")).then((function(t){var a=t.data,s=a.code,r=a.data;200===s&&n.setState({groupcourse:Object.assign({},e,{isMore:r.length>4,course:r.length>4?r.filter((function(e,t){return t<4})):r,courseList:r})})}))},n.fetchAICourse=function(e,t){g.f.get("".concat(API.home,"/activity/four_stage/").concat(e)).then((function(a){var s=a.data,r=s.code,c=s.data;200===r&&n.getList(e,c,t)}))},n.getList=function(e,t,a){var s=n.state,r=s.basic,c=s.advanced,o=s.higher,i=s.expand;"one"===e&&n.setState({basic:Object.assign({},r,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})}),"two"===e&&n.setState({advanced:Object.assign({},c,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})}),"three"===e&&n.setState({higher:Object.assign({},o,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})}),"four"===e&&n.setState({expand:Object.assign({},i,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})})},n.toQQque=function(){Object(g.c)("version")?Object(g.a)("toQQ","https://q.url.cn/AB8aue?_type=wpa&qidian=true"):window.location.href="http://q.url.cn/s/Vbkup6m?_type=wpa"},n.toCourse=function(e){var t=n.props.history;Object(g.c)("version")?Object(g.a)("toCourse",e):t.push("/detail?id=".concat(e))},n.handleToMore=function(e){var t={};n.state[e].isMore?(t[e]={isMore:!n.state[e].isMore,course:n.state[e].courseList,courseList:n.state[e].courseList,addshowMore:!n.state[e].addshowMore},n.setState(Object(c.a)({},t))):(t[e]={isMore:!n.state[e].isMore,course:n.state[e].courseList.filter((function(e,t){return t<4})),courseList:n.state[e].courseList,addshowMore:!n.state[e].addshowMore},n.setState(Object(c.a)({},t)))},n.toLogin=function(){Object(g.c)("version")?Object(g.a)("toLogin"):n.props.history.push("/passport/login")},n.freeStudy=function(){n.setState({tofreeStudy:!0})},n.closePopup=function(){n.setState({tofreeStudy:!1})},n.closePopupWish=function(){var e=Object(l.a)(n);e.setState({isshowFollow:!1}),setTimeout((function(){e.toJoinList(e.state.wish.id,e.state.wish.key)}),200)},n.getQRcodeUrl=function(){var e=Object(l.a)(n);g.f.get("".concat(API["base-api"],"/wx/user_temporary_qrcode/").concat(e.props.user.data.uid)).then((function(e){var t=e.data,a=t.errno,s=t.data,c=t.msg;0===a?(n.setState({qrUrl:s.url}),v.a.toDataURL(s.url,(function(e,t){n.setState({followBarcode:t})}))):r.a.info(c,2)}))},n.addWishList=function(e,t){var a=Object(l.a)(n),s=!n.props.user.hasError;a.setState({wish:{id:e,key:t}}),s?a.isFollow(e,t):a.toLogin()},n.isFollow=function(e,t){var a=Object(l.a)(n);g.f.get("".concat(API.home,"/sys/user/isFollowWeChat")).then((function(n){var s=n.data,c=s.code,o=s.data,i=s.msg;200===c?(a.setState({isshowFollow:!o.is_follow}),a.state.isshowFollow?a.getQRcodeUrl():a.toJoinList(e,t)):r.a.info(i,2)}))},n.toJoinList=function(e,t){var a=Object(l.a)(n);g.f.post("".concat(API.home,"/activity/join_list"),{course_id:e}).then((function(e){var n=e.data,s=n.code,c=n.msg;200===s?(r.a.success("\u5df2\u6210\u529f\u52a0\u5165\u5fc3\u613f\u5355",3),a.getLength(),"1"===t&&a.fetchAICourse("one",a.state.basic.addshowMore),"2"===t&&a.fetchAICourse("two",a.state.advanced.addshowMore),"3"===t&&a.fetchAICourse("three",a.state.higher.addshowMore),"4"===t&&a.fetchAICourse("four",a.state.expand.addshowMore),"group"===t&&a.fetchGroupCourse()):r.a.info(c,2)}))},n.saveImage=function(){var e=Object(g.c)("version");e="string"===typeof e?e.replace(".","").replace(".","").slice(0,3):"";var t=n.state.qrUrl;e&&parseInt(e)<451?r.a.info("\u5f53\u524d\u4e0d\u652f\u6301\u6b64\u529f\u80fd\uff0c\u5347\u7ea7\u5230\u6700\u65b0\u7248\u672capp\u53ef\u4ee5\u70b9\u51fb\u4fdd\u5b58\u4e8c\u7ef4\u7801\uff01",3,null,!1):Object(g.a)("generateQRCode",t)},n.saveImage2=function(){var e=Object(g.c)("version");(e="string"===typeof e?e.replace(".","").replace(".","").slice(0,3):"")&&parseInt(e)<451?r.a.info("\u5f53\u524d\u4e0d\u652f\u6301\u6b64\u529f\u80fd\uff0c\u5347\u7ea7\u5230\u6700\u65b0\u7248\u672capp\u53ef\u4ee5\u70b9\u51fb\u4fdd\u5b58\u4e8c\u7ef4\u7801\uff01",3,null,!1):Object(g.a)("saveImage","https://cdn.julyedu.com/2018christyear/h5/qrcode.jpg")},n.getTeamInfo=function(){g.f.get("".concat(API.home,"/sys/treasure/teamInfo")).then((function(e){var t=e.data,a=t.code,s=t.data,c=t.msg;if(200===a){var o=s.info,i=s.removable_data;n.setState({removable:o.removable,currentId:o.removable>0?i[0].id:null})}else r.a.info(c)}))},n.toBoxList=function(){var e=!n.props.user.hasError,t=n.state.currentId,a="";t&&(a="?id=".concat(t)),e?Object(g.c)("version")?n.props.history.push("/year/yearTreasure".concat(a,"?version=").concat(Object(g.c)("version"))):n.props.history.push("/year/yearTreasure".concat(a)):n.toLogin()},n.toYearWish=function(){!n.props.user.hasError?Object(g.c)("version")?n.props.history.push("/year/yearWish?version=".concat(Object(g.c)("version"))):n.props.history.push("/year/yearWish"):n.toLogin()},n.toInviteFriends=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=n.props.history;if(Object(g.c)("version")){var s={title:"\u3010\u4ec5\u5269".concat(t.number,"\u4e2a\u540d\u989d\u3011\u6211").concat(t.price,"\u5143\u62fc\u4e86\u300a").concat(t.course_title,"\u300b"),desc:t.course_title,link:"".concat(API.m,"/togroup?id=").concat(e,"&is_originator=1"),imgUrl:t.image_name};Object(g.a)("toShare",s)}else a.push("/togroup?id=".concat(e))},n.isCountDown=function(e,t){return e?t:""},n.formatTitleAndKey=function(e){var t=null;switch(e){case 1:t={title:"\u57fa\u7840",key:"basic"};break;case 2:t={title:"\u8fdb\u9636",key:"advanced"};break;case 3:t={title:"\u9ad8\u9636",key:"higher"};break;case 4:t={title:"\u6269\u5c55",key:"expand"};break;default:t=null}return t},n.formatCourseData=function(e){var t=n.state,a=t.basic,s=t.advanced,r=t.higher,c=t.expand,o=null;switch(e){case 1:o=a;break;case 2:o=s;break;case 3:o=r;break;case 4:o=c;break;default:o=null}return o},n.toCart=function(e){var t=n.props.history;g.f.post("".concat(API.home,"/m/cart/add"),{course_id:e}).then((function(e){var a=e.data,s=a.code,c=a.msg;200===s||15001===s?Object(g.c)("version")?Object(g.a)("toShoppingCart"):t.push("/shopcart"):4030===s||4040===s?n.toLogin():r.a.info(c,2)}))},n.toContinueBargain=function(e,t,a,s){var r=n.props.history;if(Object(g.c)("version")){var c={title:"\u6211\u53d1\u73b0\u4e00\u95e8\u597d\u8bfe\uff0c\u5feb\u6765\u5e2e\u6211\u780d\u4ef7\u5427\uff01",desc:"\u6211\u5df2\u7ecf\u780d\u4e86".concat(t,"\u5143\uff0c\u770b\u770b\u4f60\u80fd\u780d\u591a\u5c11"),link:"".concat(API.m,"/bargain-middle-page?id=").concat(e,"&bargaincode=").concat(a,"&is_originator=1"),imgUrl:s};Object(g.a)("toShare",c)}else r.push("/bargain-middle-page?id=".concat(e,"&bargaincode=").concat(a,"&is_originator=1"))},n.bargainToOrder=function(e){var t=n.props,a=t.history;t.user.hasError?n.toLogin():Object(g.c)("version")?Object(g.a)("toPay",e):g.f.get("".concat(API["base-api"],"/m/cart/addtopreorder/[").concat(e,"]")).then((function(t){var n=t.data,s=n.errno,c=n.msg;0===s?a.push("/order?id=[".concat(e,"]"),{bargain:1}):r.a.info(c,2)}))},n.state={tofreeStudy:!1,basic:{course:[],courseList:[],isMore:!1,addshowMore:!1},advanced:{course:[],courseList:[],isMore:!1,addshowMore:!1},higher:{course:[],courseList:[],isMore:!1,addshowMore:!1},expand:{course:[],courseList:[],isMore:!1,addshowMore:!1},bigcourse:{course:[],courseList:[],isMore:!1},freecourse:{course:[],courseList:[],isMore:!1},groupcourse:{course:[],courseList:[],isMore:!1},isshowFollow:!1,wish:{id:"",key:""},followBarcode:"",qrUrl:"",sum:"",removable:"",currentId:""},n}return Object(i.a)(a,[{key:"componentDidMount",value:function(){this.getTeamInfo(),this.getLength(),this.fetchBigCourse(),this.fetchGroupCourse(),this.fetchAICourse("one",!1),this.fetchAICourse("two",!1),this.fetchAICourse("three",!1),this.fetchAICourse("four",!1)}},{key:"shouldComponentUpdate",value:function(e,t,a){return this.props.isAppUpdate===e.isAppUpdate||(this.getTeamInfo(),this.getLength(),this.fetchBigCourse(),this.fetchGroupCourse(),this.fetchAICourse("one"),this.fetchAICourse("two"),this.fetchAICourse("three"),this.fetchAICourse("four"),!1)}},{key:"render",value:function(){var e=this,t=this.state,a=t.bigcourse,n=t.groupcourse,s=t.basic,r=t.advanced,c=t.higher,o=t.expand,i=t.removable,l=this.props.stage;return d.a.createElement("div",{className:"year-index-course"},d.a.createElement("div",{className:"nav-right-wish nav-right"},d.a.createElement("span",{onClick:this.toBoxList,className:"nav-right__link"},"\u672a\u5f00\u5b9d\u7bb1",i>0&&d.a.createElement("i",{className:"nav-right__number"},i))),d.a.createElement(h.a,{title:"\u9a70\u63f4\u6b66\u6c49 \u6ce8\u518c\u5373\u9001",id:"year-wuhan"},d.a.createElement("div",{className:"course-box course-conter"},d.a.createElement("div",{className:"course-item"},d.a.createElement("span",null,"\u6ce8\u518c\u5373\u9001"),d.a.createElement("a",{href:"/detail?id=224"},d.a.createElement("img",{src:"http://img-public.julyedu.com/Public/Image/75d1c3cef5.png",alt:""}))),d.a.createElement("div",{className:"course-item"},d.a.createElement("span",null,"\u6ce8\u518c\u5373\u9001"),d.a.createElement("a",{href:"/detail?id=206"},d.a.createElement("img",{src:"https://img-public.julyedu.com/Public/Image/b001fac23f.png",alt:""}))),d.a.createElement("div",{className:"course-item"},d.a.createElement("span",null,"\u6ce8\u518c\u5373\u9001"),d.a.createElement("a",{href:"/detail?id=230"},d.a.createElement("img",{src:"https://img-public.julyedu.com/Public/Image/d0fb0a479b.png",alt:""}))))),d.a.createElement(h.a,{title:"\u91cd\u78c5\u597d\u8bfe\u9650\u65f6\u514d\u8d39\u8bd5\u542c",id:"year-course"},a.course&&a.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"bigcourse course-box"},a.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},1===Number(t.is_vip)&&d.a.createElement("a",{className:"btn big-course",onClick:function(){return e.toQQque()}},"\u9996\u8d2d\xa599\u8d77"),0==t.is_vip&&d.a.createElement(d.a.Fragment,null,1==t.is_buy&&d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-study"},"\u5f00\u59cb\u5b66\u4e60"),0==t.is_buy&&d.a.createElement("a",{onClick:function(){return e.toQQque()},className:"btn big-course"},1==t.is_audition?"\u514d\u8d39\u8bd5\u542c":"\u62a2\u56e2\u62a5\u540d\u989d"))))}))))),1!==Number(l)&&d.a.createElement(d.a.Fragment,null,d.a.createElement(h.a,{title:"\u7cbe\u54c1\u597d\u8bfe1\u5206\u79d2",id:"year-group"},n.course&&n.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box","data-stage":"2"},n.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,time:e.isCountDown(1===t.is_assemble,t.add_time),toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},2==t.is_assemble&&d.a.createElement(d.a.Fragment,null,d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("div",{className:"status"},d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-group","data-status":"study"},"\u5f00\u59cb\u5b66\u4e60"))),2!=t.is_assemble&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},d.a.createElement("span",{className:"tag","data-color":"green"},"\u62fc\u56e2\u4ef7")),d.a.createElement("div",{className:"price price-group"},d.a.createElement("span",{className:"price-label"},"\xa5"),d.a.createElement("span",{className:"new-price"},"0.01"),d.a.createElement("span",{className:"old-price"},d.a.createElement("s",null,"\xa5",t.price1))),0==t.is_assemble&&d.a.createElement("div",{className:"progree-and-sale"},d.a.createElement("div",{className:"progress"},d.a.createElement("i",{className:"progress_bar",style:{width:"".concat(t.progress,"%")}})),d.a.createElement("p",{className:"sale-sum"},Number(t.sum<=285)?"\u5df2\u62a2".concat(t.sum,"\u4e2a"):"\u5373\u5c06\u552e\u7f44")),d.a.createElement("div",{className:"status"},0==t.is_assemble&&d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-group"},"\u9a6c\u4e0a\u62a2>>"),1==t.is_assemble&&d.a.createElement("a",{onClick:function(){return e.toInviteFriends(t.order_id,{number:t.number,course_title:t.course_title,image_name:t.image_name,price:.01})},className:"status-btn to-group","data-status":"done"},"\u5df2\u53c2\u56e2\uff0c\u9080\u8bf7\u597d\u53cb\u53c2\u56e2")))))}))),n.courseList&&n.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore("groupcourse")}},n.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77"))),d.a.createElement(h.a,{title:"\u201c\u85aa\u201d\u5e74\u4ef7\u5230\uff0c\u7b49\u4f60\u6284\u5e95\uff01",id:"year-discount"},[1,2,3,4].map((function(t){var a=e.formatTitleAndKey(t),n=e.formatCourseData(t);return d.a.createElement(d.a.Fragment,{key:t},d.a.createElement("h4",{className:"ai-course__subtitle"},a.title),n.course&&n.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box"},n.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,time:e.isCountDown(2===t.type,t.end_time),toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},(4===t.type||8===t.type)&&d.a.createElement("div",{className:"bargain-price"},"\u5df2\u780d",t.already_bargain,"\u5143"),0===t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},d.a.createElement("span",{className:"tag","data-color":"green"},"\u6d3b\u52a8\u4ef7")),d.a.createElement("div",{className:"price price-group"},d.a.createElement("span",{className:"price-label"},"\xa5"),d.a.createElement("span",{className:"new-price"},t.original_price),d.a.createElement("span",{className:"old-price"},d.a.createElement("s",null,"\xa5",t.price1)))),(1===t.type||2===t.type)&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},d.a.createElement("span",{className:"tag","data-color":"green"},"\u62fc\u56e2\u4ef7")),d.a.createElement("div",{className:"price price-group"},d.a.createElement("span",{className:"price-label"},"\xa5"),d.a.createElement("span",{className:"new-price"},t.pdd_price),d.a.createElement("span",{className:"old-price"},d.a.createElement("s",null,"\xa5",t.original_price)))),(3===t.type||4===t.type||8===t.type)&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},d.a.createElement("span",{className:"tag","data-color":"green"},"\u597d\u53cb\u5e2e\u5e2e\u780d")),d.a.createElement("div",{className:"price price-group"},d.a.createElement("span",{className:"price-label"},"\u5230\u624b\u6700\u4f4e\uff1a\xa5"),d.a.createElement("span",{className:"new-price"},t.low_prize),d.a.createElement("span",{className:"old-price"},d.a.createElement("s",null,"\xa5",t.original_price)))),6===t.type&&d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("div",{className:"status","data-layout":4===t.type?"row":""},0===t.type&&d.a.createElement("a",{onClick:function(){return e.toCart(t.course_id)},className:"status-btn to-group"},"\u7acb\u5373\u8d2d\u4e70"),1===t.type&&d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-group"},"\u7acb\u5373\u53c2\u4e0e\u62fc\u56e2"),2===t.type&&d.a.createElement("a",{onClick:function(){return e.toInviteFriends(t.order_id,{number:t.number,course_title:t.course_title,image_name:t.image_name,price:t.pdd_price})},className:"status-btn to-group","data-status":"done"},"\u5df2\u53c2\u56e2\uff0c\u9080\u8bf7\u597d\u53cb\u53c2\u56e2"),3===t.type&&d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-group"},"\u6211\u8981\u780d\u4ef7"),4===t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("a",{onClick:function(){return e.toContinueBargain(t.course_id,t.already_bargain,t.bargain_code,t.image_name)},className:"status-btn to-group"},"\u7ee7\u7eed\u780d\u4ef7"),d.a.createElement("a",{onClick:function(){return e.bargainToOrder(t.course_id)},className:"status-btn to-group"},"\u652f\u4ed8",t.actual_payment,"\u5143")),8===t.type&&d.a.createElement("a",{onClick:function(){return e.bargainToOrder(t.course_id)},className:"status-btn to-group"},"\u652f\u4ed8",t.actual_payment,"\u5143"),6===t.type&&d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-group","data-status":"study"},"\u5f00\u59cb\u5b66\u4e60"))))}))),n.courseList&&n.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore(a.key)}},n.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77")))})))),1===Number(l)&&d.a.createElement(d.a.Fragment,null,d.a.createElement(h.a,{title:"\u7cbe\u54c1\u597d\u8bfe1\u5206\u5f00\u62a2",id:"year-group"},n.course&&n.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box"},n.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,toCourse:e.toCourse},d.a.createElement("div",{className:"group-num"},"\u9650\u91cf300\u4e2a"),d.a.createElement("div",{className:"coupon-course__footer"},1==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-study"},"\u5f00\u59cb\u5b66\u4e60")),0==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},d.a.createElement("span",{className:"tag"},"\u62fc\u56e2\u4ef7"),d.a.createElement("span",{className:"time"},"12\u670823\u65e5\u5f00\u56e2")),d.a.createElement("div",{className:"price"},"\xa5",d.a.createElement("span",{className:"new-price"},"0.01"),d.a.createElement("span",{className:"old-price"},"\u73b0\u4ef7\uff1a",d.a.createElement("s",null,"\xa5",t.price1))),d.a.createElement("div",{className:"status"},d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-buy"},"\u76f4\u63a5\u8d2d\u4e70"),1==t.is_join&&d.a.createElement("a",{className:"status-btn add-wish"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/PC/add-success.png",alt:""}),"\u5df2\u52a0\u5fc3\u613f\u5355"),0==t.is_join&&d.a.createElement("a",{onClick:function(){return e.addWishList(t.course_id,"group")},className:"status-btn add-wish-success"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/like_icon.png",alt:""}),"\u52a0\u5165\u5fc3\u613f\u5355")))))}))),n.courseList&&n.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore("groupcourse")}},n.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77"))),d.a.createElement(h.a,{title:"\u597d\u8bfe\u4ef7\u5230\uff0c\u7b49\u4f60\u6284\u5e95",id:"year-discount"},d.a.createElement("h4",{className:"ai-course__subtitle"},"\u57fa\u7840"),s.course&&s.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box"},s.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},1==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-study"},"\u5f00\u59cb\u5b66\u4e60")),0==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},0==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u6d3b\u52a8\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u59cb")),1==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u62fc\u56e2\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u56e2")),2==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u597d\u53cb\u5e2e\u5e2e\u780d"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u780d"))),d.a.createElement("div",{className:"price"},2==t.type?"\u5230\u624b\u6700\u4f4e:\xa5":"\xa5",d.a.createElement("span",{className:"new-price"},t.price2),d.a.createElement("span",{className:"old-price"},2==t.type?"":"\u73b0\u4ef7\uff1a",d.a.createElement("s",null,"\xa5",t.price1))),d.a.createElement("div",{className:"status"},d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-buy"},"\u76f4\u63a5\u8d2d\u4e70"),1==t.is_join&&d.a.createElement("a",{className:"status-btn add-wish"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/PC/add-success.png",alt:""}),"\u5df2\u52a0\u5fc3\u613f\u5355"),0==t.is_join&&d.a.createElement("a",{onClick:function(){return e.addWishList(t.course_id,"1")},className:"status-btn add-wish-success"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/like_icon.png",alt:""}),"\u52a0\u5165\u5fc3\u613f\u5355")))))}))),s.courseList&&s.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore("basic")}},s.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77")),d.a.createElement("h4",{className:"ai-course__subtitle"},"\u8fdb\u9636"),r.course&&r.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box"},r.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},1==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-study"},"\u5f00\u59cb\u5b66\u4e60")),0==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},0==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u6d3b\u52a8\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u59cb")),1==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u62fc\u56e2\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u56e2")),2==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u597d\u53cb\u5e2e\u5e2e\u780d"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u780d"))),d.a.createElement("div",{className:"price"},2==t.type?"\u5230\u624b\u6700\u4f4e:\xa5":"\xa5",d.a.createElement("span",{className:"new-price"},t.price2),d.a.createElement("span",{className:"old-price"},2==t.type?"":"\u73b0\u4ef7\uff1a",d.a.createElement("s",null,"\xa5",t.price1))),d.a.createElement("div",{className:"status"},d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-buy"},"\u76f4\u63a5\u8d2d\u4e70"),1==t.is_join&&d.a.createElement("a",{className:"status-btn add-wish"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/PC/add-success.png",alt:""}),"\u5df2\u52a0\u5fc3\u613f\u5355"),0==t.is_join&&d.a.createElement("a",{onClick:function(){return e.addWishList(t.course_id,"2")},className:"status-btn add-wish-success"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/like_icon.png",alt:""}),"\u52a0\u5165\u5fc3\u613f\u5355")))))}))),r.courseList&&r.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore("advanced")}},r.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77")),d.a.createElement("h4",{className:"ai-course__subtitle"},"\u9ad8\u9636"),c.course&&c.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box"},c.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},1==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-study"},"\u5f00\u59cb\u5b66\u4e60")),0==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},0==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u6d3b\u52a8\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u59cb")),1==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u62fc\u56e2\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u56e2")),2==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u597d\u53cb\u5e2e\u5e2e\u780d"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u780d"))),d.a.createElement("div",{className:"price"},2==t.type?"\u5230\u624b\u6700\u4f4e:\xa5":"\xa5",d.a.createElement("span",{className:"new-price"},t.price2),d.a.createElement("span",{className:"old-price"},2==t.type?"":"\u73b0\u4ef7\uff1a",d.a.createElement("s",null,"\xa5",t.price1))),d.a.createElement("div",{className:"status"},d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-buy"},"\u76f4\u63a5\u8d2d\u4e70"),1==t.is_join&&d.a.createElement("a",{className:"status-btn add-wish"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/PC/add-success.png",alt:""}),"\u5df2\u52a0\u5fc3\u613f\u5355"),0==t.is_join&&d.a.createElement("a",{onClick:function(){return e.addWishList(t.course_id,"3")},className:"status-btn add-wish-success"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/like_icon.png",alt:""}),"\u52a0\u5165\u5fc3\u613f\u5355")))))}))),c.courseList&&c.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore("higher")}},c.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77")),d.a.createElement("h4",{className:"ai-course__subtitle"},"\u6269\u5c55"),o.course&&o.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box"},o.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},1==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-study"},"\u5f00\u59cb\u5b66\u4e60")),0==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},0==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u6d3b\u52a8\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u59cb")),1==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u62fc\u56e2\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u56e2")),2==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u597d\u53cb\u5e2e\u5e2e\u780d"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u780d"))),d.a.createElement("div",{className:"price"},2==t.type?"\u5230\u624b\u6700\u4f4e:\xa5":"\xa5",d.a.createElement("span",{className:"new-price"},t.price2),d.a.createElement("span",{className:"old-price"},2==t.type?"":"\u73b0\u4ef7\uff1a",d.a.createElement("s",null,"\xa5",t.price1))),d.a.createElement("div",{className:"status"},d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-buy"},"\u76f4\u63a5\u8d2d\u4e70"),1==t.is_join&&d.a.createElement("a",{className:"status-btn add-wish"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/PC/add-success.png",alt:""}),"\u5df2\u52a0\u5fc3\u613f\u5355"),0==t.is_join&&d.a.createElement("a",{onClick:function(){return e.addWishList(t.course_id,"4")},className:"status-btn add-wish-success"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/like_icon.png",alt:""}),"\u52a0\u5165\u5fc3\u613f\u5355")))))}))),o.courseList&&o.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore("expand")}},o.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77")))),this.state.tofreeStudy&&d.a.createElement(b.a,{top:100,closePopup:this.closePopup,mark:!1},d.a.createElement("div",{className:"sub__code_container"},d.a.createElement("p",{className:"sub__title"},"\u63d0\u9192\u670d\u52a1"),d.a.createElement("p",{className:"sub__tip"},"\u8fdb\u5165\u670d\u52a1\u53f7\u56de\u590d",d.a.createElement("i",null,"77"),"\u514d\u8d39\u9886\u53d6\u8bfe\u7a0b"),d.a.createElement("img",{className:"sub__qr_code",id:"live-qr-code",src:"//cdn.julyedu.com/2018christyear/h5/qrcode.jpg",alt:""}),g.b.isAndroidApp?d.a.createElement("button",{className:"save-image",onClick:this.saveImage2},"\u4fdd\u5b58\u4e8c\u7ef4\u7801"):d.a.createElement("p",{className:"sub__tip"},"\u957f\u6309\u8bc6\u522b/\u626b\u7801 \u5173\u6ce8\u3010\u4e03\u6708\u5728\u7ebf\u3011\u670d\u52a1\u53f7"))),this.state.isshowFollow&&d.a.createElement(b.a,{top:100,closePopup:this.closePopupWish,mark:!1},d.a.createElement("div",{className:"sub__code_container"},d.a.createElement("p",{className:"sub__title"},"\u63d0\u9192\u670d\u52a1"),d.a.createElement("p",{className:"sub__tip"},"\u8bfe\u7a0b\u5f00\u552e\u7acb\u5373\u63d0\u9192\uff0c\u4e0d\u9519\u8fc7\u4efb\u4f55\u4f18\u60e0\u54e6\uff01"),d.a.createElement("img",{className:"sub__qr_code",id:"live-qr-code",src:this.state.followBarcode,alt:""}),g.b.isAndroidApp?d.a.createElement("button",{className:"save-image",onClick:this.saveImage},"\u4fdd\u5b58\u4e8c\u7ef4\u7801"):d.a.createElement("p",{className:"sub__tip"},"\u957f\u6309\u8bc6\u522b/\u626b\u7801 \u5173\u6ce8\u3010\u4e03\u6708\u5728\u7ebf\u3011\u670d\u52a1\u53f7"))))}}]),a}(p.Component))||n;t.a=Object(f.g)(N)}}]); (this["webpackJsonpmr-julyedu"]=this["webpackJsonpmr-julyedu"]||[]).push([[2],{1025:function(e,t,a){},1026:function(e,t,a){},1028:function(e,t,a){},1029:function(e,t,a){},1030:function(e,t,a){},515:function(e,t,a){"use strict";var n=a(3),s=a(5),r=a(6),c=a(7),o=a(0),i=a.n(o),l=(a(579),function(e){Object(r.a)(a,e);var t=Object(c.a)(a);function a(e){var s;return Object(n.a)(this,a),(s=t.call(this,e)).startCountDown=function(e){if(e){var t=1e3*e,a=0,n=0,r=0;setInterval((function(){t-=1e3,a="".concat(parseInt(t/36e5)).padStart(2,0),n="".concat(parseInt((t-36e5*a)/6e4)).padStart(2,0),r="".concat(parseInt((t-36e5*a-6e4*n)/1e3)).padStart(2,0),s.setState({countdown:"".concat(a,"\u65f6").concat(n,"\u5206").concat(r,"\u79d2\u540e\u7ed3\u675f")})}),1e3)}},s.state={countdown:""},s}return Object(s.a)(a,[{key:"componentDidMount",value:function(){var e=this.props.time;this.startCountDown(e)}},{key:"componentWillReceiveProps",value:function(e){var t=e.time;this.props.time!=t&&this.startCountDown(t)}},{key:"render",value:function(){var e=this.props,t=e.image,a=e.toCourse,n=e.id,s=this.state.countdown;return i.a.createElement("div",{className:"course-container"},i.a.createElement("div",{className:"course__cover"},s&&i.a.createElement("p",{className:"course__time"},s),i.a.createElement("img",{src:t,alt:"cover",onClick:function(){return a(n)}})),this.props.children)}}]),a}(o.Component));t.a=l},516:function(e,t,a){"use strict";a.d(t,"a",(function(){return l}));var n=a(3),s=a(5),r=a(6),c=a(7),o=a(0),i=a.n(o),l=(a(1029),function(e){Object(r.a)(a,e);var t=Object(c.a)(a);function a(){return Object(n.a)(this,a),t.apply(this,arguments)}return Object(s.a)(a,[{key:"render",value:function(){var e=this.props.id;return i.a.createElement("div",{className:"common_container",id:e},i.a.createElement("div",{className:"container_top"}),i.a.createElement("div",{className:"container_content"},this.props.title&&i.a.createElement("div",{className:"title_container"},i.a.createElement("i",null),i.a.createElement("p",null,this.props.title),i.a.createElement("i",null)),i.a.Children.map(this.props.children,(function(e){return i.a.createElement(i.a.Fragment,null,e)}))),i.a.createElement("div",{className:"container_bottom"}))}}]),a}(o.Component))},579:function(e,t,a){},581:function(e,t,a){"use strict";a(36);var n=a(10),s=a.n(n),r=a(3),c=a(5),o=a(6),i=a(7),l=a(0),u=a.n(l),m=a(1),p=(a(1025),a(25)),d=a(8),g=Object(d.a)((function(){return a.e(44).then(a.bind(null,1135))})),h=function(e){Object(o.a)(a,e);var t=Object(i.a)(a);function a(){var e;Object(r.a)(this,a);for(var n=arguments.length,c=new Array(n),o=0;o<n;o++)c[o]=arguments[o];return(e=t.call.apply(t,[this].concat(c))).closeIcon="https://cdn.julyedu.com/newyear20/H5/close-btn.png",e.state={prizes:[],notices:[],rule:[],unfoldList:!1},e.getPrizes=function(){m.f.get("".concat(API.home,"/sys/prize_data")).then((function(t){var a=t.data,n=a.code,r=a.data,c=a.msg;200==n?e.setState({prizes:r.prize_data,notices:r.notices,rule:r.rule}):s.a.info(c,2,null,!1)}))},e.showRules=function(){Object(p.h)({title:"\u7ec4\u961f\u5f00\u5b9d\u7bb1\u6d3b\u52a8\u89c4\u5219",className:"landing-treasure-rules",content:u.a.createElement("div",{dangerouslySetInnerHTML:{__html:e.state.rule}}),closeIcon:e.closeIcon})},e.showMore=function(){e.setState((function(t){if(e.state.unfoldList)e.bg.style=e.innerBox.style=e.prizeBox.style="";else{var a=parseFloat(getComputedStyle(e.prizeBox,":before").getPropertyValue("height")),n=parseFloat(getComputedStyle(e.prizeBox,":after").getPropertyValue("height")),s=e.prizeList.scrollHeight,r=a+s-.12458*a-.595*n+n;e.prizeBox.style.height="".concat(r+27,"px"),e.innerBox.style.height="".concat(s,"px"),e.bg.style.height="".concat(s-n+.12458*a+27,"px")}return{unfoldList:!t.unfoldList}}))},e}return Object(c.a)(a,[{key:"componentDidMount",value:function(){this.getPrizes()}},{key:"render",value:function(){var e=this,t=this.props.showSystemNotices,a=this.state.notices;return u.a.createElement(u.a.Fragment,null,t&&a&&a.length?u.a.createElement(g,{bullets:a}):null,u.a.createElement("div",{className:"prizes-box",ref:function(t){return e.prizeBox=t}},u.a.createElement("a",{href:"javascript:;",className:"rule-btn",onClick:this.showRules},"\u6d3b\u52a8\u89c4\u5219 >"," "),u.a.createElement("div",{className:"bg",ref:function(t){return e.bg=t}}),u.a.createElement("div",{className:"inner-box",ref:function(t){return e.innerBox=t}},u.a.createElement("ul",{className:"prize-list",ref:function(t){return e.prizeList=t}},this.state.prizes.map((function(e,t){return u.a.createElement("li",{key:t},e.img_name?u.a.createElement("i",{className:"prize-list__image",style:{backgroundImage:"url(".concat(e.img_name,")")}}):u.a.createElement("i",{className:"prize-list__image"}),0!=e.is_captain&&u.a.createElement("span",{className:"captain top-tag"},"\u961f\u957f\u4e13\u5c5e"),2===e.mode&&u.a.createElement("span",{className:"stage top-tag"},"\u7b2c",e.stage_no,"\u4e2a\u5fc5\u4e2d"),e.grant_max?u.a.createElement("div",{className:"bottom-bar"},u.a.createElement("div",{className:"progress-bar"},u.a.createElement("span",{className:"progress",style:{width:"".concat(e.surplus/e.grant_max*100,"%")}})),u.a.createElement("span",null,"\u9650\u91cf",e.grant_max,"\u4efd")):u.a.createElement("span",{className:"no-limit"},"\u4e0d\u9650\u91cf"))})),u.a.createElement("li",null,u.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/prize-placeholder.png",alt:""})))),u.a.createElement("div",{className:"show-more",onClick:this.showMore},this.state.unfoldList?u.a.createElement("div",null,"\u6536\u8d77",u.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/fold-icon.png",alt:""})):u.a.createElement("div",null,"\u67e5\u770b\u5168\u90e8\u5956\u54c1",u.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/unfold-icon.png",alt:""})))))}}]),a}(l.Component);t.a=h},582:function(e,t,a){"use strict";var n=a(73),s=a(3),r=a(5),c=a(58),o=a(6),i=a(7),l=a(0),u=a.n(l),m=a(1),p=a(139),d=(a(205),a(1026),function(e){Object(o.a)(a,e);var t=Object(i.a)(a);function a(){var e;Object(s.a)(this,a);for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return(e=t.call.apply(t,[this].concat(o))).state={bulletScreenData:[]},e.initializeBulletScreen=function(){var t=Object(c.a)(e),a=Object(n.a)(Array(19).keys()),s=!1;e.swiper=new p.a(".swiper-container",{direction:"vertical",allowTouchMove:!1,autoplay:!0,on:{transitionEnd:function(){var e=this;this.slides.length>20&&(this.removeSlide(0),this.autoplay.start()),this.activeIndex!==this.slides.length-1||s||(this.autoplay.stop(),t.getBulletScreenData().then((function(n){s=!0,e.removeSlide(a),e.appendSlide(t.getSlides(n)),setTimeout((function(){e.autoplay.start(),s=!1}))})))}}})},e.getSlides=function(e){return e.map((function(e){return'\n <li class="swiper-slide">\n <img class="avatar" src="'.concat(e.avatar_file,'" alt="">\n <span>').concat(e.user_name," ").concat(e.msg,"</span>\n </li>\n ")}))},e.getBulletScreenData=function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return m.f.get("".concat(API.home,"/sys/barrage_data")).then((function(a){var n=a.data,s=n.data;if(200===n.code){if(!t)return s;e.setState({bulletScreenData:s},(function(){e.initializeBulletScreen()}))}}))},e}return Object(r.a)(a,[{key:"componentDidMount",value:function(){this.getBulletScreenData(!0)}},{key:"componentWillUnmount",value:function(){this.swiper&&this.swiper.destroy()}},{key:"render",value:function(){var e=this.state.bulletScreenData;return u.a.createElement("div",{id:"user-bullet-screen",className:"swiper-container"},u.a.createElement("ul",{className:"swiper-wrapper"},e.length&&e.map((function(e,t){return u.a.createElement("li",{className:"swiper-slide",key:t},u.a.createElement("img",{src:e.avatar_file,alt:"",className:"avatar"}),u.a.createElement("span",null,e.user_name," ",e.msg))}))))}}]),a}(l.Component));t.a=d},583:function(e,t,a){"use strict";a.d(t,"a",(function(){return l}));var n=a(3),s=a(5),r=a(6),c=a(7),o=a(0),i=a.n(o),l=(a(1030),function(e){Object(r.a)(a,e);var t=Object(c.a)(a);function a(){var e;Object(n.a)(this,a);for(var s=arguments.length,r=new Array(s),c=0;c<s;c++)r[c]=arguments[c];return(e=t.call.apply(t,[this].concat(r))).computedStyle=function(){return{top:"".concat(e.props.top,"px"),width:"".concat(e.props.width,"px")}},e.closePopup=function(){e.props.mark&&e.props.closePopup()},e}return Object(s.a)(a,[{key:"render",value:function(){return i.a.createElement("div",{className:"popup__container",onClick:this.closePopup},i.a.createElement("div",{className:"content__container",style:this.computedStyle(),onClick:function(e){e.stopPropagation()}},i.a.createElement("img",{className:"close__btn",onClick:this.props.closePopup,src:"https://cdn.julyedu.com/newyear20/H5/close-btn.png",alt:""}),i.a.Children.map(this.props.children,(function(e){return i.a.createElement(i.a.Fragment,null,e)}))))}}]),a}(o.Component))},650:function(e,t,a){"use strict";a(36);var n,s=a(10),r=a.n(s),c=a(4),o=a(3),i=a(5),l=a(58),u=a(6),m=a(7),p=a(0),d=a.n(p),g=(a(1028),a(1)),h=a(516),E=a(515),f=a(28),b=a(583),y=a(419),v=a.n(y),_=a(20),N=Object(_.b)((function(e){return{user:e.user}}))(n=function(e){Object(u.a)(a,e);var t=Object(m.a)(a);function a(e){var n;return Object(o.a)(this,a),(n=t.call(this,e)).getLength=function(){var e=Object(l.a)(n);g.f.get("".concat(API.home,"/activity/wish_sum")).then((function(t){var a=t.data,n=a.code,s=a.data;200===n&&e.setState({sum:s.sum})}))},n.fetchBigCourse=function(){var e=n.state.bigcourse;g.f.get("".concat(API.home,"/activity/preheat_data")).then((function(t){var a=t.data,s=a.code,r=a.data;200===s&&n.setState({bigcourse:Object.assign({},e,{isMore:!1,course:r,courseList:r})})}))},n.fetchFreeCourse=function(){var e=n.state.freecourse;g.f.get("".concat(API["base-api"],"/assistance/detail")).then((function(t){var a=t.data,s=a.errno,r=a.data;200===s&&n.setState({freecourse:Object.assign({},e,{isMore:r.course_info.length>4,course:r.course_info.length>4?r.course_info.filter((function(e,t){return t<4})):r.course_info,courseList:r.course_info})})}))},n.fetchGroupCourse=function(){var e=n.state.groupcourse;g.f.get("".concat(API.home,"/activity/excellent_course")).then((function(t){var a=t.data,s=a.code,r=a.data;200===s&&n.setState({groupcourse:Object.assign({},e,{isMore:r.length>4,course:r.length>4?r.filter((function(e,t){return t<4})):r,courseList:r})})}))},n.fetchAICourse=function(e,t){g.f.get("".concat(API.home,"/activity/four_stage/").concat(e)).then((function(a){var s=a.data,r=s.code,c=s.data;200===r&&n.getList(e,c,t)}))},n.getList=function(e,t,a){var s=n.state,r=s.basic,c=s.advanced,o=s.higher,i=s.expand;"one"===e&&n.setState({basic:Object.assign({},r,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})}),"two"===e&&n.setState({advanced:Object.assign({},c,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})}),"three"===e&&n.setState({higher:Object.assign({},o,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})}),"four"===e&&n.setState({expand:Object.assign({},i,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})})},n.toQQque=function(){Object(g.c)("version")?Object(g.a)("toQQ","https://q.url.cn/AB8aue?_type=wpa&qidian=true"):window.location.href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"},n.toCourse=function(e){var t=n.props.history;Object(g.c)("version")?Object(g.a)("toCourse",e):t.push("/detail?id=".concat(e))},n.handleToMore=function(e){var t={};n.state[e].isMore?(t[e]={isMore:!n.state[e].isMore,course:n.state[e].courseList,courseList:n.state[e].courseList,addshowMore:!n.state[e].addshowMore},n.setState(Object(c.a)({},t))):(t[e]={isMore:!n.state[e].isMore,course:n.state[e].courseList.filter((function(e,t){return t<4})),courseList:n.state[e].courseList,addshowMore:!n.state[e].addshowMore},n.setState(Object(c.a)({},t)))},n.toLogin=function(){Object(g.c)("version")?Object(g.a)("toLogin"):n.props.history.push("/passport/login")},n.freeStudy=function(){n.setState({tofreeStudy:!0})},n.closePopup=function(){n.setState({tofreeStudy:!1})},n.closePopupWish=function(){var e=Object(l.a)(n);e.setState({isshowFollow:!1}),setTimeout((function(){e.toJoinList(e.state.wish.id,e.state.wish.key)}),200)},n.getQRcodeUrl=function(){var e=Object(l.a)(n);g.f.get("".concat(API["base-api"],"/wx/user_temporary_qrcode/").concat(e.props.user.data.uid)).then((function(e){var t=e.data,a=t.errno,s=t.data,c=t.msg;0===a?(n.setState({qrUrl:s.url}),v.a.toDataURL(s.url,(function(e,t){n.setState({followBarcode:t})}))):r.a.info(c,2)}))},n.addWishList=function(e,t){var a=Object(l.a)(n),s=!n.props.user.hasError;a.setState({wish:{id:e,key:t}}),s?a.isFollow(e,t):a.toLogin()},n.isFollow=function(e,t){var a=Object(l.a)(n);g.f.get("".concat(API.home,"/sys/user/isFollowWeChat")).then((function(n){var s=n.data,c=s.code,o=s.data,i=s.msg;200===c?(a.setState({isshowFollow:!o.is_follow}),a.state.isshowFollow?a.getQRcodeUrl():a.toJoinList(e,t)):r.a.info(i,2)}))},n.toJoinList=function(e,t){var a=Object(l.a)(n);g.f.post("".concat(API.home,"/activity/join_list"),{course_id:e}).then((function(e){var n=e.data,s=n.code,c=n.msg;200===s?(r.a.success("\u5df2\u6210\u529f\u52a0\u5165\u5fc3\u613f\u5355",3),a.getLength(),"1"===t&&a.fetchAICourse("one",a.state.basic.addshowMore),"2"===t&&a.fetchAICourse("two",a.state.advanced.addshowMore),"3"===t&&a.fetchAICourse("three",a.state.higher.addshowMore),"4"===t&&a.fetchAICourse("four",a.state.expand.addshowMore),"group"===t&&a.fetchGroupCourse()):r.a.info(c,2)}))},n.saveImage=function(){var e=Object(g.c)("version");e="string"===typeof e?e.replace(".","").replace(".","").slice(0,3):"";var t=n.state.qrUrl;e&&parseInt(e)<451?r.a.info("\u5f53\u524d\u4e0d\u652f\u6301\u6b64\u529f\u80fd\uff0c\u5347\u7ea7\u5230\u6700\u65b0\u7248\u672capp\u53ef\u4ee5\u70b9\u51fb\u4fdd\u5b58\u4e8c\u7ef4\u7801\uff01",3,null,!1):Object(g.a)("generateQRCode",t)},n.saveImage2=function(){var e=Object(g.c)("version");(e="string"===typeof e?e.replace(".","").replace(".","").slice(0,3):"")&&parseInt(e)<451?r.a.info("\u5f53\u524d\u4e0d\u652f\u6301\u6b64\u529f\u80fd\uff0c\u5347\u7ea7\u5230\u6700\u65b0\u7248\u672capp\u53ef\u4ee5\u70b9\u51fb\u4fdd\u5b58\u4e8c\u7ef4\u7801\uff01",3,null,!1):Object(g.a)("saveImage","https://cdn.julyedu.com/2018christyear/h5/qrcode.jpg")},n.getTeamInfo=function(){g.f.get("".concat(API.home,"/sys/treasure/teamInfo")).then((function(e){var t=e.data,a=t.code,s=t.data,c=t.msg;if(200===a){var o=s.info,i=s.removable_data;n.setState({removable:o.removable,currentId:o.removable>0?i[0].id:null})}else r.a.info(c)}))},n.toBoxList=function(){var e=!n.props.user.hasError,t=n.state.currentId,a="";t&&(a="?id=".concat(t)),e?Object(g.c)("version")?n.props.history.push("/year/yearTreasure".concat(a,"?version=").concat(Object(g.c)("version"))):n.props.history.push("/year/yearTreasure".concat(a)):n.toLogin()},n.toYearWish=function(){!n.props.user.hasError?Object(g.c)("version")?n.props.history.push("/year/yearWish?version=".concat(Object(g.c)("version"))):n.props.history.push("/year/yearWish"):n.toLogin()},n.toInviteFriends=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=n.props.history;if(Object(g.c)("version")){var s={title:"\u3010\u4ec5\u5269".concat(t.number,"\u4e2a\u540d\u989d\u3011\u6211").concat(t.price,"\u5143\u62fc\u4e86\u300a").concat(t.course_title,"\u300b"),desc:t.course_title,link:"".concat(API.m,"/togroup?id=").concat(e,"&is_originator=1"),imgUrl:t.image_name};Object(g.a)("toShare",s)}else a.push("/togroup?id=".concat(e))},n.isCountDown=function(e,t){return e?t:""},n.formatTitleAndKey=function(e){var t=null;switch(e){case 1:t={title:"\u57fa\u7840",key:"basic"};break;case 2:t={title:"\u8fdb\u9636",key:"advanced"};break;case 3:t={title:"\u9ad8\u9636",key:"higher"};break;case 4:t={title:"\u6269\u5c55",key:"expand"};break;default:t=null}return t},n.formatCourseData=function(e){var t=n.state,a=t.basic,s=t.advanced,r=t.higher,c=t.expand,o=null;switch(e){case 1:o=a;break;case 2:o=s;break;case 3:o=r;break;case 4:o=c;break;default:o=null}return o},n.toCart=function(e){var t=n.props.history;g.f.post("".concat(API.home,"/m/cart/add"),{course_id:e}).then((function(e){var a=e.data,s=a.code,c=a.msg;200===s||15001===s?Object(g.c)("version")?Object(g.a)("toShoppingCart"):t.push("/shopcart"):4030===s||4040===s?n.toLogin():r.a.info(c,2)}))},n.toContinueBargain=function(e,t,a,s){var r=n.props.history;if(Object(g.c)("version")){var c={title:"\u6211\u53d1\u73b0\u4e00\u95e8\u597d\u8bfe\uff0c\u5feb\u6765\u5e2e\u6211\u780d\u4ef7\u5427\uff01",desc:"\u6211\u5df2\u7ecf\u780d\u4e86".concat(t,"\u5143\uff0c\u770b\u770b\u4f60\u80fd\u780d\u591a\u5c11"),link:"".concat(API.m,"/bargain-middle-page?id=").concat(e,"&bargaincode=").concat(a,"&is_originator=1"),imgUrl:s};Object(g.a)("toShare",c)}else r.push("/bargain-middle-page?id=".concat(e,"&bargaincode=").concat(a,"&is_originator=1"))},n.bargainToOrder=function(e){var t=n.props,a=t.history;t.user.hasError?n.toLogin():Object(g.c)("version")?Object(g.a)("toPay",e):g.f.get("".concat(API["base-api"],"/m/cart/addtopreorder/[").concat(e,"]")).then((function(t){var n=t.data,s=n.errno,c=n.msg;0===s?a.push("/order?id=[".concat(e,"]"),{bargain:1}):r.a.info(c,2)}))},n.state={tofreeStudy:!1,basic:{course:[],courseList:[],isMore:!1,addshowMore:!1},advanced:{course:[],courseList:[],isMore:!1,addshowMore:!1},higher:{course:[],courseList:[],isMore:!1,addshowMore:!1},expand:{course:[],courseList:[],isMore:!1,addshowMore:!1},bigcourse:{course:[],courseList:[],isMore:!1},freecourse:{course:[],courseList:[],isMore:!1},groupcourse:{course:[],courseList:[],isMore:!1},isshowFollow:!1,wish:{id:"",key:""},followBarcode:"",qrUrl:"",sum:"",removable:"",currentId:""},n}return Object(i.a)(a,[{key:"componentDidMount",value:function(){this.getTeamInfo(),this.getLength(),this.fetchBigCourse(),this.fetchGroupCourse(),this.fetchAICourse("one",!1),this.fetchAICourse("two",!1),this.fetchAICourse("three",!1),this.fetchAICourse("four",!1)}},{key:"shouldComponentUpdate",value:function(e,t,a){return this.props.isAppUpdate===e.isAppUpdate||(this.getTeamInfo(),this.getLength(),this.fetchBigCourse(),this.fetchGroupCourse(),this.fetchAICourse("one"),this.fetchAICourse("two"),this.fetchAICourse("three"),this.fetchAICourse("four"),!1)}},{key:"render",value:function(){var e=this,t=this.state,a=t.bigcourse,n=t.groupcourse,s=t.basic,r=t.advanced,c=t.higher,o=t.expand,i=t.removable,l=this.props.stage;return d.a.createElement("div",{className:"year-index-course"},d.a.createElement("div",{className:"nav-right-wish nav-right"},d.a.createElement("span",{onClick:this.toBoxList,className:"nav-right__link"},"\u672a\u5f00\u5b9d\u7bb1",i>0&&d.a.createElement("i",{className:"nav-right__number"},i))),d.a.createElement(h.a,{title:"\u9a70\u63f4\u6b66\u6c49 \u6ce8\u518c\u5373\u9001",id:"year-wuhan"},d.a.createElement("div",{className:"course-box course-conter"},d.a.createElement("div",{className:"course-item"},d.a.createElement("span",null,"\u6ce8\u518c\u5373\u9001"),d.a.createElement("a",{href:"/detail?id=224"},d.a.createElement("img",{src:"http://img-public.julyedu.com/Public/Image/75d1c3cef5.png",alt:""}))),d.a.createElement("div",{className:"course-item"},d.a.createElement("span",null,"\u6ce8\u518c\u5373\u9001"),d.a.createElement("a",{href:"/detail?id=206"},d.a.createElement("img",{src:"https://img-public.julyedu.com/Public/Image/b001fac23f.png",alt:""}))),d.a.createElement("div",{className:"course-item"},d.a.createElement("span",null,"\u6ce8\u518c\u5373\u9001"),d.a.createElement("a",{href:"/detail?id=230"},d.a.createElement("img",{src:"https://img-public.julyedu.com/Public/Image/d0fb0a479b.png",alt:""}))))),d.a.createElement(h.a,{title:"\u91cd\u78c5\u597d\u8bfe\u9650\u65f6\u514d\u8d39\u8bd5\u542c",id:"year-course"},a.course&&a.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"bigcourse course-box"},a.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},1===Number(t.is_vip)&&d.a.createElement("a",{className:"btn big-course",onClick:function(){return e.toQQque()}},"\u9996\u8d2d\xa599\u8d77"),0==t.is_vip&&d.a.createElement(d.a.Fragment,null,1==t.is_buy&&d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-study"},"\u5f00\u59cb\u5b66\u4e60"),0==t.is_buy&&d.a.createElement("a",{onClick:function(){return e.toQQque()},className:"btn big-course"},1==t.is_audition?"\u514d\u8d39\u8bd5\u542c":"\u62a2\u56e2\u62a5\u540d\u989d"))))}))))),1!==Number(l)&&d.a.createElement(d.a.Fragment,null,d.a.createElement(h.a,{title:"\u7cbe\u54c1\u597d\u8bfe1\u5206\u79d2",id:"year-group"},n.course&&n.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box","data-stage":"2"},n.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,time:e.isCountDown(1===t.is_assemble,t.add_time),toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},2==t.is_assemble&&d.a.createElement(d.a.Fragment,null,d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("div",{className:"status"},d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-group","data-status":"study"},"\u5f00\u59cb\u5b66\u4e60"))),2!=t.is_assemble&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},d.a.createElement("span",{className:"tag","data-color":"green"},"\u62fc\u56e2\u4ef7")),d.a.createElement("div",{className:"price price-group"},d.a.createElement("span",{className:"price-label"},"\xa5"),d.a.createElement("span",{className:"new-price"},"0.01"),d.a.createElement("span",{className:"old-price"},d.a.createElement("s",null,"\xa5",t.price1))),0==t.is_assemble&&d.a.createElement("div",{className:"progree-and-sale"},d.a.createElement("div",{className:"progress"},d.a.createElement("i",{className:"progress_bar",style:{width:"".concat(t.progress,"%")}})),d.a.createElement("p",{className:"sale-sum"},Number(t.sum<=285)?"\u5df2\u62a2".concat(t.sum,"\u4e2a"):"\u5373\u5c06\u552e\u7f44")),d.a.createElement("div",{className:"status"},0==t.is_assemble&&d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-group"},"\u9a6c\u4e0a\u62a2>>"),1==t.is_assemble&&d.a.createElement("a",{onClick:function(){return e.toInviteFriends(t.order_id,{number:t.number,course_title:t.course_title,image_name:t.image_name,price:.01})},className:"status-btn to-group","data-status":"done"},"\u5df2\u53c2\u56e2\uff0c\u9080\u8bf7\u597d\u53cb\u53c2\u56e2")))))}))),n.courseList&&n.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore("groupcourse")}},n.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77"))),d.a.createElement(h.a,{title:"\u201c\u85aa\u201d\u5e74\u4ef7\u5230\uff0c\u7b49\u4f60\u6284\u5e95\uff01",id:"year-discount"},[1,2,3,4].map((function(t){var a=e.formatTitleAndKey(t),n=e.formatCourseData(t);return d.a.createElement(d.a.Fragment,{key:t},d.a.createElement("h4",{className:"ai-course__subtitle"},a.title),n.course&&n.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box"},n.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,time:e.isCountDown(2===t.type,t.end_time),toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},(4===t.type||8===t.type)&&d.a.createElement("div",{className:"bargain-price"},"\u5df2\u780d",t.already_bargain,"\u5143"),0===t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},d.a.createElement("span",{className:"tag","data-color":"green"},"\u6d3b\u52a8\u4ef7")),d.a.createElement("div",{className:"price price-group"},d.a.createElement("span",{className:"price-label"},"\xa5"),d.a.createElement("span",{className:"new-price"},t.original_price),d.a.createElement("span",{className:"old-price"},d.a.createElement("s",null,"\xa5",t.price1)))),(1===t.type||2===t.type)&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},d.a.createElement("span",{className:"tag","data-color":"green"},"\u62fc\u56e2\u4ef7")),d.a.createElement("div",{className:"price price-group"},d.a.createElement("span",{className:"price-label"},"\xa5"),d.a.createElement("span",{className:"new-price"},t.pdd_price),d.a.createElement("span",{className:"old-price"},d.a.createElement("s",null,"\xa5",t.original_price)))),(3===t.type||4===t.type||8===t.type)&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},d.a.createElement("span",{className:"tag","data-color":"green"},"\u597d\u53cb\u5e2e\u5e2e\u780d")),d.a.createElement("div",{className:"price price-group"},d.a.createElement("span",{className:"price-label"},"\u5230\u624b\u6700\u4f4e\uff1a\xa5"),d.a.createElement("span",{className:"new-price"},t.low_prize),d.a.createElement("span",{className:"old-price"},d.a.createElement("s",null,"\xa5",t.original_price)))),6===t.type&&d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("div",{className:"status","data-layout":4===t.type?"row":""},0===t.type&&d.a.createElement("a",{onClick:function(){return e.toCart(t.course_id)},className:"status-btn to-group"},"\u7acb\u5373\u8d2d\u4e70"),1===t.type&&d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-group"},"\u7acb\u5373\u53c2\u4e0e\u62fc\u56e2"),2===t.type&&d.a.createElement("a",{onClick:function(){return e.toInviteFriends(t.order_id,{number:t.number,course_title:t.course_title,image_name:t.image_name,price:t.pdd_price})},className:"status-btn to-group","data-status":"done"},"\u5df2\u53c2\u56e2\uff0c\u9080\u8bf7\u597d\u53cb\u53c2\u56e2"),3===t.type&&d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-group"},"\u6211\u8981\u780d\u4ef7"),4===t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("a",{onClick:function(){return e.toContinueBargain(t.course_id,t.already_bargain,t.bargain_code,t.image_name)},className:"status-btn to-group"},"\u7ee7\u7eed\u780d\u4ef7"),d.a.createElement("a",{onClick:function(){return e.bargainToOrder(t.course_id)},className:"status-btn to-group"},"\u652f\u4ed8",t.actual_payment,"\u5143")),8===t.type&&d.a.createElement("a",{onClick:function(){return e.bargainToOrder(t.course_id)},className:"status-btn to-group"},"\u652f\u4ed8",t.actual_payment,"\u5143"),6===t.type&&d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-group","data-status":"study"},"\u5f00\u59cb\u5b66\u4e60"))))}))),n.courseList&&n.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore(a.key)}},n.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77")))})))),1===Number(l)&&d.a.createElement(d.a.Fragment,null,d.a.createElement(h.a,{title:"\u7cbe\u54c1\u597d\u8bfe1\u5206\u5f00\u62a2",id:"year-group"},n.course&&n.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box"},n.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,toCourse:e.toCourse},d.a.createElement("div",{className:"group-num"},"\u9650\u91cf300\u4e2a"),d.a.createElement("div",{className:"coupon-course__footer"},1==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-study"},"\u5f00\u59cb\u5b66\u4e60")),0==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},d.a.createElement("span",{className:"tag"},"\u62fc\u56e2\u4ef7"),d.a.createElement("span",{className:"time"},"12\u670823\u65e5\u5f00\u56e2")),d.a.createElement("div",{className:"price"},"\xa5",d.a.createElement("span",{className:"new-price"},"0.01"),d.a.createElement("span",{className:"old-price"},"\u73b0\u4ef7\uff1a",d.a.createElement("s",null,"\xa5",t.price1))),d.a.createElement("div",{className:"status"},d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-buy"},"\u76f4\u63a5\u8d2d\u4e70"),1==t.is_join&&d.a.createElement("a",{className:"status-btn add-wish"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/PC/add-success.png",alt:""}),"\u5df2\u52a0\u5fc3\u613f\u5355"),0==t.is_join&&d.a.createElement("a",{onClick:function(){return e.addWishList(t.course_id,"group")},className:"status-btn add-wish-success"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/like_icon.png",alt:""}),"\u52a0\u5165\u5fc3\u613f\u5355")))))}))),n.courseList&&n.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore("groupcourse")}},n.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77"))),d.a.createElement(h.a,{title:"\u597d\u8bfe\u4ef7\u5230\uff0c\u7b49\u4f60\u6284\u5e95",id:"year-discount"},d.a.createElement("h4",{className:"ai-course__subtitle"},"\u57fa\u7840"),s.course&&s.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box"},s.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},1==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-study"},"\u5f00\u59cb\u5b66\u4e60")),0==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},0==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u6d3b\u52a8\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u59cb")),1==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u62fc\u56e2\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u56e2")),2==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u597d\u53cb\u5e2e\u5e2e\u780d"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u780d"))),d.a.createElement("div",{className:"price"},2==t.type?"\u5230\u624b\u6700\u4f4e:\xa5":"\xa5",d.a.createElement("span",{className:"new-price"},t.price2),d.a.createElement("span",{className:"old-price"},2==t.type?"":"\u73b0\u4ef7\uff1a",d.a.createElement("s",null,"\xa5",t.price1))),d.a.createElement("div",{className:"status"},d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-buy"},"\u76f4\u63a5\u8d2d\u4e70"),1==t.is_join&&d.a.createElement("a",{className:"status-btn add-wish"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/PC/add-success.png",alt:""}),"\u5df2\u52a0\u5fc3\u613f\u5355"),0==t.is_join&&d.a.createElement("a",{onClick:function(){return e.addWishList(t.course_id,"1")},className:"status-btn add-wish-success"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/like_icon.png",alt:""}),"\u52a0\u5165\u5fc3\u613f\u5355")))))}))),s.courseList&&s.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore("basic")}},s.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77")),d.a.createElement("h4",{className:"ai-course__subtitle"},"\u8fdb\u9636"),r.course&&r.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box"},r.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},1==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-study"},"\u5f00\u59cb\u5b66\u4e60")),0==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},0==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u6d3b\u52a8\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u59cb")),1==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u62fc\u56e2\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u56e2")),2==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u597d\u53cb\u5e2e\u5e2e\u780d"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u780d"))),d.a.createElement("div",{className:"price"},2==t.type?"\u5230\u624b\u6700\u4f4e:\xa5":"\xa5",d.a.createElement("span",{className:"new-price"},t.price2),d.a.createElement("span",{className:"old-price"},2==t.type?"":"\u73b0\u4ef7\uff1a",d.a.createElement("s",null,"\xa5",t.price1))),d.a.createElement("div",{className:"status"},d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-buy"},"\u76f4\u63a5\u8d2d\u4e70"),1==t.is_join&&d.a.createElement("a",{className:"status-btn add-wish"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/PC/add-success.png",alt:""}),"\u5df2\u52a0\u5fc3\u613f\u5355"),0==t.is_join&&d.a.createElement("a",{onClick:function(){return e.addWishList(t.course_id,"2")},className:"status-btn add-wish-success"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/like_icon.png",alt:""}),"\u52a0\u5165\u5fc3\u613f\u5355")))))}))),r.courseList&&r.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore("advanced")}},r.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77")),d.a.createElement("h4",{className:"ai-course__subtitle"},"\u9ad8\u9636"),c.course&&c.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box"},c.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},1==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-study"},"\u5f00\u59cb\u5b66\u4e60")),0==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},0==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u6d3b\u52a8\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u59cb")),1==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u62fc\u56e2\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u56e2")),2==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u597d\u53cb\u5e2e\u5e2e\u780d"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u780d"))),d.a.createElement("div",{className:"price"},2==t.type?"\u5230\u624b\u6700\u4f4e:\xa5":"\xa5",d.a.createElement("span",{className:"new-price"},t.price2),d.a.createElement("span",{className:"old-price"},2==t.type?"":"\u73b0\u4ef7\uff1a",d.a.createElement("s",null,"\xa5",t.price1))),d.a.createElement("div",{className:"status"},d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-buy"},"\u76f4\u63a5\u8d2d\u4e70"),1==t.is_join&&d.a.createElement("a",{className:"status-btn add-wish"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/PC/add-success.png",alt:""}),"\u5df2\u52a0\u5fc3\u613f\u5355"),0==t.is_join&&d.a.createElement("a",{onClick:function(){return e.addWishList(t.course_id,"3")},className:"status-btn add-wish-success"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/like_icon.png",alt:""}),"\u52a0\u5165\u5fc3\u613f\u5355")))))}))),c.courseList&&c.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore("higher")}},c.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77")),d.a.createElement("h4",{className:"ai-course__subtitle"},"\u6269\u5c55"),o.course&&o.course.length>0&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"groupcourse course-box"},o.course.map((function(t){return d.a.createElement(E.a,{image:t.image_name,key:t.course_id,id:t.course_id,toCourse:e.toCourse},d.a.createElement("div",{className:"coupon-course__footer"},1==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("p",{className:"course-title text-overflow-1"},t.course_title),d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"btn to-study"},"\u5f00\u59cb\u5b66\u4e60")),0==t.is_buy&&d.a.createElement(d.a.Fragment,null,d.a.createElement("div",{className:"type"},0==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u6d3b\u52a8\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u59cb")),1==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u62fc\u56e2\u4ef7"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u56e2")),2==t.type&&d.a.createElement(d.a.Fragment,null,d.a.createElement("span",{className:"tag"},"\u597d\u53cb\u5e2e\u5e2e\u780d"),d.a.createElement("span",{className:"time"},"12.23\u5f00\u780d"))),d.a.createElement("div",{className:"price"},2==t.type?"\u5230\u624b\u6700\u4f4e:\xa5":"\xa5",d.a.createElement("span",{className:"new-price"},t.price2),d.a.createElement("span",{className:"old-price"},2==t.type?"":"\u73b0\u4ef7\uff1a",d.a.createElement("s",null,"\xa5",t.price1))),d.a.createElement("div",{className:"status"},d.a.createElement("a",{onClick:function(){return e.toCourse(t.course_id)},className:"status-btn to-buy"},"\u76f4\u63a5\u8d2d\u4e70"),1==t.is_join&&d.a.createElement("a",{className:"status-btn add-wish"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/PC/add-success.png",alt:""}),"\u5df2\u52a0\u5fc3\u613f\u5355"),0==t.is_join&&d.a.createElement("a",{onClick:function(){return e.addWishList(t.course_id,"4")},className:"status-btn add-wish-success"},d.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/like_icon.png",alt:""}),"\u52a0\u5165\u5fc3\u613f\u5355")))))}))),o.courseList&&o.courseList.length>4&&d.a.createElement("button",{className:"more-button",onClick:function(){return e.handleToMore("expand")}},o.isMore?"\u67e5\u770b\u66f4\u591a":"\u6536\u8d77")))),this.state.tofreeStudy&&d.a.createElement(b.a,{top:100,closePopup:this.closePopup,mark:!1},d.a.createElement("div",{className:"sub__code_container"},d.a.createElement("p",{className:"sub__title"},"\u63d0\u9192\u670d\u52a1"),d.a.createElement("p",{className:"sub__tip"},"\u8fdb\u5165\u670d\u52a1\u53f7\u56de\u590d",d.a.createElement("i",null,"77"),"\u514d\u8d39\u9886\u53d6\u8bfe\u7a0b"),d.a.createElement("img",{className:"sub__qr_code",id:"live-qr-code",src:"//cdn.julyedu.com/2018christyear/h5/qrcode.jpg",alt:""}),g.b.isAndroidApp?d.a.createElement("button",{className:"save-image",onClick:this.saveImage2},"\u4fdd\u5b58\u4e8c\u7ef4\u7801"):d.a.createElement("p",{className:"sub__tip"},"\u957f\u6309\u8bc6\u522b/\u626b\u7801 \u5173\u6ce8\u3010\u4e03\u6708\u5728\u7ebf\u3011\u670d\u52a1\u53f7"))),this.state.isshowFollow&&d.a.createElement(b.a,{top:100,closePopup:this.closePopupWish,mark:!1},d.a.createElement("div",{className:"sub__code_container"},d.a.createElement("p",{className:"sub__title"},"\u63d0\u9192\u670d\u52a1"),d.a.createElement("p",{className:"sub__tip"},"\u8bfe\u7a0b\u5f00\u552e\u7acb\u5373\u63d0\u9192\uff0c\u4e0d\u9519\u8fc7\u4efb\u4f55\u4f18\u60e0\u54e6\uff01"),d.a.createElement("img",{className:"sub__qr_code",id:"live-qr-code",src:this.state.followBarcode,alt:""}),g.b.isAndroidApp?d.a.createElement("button",{className:"save-image",onClick:this.saveImage},"\u4fdd\u5b58\u4e8c\u7ef4\u7801"):d.a.createElement("p",{className:"sub__tip"},"\u957f\u6309\u8bc6\u522b/\u626b\u7801 \u5173\u6ce8\u3010\u4e03\u6708\u5728\u7ebf\u3011\u670d\u52a1\u53f7"))))}}]),a}(p.Component))||n;t.a=Object(f.g)(N)}}]);
//# sourceMappingURL=2.a170db71.chunk.js.map //# sourceMappingURL=2.a170db71.chunk.js.map
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
(this["webpackJsonpmr-julyedu"]=this["webpackJsonpmr-julyedu"]||[]).push([[30],{1117:function(e,t,a){},1179:function(e,t,a){"use strict";a.r(t);a(36);var n=a(10),c=a.n(n),s=a(4),i=a(3),r=a(5),l=a(6),o=a(7),m=a(0),d=a.n(m),u=(a(1117),a(15)),p=a(1),g=a(20),y=a(60),v=a(37),f=a(163),h=1,E=2,_=function(e){Object(l.a)(a,e);var t=Object(o.a)(a);function a(){var e;Object(i.a)(this,a);for(var n=arguments.length,r=new Array(n),l=0;l<n;l++)r[l]=arguments[l];return(e=t.call.apply(t,[this].concat(r))).state={showAnalyzing:!1,systemAvatar:"https://img-public.julyedu.com/Public/Image/home/avatar_20191104.png",options:{data:[],messageId:0},next:{oid:0,rid:0}},e.handleSelect=function(t){e.props.addMessage({type:E,content:t.describe,id:t.id}),e.setState((function(e){return{options:{data:[],messageId:0},next:Object(s.a)(Object(s.a)({},e.next),{},{oid:t.id})}}),(function(){e.getMessage()}))},e.getMessage=function(){var t=e.state.next,a=t.oid,n=t.rid;p.f.get("".concat(API.home,"/sys/icc/communicate/").concat(a,"/").concat(n)).then((function(t){var a=t.data,n=a.data,i=a.code,r=a.msg;if(200===i)if(1===n.answer_type)e.setState({showAnalyzing:!0},(function(){setTimeout((function(){e.setState({showAnalyzing:!1}),e.props.addResult(Object(s.a)({},n))}),500*Math.random()+1e3)}));else{var l={type:h,content:n.contents.find((function(e){return e.is_question}))},o=n.contents.filter((function(e){return!e.is_question}));e.props.addMessage(l),e.setState({options:{messageId:l.content.id,data:o},next:{rid:n.rid}})}else c.a.fail(r)}))},e.consult=function(t){t.preventDefault();var a=t.target;p.f.post("".concat(API.home,"/sys/icc/consult"),{rid:e.props.intelligentRecommend.result.rid}).finally((function(){window.location.href=a.getAttribute("href")}))},e.displayPrice=function(e){var t=e.toString().split(".");return 0===parseInt(t[1])?t[0]:e},e.goBack=function(){var t=e.props.location.state;p.b.isWeixin&&Object(p.c)("code")&&Object(p.c)("state")&&window.history.go(-2),t.records&&t.records.length>1?window.history.go(-1):t.from&&t.from.pathname?window.location.replace("".concat(t.from.pathname).concat(t.from.search)):window.location.href=window.location.origin},e}return Object(r.a)(a,[{key:"componentDidMount",value:function(){var e=this.props,t=e.intelligentRecommend,a=e.reselect;Object(v.isEmpty)(t.result)&&(a(),this.getMessage())}},{key:"render",value:function(){var e=this,t=this.state,a=t.showAnalyzing,n=t.systemAvatar,c=t.options,s=this.props,i=s.user,r=s.intelligentRecommend,l=r.result,o=r.processing,m=s.reselect,p=l.contents;return d.a.createElement("div",{id:"intelligent-recommend"},d.a.createElement("div",{className:"head"},d.a.createElement("div",null,d.a.createElement("div",{className:"go-back"},d.a.createElement("i",{className:"iconfont iconiconfront-68",onClick:this.goBack})),d.a.createElement("div",{className:"title"},"\u4e03\u6708\u5728\u7ebf\u667a\u80fd\u9009\u8bfe")),d.a.createElement("button",{onClick:function(){e.setState({next:{oid:0,rid:0},options:{messageId:0,data:[]}},(function(){m(),e.getMessage()}))}},"\u91cd\u65b0\u9009\u8bfe")),d.a.createElement("div",{className:"dialog-box"},!!o.length&&o.map((function(t,a){switch(t.type){case h:return d.a.createElement(d.a.Fragment,{key:a},d.a.createElement(b,{text:t.content.describe,identity:"system",avatar:n}),c.messageId===t.content.id&&d.a.createElement(N,{options:c.data,handleSelect:e.handleSelect}));case E:return d.a.createElement(b,{text:t.content,identity:"user",avatar:i.data.avatar,key:a+2})}})),a&&d.a.createElement("div",{className:"analyzing"},"\u52aa\u529b\u5206\u6790\u4e2d...")),!Object(v.isEmpty)(p)&&d.a.createElement("div",{className:"result"},d.a.createElement("div",{className:"title"},"\u6839\u636e\u60a8\u76ee\u524d\u7684\u60c5\u51b5\uff0c\u63a8\u8350\u7ed3\u679c\u5982\u4e0b"),d.a.createElement("div",{className:"obtained"},d.a.createElement("div",{className:"subtitle",dangerouslySetInnerHTML:{__html:p.skill_title}}),d.a.createElement("div",{className:"skill",dangerouslySetInnerHTML:{__html:p.skill_desc}})),d.a.createElement("div",{className:"obtained"},d.a.createElement("div",{className:"subtitle",dangerouslySetInnerHTML:{__html:p.project_title}}),d.a.createElement("div",{className:"skill project",dangerouslySetInnerHTML:{__html:p.project_desc}})),d.a.createElement("div",{className:"salary-section"},d.a.createElement("div",{className:"subtitle",dangerouslySetInnerHTML:{__html:p.salary_title}}),d.a.createElement("div",{className:"salary",dangerouslySetInnerHTML:{__html:p.salary_desc}})),d.a.createElement("div",{className:"recommends"},d.a.createElement("div",null,"\u60f3\u83b7\u5f97\u4ee5\u4e0a\u6280\u80fd\uff0c\u5411\u60a8\u63a8\u8350\uff1a"),d.a.createElement("ul",{className:"courses"},!!p.courses.length&&p.courses.map((function(t){return d.a.createElement("li",{className:"course",key:t.course_id,onClick:function(a){"a"!==a.target.nodeName.toLowerCase()&&(t.course_id?e.props.history.push("/detail?id=".concat(t.course_id)):e.props.history.push("/play?id=".concat(t.v_course_id)))}},d.a.createElement("div",{className:"cover"},d.a.createElement("img",{src:t.img_url,alt:""})),d.a.createElement("div",{className:"info"},d.a.createElement("div",{className:"title"},t.recmd_title),d.a.createElement("div",{className:"des"},t.recmd_desc),d.a.createElement("div",{className:"bar"},1===t.c_type&&d.a.createElement(d.a.Fragment,{key:t.course_id},d.a.createElement("div",{className:"prices"},d.a.createElement("span",{className:"price"},"\uffe5",e.displayPrice(t.price_sale)),d.a.createElement("span",{className:"old-price"},"\uffe5",e.displayPrice(t.price_original))),d.a.createElement(u.b,{className:"register",to:"/detail?id=".concat(t.course_id)},t.second_btn)),2===t.c_type&&d.a.createElement(d.a.Fragment,{key:t.course_id},d.a.createElement("a",{href:"http://q.url.cn/s/Vbkup6m?_type=wpa",className:"contact",onClick:e.consult},t.consult),d.a.createElement(u.b,{className:"register",to:"/detail?id=".concat(t.course_id)},t.second_btn)),0===t.c_type&&d.a.createElement(u.b,{className:"study",to:"/play?id=".concat(t.v_course_id)},t.second_btn))))}))))))}}]),a}(m.Component);function b(e){var t=e.text,a=e.avatar,n=e.identity;return d.a.createElement("div",{className:"message clearfix ".concat(n)},d.a.createElement("div",{className:"avatar"},d.a.createElement("img",{src:a,alt:""})),d.a.createElement("div",{className:"text"},t))}function N(e){var t=e.options,a=e.handleSelect;return d.a.createElement("ul",{className:"options"},!!t.length&&t.map((function(e){return d.a.createElement("li",{onClick:function(){return a(e)},key:e.id},d.a.createElement("button",null,e.describe))})))}t.default=Object(g.b)((function(e){return{user:e.user,intelligentRecommend:e.intelligentRecommend}}),{addMessage:f.a,addResult:f.b,reselect:f.d})(Object(y.a)(_))}}]); (this["webpackJsonpmr-julyedu"]=this["webpackJsonpmr-julyedu"]||[]).push([[30],{1117:function(e,t,a){},1179:function(e,t,a){"use strict";a.r(t);a(36);var n=a(10),c=a.n(n),s=a(4),i=a(3),r=a(5),l=a(6),o=a(7),m=a(0),d=a.n(m),u=(a(1117),a(15)),p=a(1),g=a(20),y=a(60),v=a(37),f=a(163),h=1,E=2,_=function(e){Object(l.a)(a,e);var t=Object(o.a)(a);function a(){var e;Object(i.a)(this,a);for(var n=arguments.length,r=new Array(n),l=0;l<n;l++)r[l]=arguments[l];return(e=t.call.apply(t,[this].concat(r))).state={showAnalyzing:!1,systemAvatar:"https://img-public.julyedu.com/Public/Image/home/avatar_20191104.png",options:{data:[],messageId:0},next:{oid:0,rid:0}},e.handleSelect=function(t){e.props.addMessage({type:E,content:t.describe,id:t.id}),e.setState((function(e){return{options:{data:[],messageId:0},next:Object(s.a)(Object(s.a)({},e.next),{},{oid:t.id})}}),(function(){e.getMessage()}))},e.getMessage=function(){var t=e.state.next,a=t.oid,n=t.rid;p.f.get("".concat(API.home,"/sys/icc/communicate/").concat(a,"/").concat(n)).then((function(t){var a=t.data,n=a.data,i=a.code,r=a.msg;if(200===i)if(1===n.answer_type)e.setState({showAnalyzing:!0},(function(){setTimeout((function(){e.setState({showAnalyzing:!1}),e.props.addResult(Object(s.a)({},n))}),500*Math.random()+1e3)}));else{var l={type:h,content:n.contents.find((function(e){return e.is_question}))},o=n.contents.filter((function(e){return!e.is_question}));e.props.addMessage(l),e.setState({options:{messageId:l.content.id,data:o},next:{rid:n.rid}})}else c.a.fail(r)}))},e.consult=function(t){t.preventDefault();var a=t.target;p.f.post("".concat(API.home,"/sys/icc/consult"),{rid:e.props.intelligentRecommend.result.rid}).finally((function(){window.location.href=a.getAttribute("href")}))},e.displayPrice=function(e){var t=e.toString().split(".");return 0===parseInt(t[1])?t[0]:e},e.goBack=function(){var t=e.props.location.state;p.b.isWeixin&&Object(p.c)("code")&&Object(p.c)("state")&&window.history.go(-2),t.records&&t.records.length>1?window.history.go(-1):t.from&&t.from.pathname?window.location.replace("".concat(t.from.pathname).concat(t.from.search)):window.location.href=window.location.origin},e}return Object(r.a)(a,[{key:"componentDidMount",value:function(){var e=this.props,t=e.intelligentRecommend,a=e.reselect;Object(v.isEmpty)(t.result)&&(a(),this.getMessage())}},{key:"render",value:function(){var e=this,t=this.state,a=t.showAnalyzing,n=t.systemAvatar,c=t.options,s=this.props,i=s.user,r=s.intelligentRecommend,l=r.result,o=r.processing,m=s.reselect,p=l.contents;return d.a.createElement("div",{id:"intelligent-recommend"},d.a.createElement("div",{className:"head"},d.a.createElement("div",null,d.a.createElement("div",{className:"go-back"},d.a.createElement("i",{className:"iconfont iconiconfront-68",onClick:this.goBack})),d.a.createElement("div",{className:"title"},"\u4e03\u6708\u5728\u7ebf\u667a\u80fd\u9009\u8bfe")),d.a.createElement("button",{onClick:function(){e.setState({next:{oid:0,rid:0},options:{messageId:0,data:[]}},(function(){m(),e.getMessage()}))}},"\u91cd\u65b0\u9009\u8bfe")),d.a.createElement("div",{className:"dialog-box"},!!o.length&&o.map((function(t,a){switch(t.type){case h:return d.a.createElement(d.a.Fragment,{key:a},d.a.createElement(b,{text:t.content.describe,identity:"system",avatar:n}),c.messageId===t.content.id&&d.a.createElement(N,{options:c.data,handleSelect:e.handleSelect}));case E:return d.a.createElement(b,{text:t.content,identity:"user",avatar:i.data.avatar,key:a+2})}})),a&&d.a.createElement("div",{className:"analyzing"},"\u52aa\u529b\u5206\u6790\u4e2d...")),!Object(v.isEmpty)(p)&&d.a.createElement("div",{className:"result"},d.a.createElement("div",{className:"title"},"\u6839\u636e\u60a8\u76ee\u524d\u7684\u60c5\u51b5\uff0c\u63a8\u8350\u7ed3\u679c\u5982\u4e0b"),d.a.createElement("div",{className:"obtained"},d.a.createElement("div",{className:"subtitle",dangerouslySetInnerHTML:{__html:p.skill_title}}),d.a.createElement("div",{className:"skill",dangerouslySetInnerHTML:{__html:p.skill_desc}})),d.a.createElement("div",{className:"obtained"},d.a.createElement("div",{className:"subtitle",dangerouslySetInnerHTML:{__html:p.project_title}}),d.a.createElement("div",{className:"skill project",dangerouslySetInnerHTML:{__html:p.project_desc}})),d.a.createElement("div",{className:"salary-section"},d.a.createElement("div",{className:"subtitle",dangerouslySetInnerHTML:{__html:p.salary_title}}),d.a.createElement("div",{className:"salary",dangerouslySetInnerHTML:{__html:p.salary_desc}})),d.a.createElement("div",{className:"recommends"},d.a.createElement("div",null,"\u60f3\u83b7\u5f97\u4ee5\u4e0a\u6280\u80fd\uff0c\u5411\u60a8\u63a8\u8350\uff1a"),d.a.createElement("ul",{className:"courses"},!!p.courses.length&&p.courses.map((function(t){return d.a.createElement("li",{className:"course",key:t.course_id,onClick:function(a){"a"!==a.target.nodeName.toLowerCase()&&(t.course_id?e.props.history.push("/detail?id=".concat(t.course_id)):e.props.history.push("/play?id=".concat(t.v_course_id)))}},d.a.createElement("div",{className:"cover"},d.a.createElement("img",{src:t.img_url,alt:""})),d.a.createElement("div",{className:"info"},d.a.createElement("div",{className:"title"},t.recmd_title),d.a.createElement("div",{className:"des"},t.recmd_desc),d.a.createElement("div",{className:"bar"},1===t.c_type&&d.a.createElement(d.a.Fragment,{key:t.course_id},d.a.createElement("div",{className:"prices"},d.a.createElement("span",{className:"price"},"\uffe5",e.displayPrice(t.price_sale)),d.a.createElement("span",{className:"old-price"},"\uffe5",e.displayPrice(t.price_original))),d.a.createElement(u.b,{className:"register",to:"/detail?id=".concat(t.course_id)},t.second_btn)),2===t.c_type&&d.a.createElement(d.a.Fragment,{key:t.course_id},d.a.createElement("a",{href:"https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372",className:"contact",onClick:e.consult},t.consult),d.a.createElement(u.b,{className:"register",to:"/detail?id=".concat(t.course_id)},t.second_btn)),0===t.c_type&&d.a.createElement(u.b,{className:"study",to:"/play?id=".concat(t.v_course_id)},t.second_btn))))}))))))}}]),a}(m.Component);function b(e){var t=e.text,a=e.avatar,n=e.identity;return d.a.createElement("div",{className:"message clearfix ".concat(n)},d.a.createElement("div",{className:"avatar"},d.a.createElement("img",{src:a,alt:""})),d.a.createElement("div",{className:"text"},t))}function N(e){var t=e.options,a=e.handleSelect;return d.a.createElement("ul",{className:"options"},!!t.length&&t.map((function(e){return d.a.createElement("li",{onClick:function(){return a(e)},key:e.id},d.a.createElement("button",null,e.describe))})))}t.default=Object(g.b)((function(e){return{user:e.user,intelligentRecommend:e.intelligentRecommend}}),{addMessage:f.a,addResult:f.b,reselect:f.d})(Object(y.a)(_))}}]);
//# sourceMappingURL=intelligent-recommend.f7bc22bd.chunk.js.map //# sourceMappingURL=intelligent-recommend.f7bc22bd.chunk.js.map
\ No newline at end of file
{"version":3,"sources":["components/intelligent-recommend/index.js"],"names":["messageType","IntelligentRecommend","state","showAnalyzing","systemAvatar","options","data","messageId","next","oid","rid","handleSelect","item","props","addMessage","type","content","describe","id","setState","getMessage","http","get","API","home","then","res","code","msg","answer_type","setTimeout","addResult","Math","random","message","contents","find","is_question","optionsData","filter","fail","consult","e","preventDefault","target","post","intelligentRecommend","result","finally","window","location","href","getAttribute","displayPrice","price","decimal","toString","split","parseInt","goBack","browser","isWeixin","getParam","history","go","records","length","from","pathname","replace","search","origin","this","reselect","isEmpty","user","processing","recommends","className","onClick","map","index","Fragment","key","Message","text","identity","avatar","Options","dangerouslySetInnerHTML","__html","skill_title","skill_desc","project_title","project_desc","salary_title","salary_desc","courses","course_id","nodeName","toLowerCase","push","v_course_id","src","img_url","alt","recmd_title","recmd_desc","c_type","price_sale","price_original","to","second_btn","Component","connect","WithFullSize"],"mappings":"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","file":"mrstaticjs/intelligent-recommend.f7bc22bd.chunk.js","sourcesContent":["/* eslint-disable default-case */\nimport React, { Component } from \"react\"\nimport \"./index.scss\"\nimport { Link } from \"react-router-dom\"\nimport { browser, getParam, http } from \"src/utils\"\nimport { Toast } from \"antd-mobile\"\nimport { connect } from \"react-redux\"\nimport { WithFullSize } from \"src/HOCs\"\nimport { isEmpty } from \"lodash\"\nimport { addMessage, addResult, reselect } from \"./store\"\n\nconst messageType = {\n SYSTEM_MESSAGE: 1,\n USER_MESSAGE: 2,\n OPTIONS: 3,\n}\n\nclass IntelligentRecommend extends Component {\n state = {\n showAnalyzing: false,\n systemAvatar:\n \"https://img-public.julyedu.com/Public/Image/home/avatar_20191104.png\",\n options: {\n data: [],\n messageId: 0,\n },\n next: {\n oid: 0,\n rid: 0,\n },\n }\n\n componentDidMount() {\n const { intelligentRecommend, reselect } = this.props\n if (isEmpty(intelligentRecommend.result)) {\n reselect()\n this.getMessage()\n }\n }\n\n handleSelect = (item) => {\n this.props.addMessage({\n type: messageType.USER_MESSAGE,\n content: item.describe,\n id: item.id,\n })\n this.setState(\n (state) => ({\n options: { data: [], messageId: 0 },\n next: {\n ...state.next,\n oid: item.id,\n },\n }),\n () => {\n this.getMessage()\n }\n )\n }\n\n getMessage = () => {\n const { oid, rid } = this.state.next\n http.get(`${API.home}/sys/icc/communicate/${oid}/${rid}`).then((res) => {\n const { data, code, msg } = res.data\n if (code === 200) {\n if (data.answer_type === 1) {\n this.setState(\n {\n showAnalyzing: true,\n },\n () => {\n setTimeout(() => {\n this.setState({ showAnalyzing: false })\n this.props.addResult({ ...data })\n }, Math.random() * 500 + 1000)\n }\n )\n } else {\n const message = {\n type: messageType.SYSTEM_MESSAGE,\n content: data.contents.find((item) => item.is_question),\n }\n const optionsData = data.contents.filter((item) => !item.is_question)\n this.props.addMessage(message)\n this.setState({\n options: {\n messageId: message.content.id,\n data: optionsData,\n },\n next: { rid: data.rid },\n })\n }\n } else {\n Toast.fail(msg)\n }\n })\n }\n\n consult = (e) => {\n e.preventDefault()\n let target = e.target\n http\n .post(`${API.home}/sys/icc/consult`, {\n rid: this.props.intelligentRecommend.result.rid,\n })\n .finally(() => {\n window.location.href = target.getAttribute(\"href\")\n })\n }\n\n displayPrice = (price) => {\n let _price = price.toString()\n let decimal = _price.split(\".\")\n return parseInt(decimal[1]) === 0 ? decimal[0] : price\n }\n\n goBack = () => {\n const { state } = this.props.location\n if (browser.isWeixin && getParam(\"code\") && getParam(\"state\")) {\n window.history.go(-2)\n }\n if (state.records && state.records.length > 1) {\n window.history.go(-1)\n } else if (state.from && state.from.pathname) {\n window.location.replace(`${state.from.pathname}${state.from.search}`)\n } else {\n window.location.href = window.location.origin\n }\n }\n\n render() {\n const { showAnalyzing, systemAvatar, options } = this.state\n const {\n user,\n intelligentRecommend: { result, processing },\n reselect,\n } = this.props\n const recommends = result.contents\n return (\n <div id={\"intelligent-recommend\"}>\n <div className=\"head\">\n <div>\n <div className=\"go-back\">\n <i\n className=\"iconfont iconiconfront-68\"\n onClick={this.goBack}\n ></i>\n </div>\n <div className={\"title\"}>七月在线智能选课</div>\n </div>\n <button\n onClick={() => {\n this.setState(\n {\n next: { oid: 0, rid: 0 },\n options: { messageId: 0, data: [] },\n },\n () => {\n reselect()\n this.getMessage()\n }\n )\n }}\n >\n 重新选课\n </button>\n </div>\n <div className=\"dialog-box\">\n {!!processing.length &&\n // eslint-disable-next-line array-callback-return\n processing.map((item, index) => {\n switch (item.type) {\n case messageType.SYSTEM_MESSAGE:\n return (\n <React.Fragment key={index}>\n <Message\n text={item.content.describe}\n identity={\"system\"}\n avatar={systemAvatar}\n />\n {options.messageId === item.content.id && (\n <Options\n options={options.data}\n handleSelect={this.handleSelect}\n />\n )}\n </React.Fragment>\n )\n case messageType.USER_MESSAGE:\n return (\n <Message\n text={item.content}\n identity={\"user\"}\n avatar={user.data.avatar}\n key={index + 2}\n />\n )\n }\n })}\n {showAnalyzing && <div className=\"analyzing\">努力分析中...</div>}\n </div>\n\n {!isEmpty(recommends) && (\n <div className=\"result\">\n <div className=\"title\">根据您目前的情况,推荐结果如下</div>\n <div className=\"obtained\">\n <div\n className={\"subtitle\"}\n dangerouslySetInnerHTML={{ __html: recommends.skill_title }}\n ></div>\n <div\n className={\"skill\"}\n dangerouslySetInnerHTML={{ __html: recommends.skill_desc }}\n ></div>\n </div>\n <div className=\"obtained\">\n <div\n className={\"subtitle\"}\n dangerouslySetInnerHTML={{ __html: recommends.project_title }}\n ></div>\n <div\n className={\"skill project\"}\n dangerouslySetInnerHTML={{ __html: recommends.project_desc }}\n ></div>\n {/*<ul>\n <li className={'skill project'}>·技能描述、技能描述</li>\n <li className={'skill project'}>·工作及项目描述、工作及项目描述、项目描述</li>\n </ul>*/}\n </div>\n <div className={\"salary-section\"}>\n <div\n className={\"subtitle\"}\n dangerouslySetInnerHTML={{ __html: recommends.salary_title }}\n ></div>\n <div\n className={\"salary\"}\n dangerouslySetInnerHTML={{ __html: recommends.salary_desc }}\n ></div>\n </div>\n <div className=\"recommends\">\n <div>想获得以上技能,向您推荐:</div>\n <ul className={\"courses\"}>\n {!!recommends.courses.length &&\n recommends.courses.map((item) => {\n return (\n <li\n className={\"course\"}\n key={item.course_id}\n onClick={(e) => {\n if (e.target.nodeName.toLowerCase() !== \"a\") {\n if (item.course_id) {\n this.props.history.push(\n `/detail?id=${item.course_id}`\n )\n } else {\n this.props.history.push(\n `/play?id=${item.v_course_id}`\n )\n }\n }\n }}\n >\n <div className=\"cover\">\n <img src={item.img_url} alt=\"\" />\n </div>\n <div className=\"info\">\n <div className={\"title\"}>{item.recmd_title}</div>\n <div className={\"des\"}>{item.recmd_desc}</div>\n <div className=\"bar\">\n {item.c_type === 1 && (\n <React.Fragment key={item.course_id}>\n <div className=\"prices\">\n <span className={\"price\"}>\n ¥{this.displayPrice(item.price_sale)}\n </span>\n <span className={\"old-price\"}>\n ¥{this.displayPrice(item.price_original)}\n </span>\n </div>\n <Link\n className={\"register\"}\n to={`/detail?id=${item.course_id}`}\n >\n {item.second_btn}\n </Link>\n </React.Fragment>\n )}\n {item.c_type === 2 && (\n <React.Fragment key={item.course_id}>\n <a\n href=\"http://q.url.cn/s/Vbkup6m?_type=wpa\"\n className={\"contact\"}\n onClick={this.consult}\n >\n {item.consult}\n </a>\n <Link\n className={\"register\"}\n to={`/detail?id=${item.course_id}`}\n >\n {item.second_btn}\n </Link>\n </React.Fragment>\n )}\n {item.c_type === 0 && (\n <Link\n className={\"study\"}\n to={`/play?id=${item.v_course_id}`}\n >\n {item.second_btn}\n </Link>\n )}\n </div>\n </div>\n </li>\n )\n })}\n </ul>\n </div>\n </div>\n )}\n </div>\n )\n }\n}\n\nfunction Message({ text, avatar, identity }) {\n return (\n <div className={`message clearfix ${identity}`}>\n <div className=\"avatar\">\n <img src={avatar} alt=\"\" />\n </div>\n <div className={`text`}>{text}</div>\n </div>\n )\n}\n\nfunction Options({ options, handleSelect }) {\n return (\n <ul className={\"options\"}>\n {!!options.length &&\n options.map((item) => {\n return (\n <li onClick={() => handleSelect(item)} key={item.id}>\n <button>{item.describe}</button>\n </li>\n )\n })}\n </ul>\n )\n}\n\nexport default connect(\n ({ user, intelligentRecommend }) => ({ user, intelligentRecommend }),\n { addMessage, addResult, reselect }\n)(WithFullSize(IntelligentRecommend))\n"],"sourceRoot":""} {"version":3,"sources":["components/intelligent-recommend/index.js"],"names":["messageType","IntelligentRecommend","state","showAnalyzing","systemAvatar","options","data","messageId","next","oid","rid","handleSelect","item","props","addMessage","type","content","describe","id","setState","getMessage","http","get","API","home","then","res","code","msg","answer_type","setTimeout","addResult","Math","random","message","contents","find","is_question","optionsData","filter","fail","consult","e","preventDefault","target","post","intelligentRecommend","result","finally","window","location","href","getAttribute","displayPrice","price","decimal","toString","split","parseInt","goBack","browser","isWeixin","getParam","history","go","records","length","from","pathname","replace","search","origin","this","reselect","isEmpty","user","processing","recommends","className","onClick","map","index","Fragment","key","Message","text","identity","avatar","Options","dangerouslySetInnerHTML","__html","skill_title","skill_desc","project_title","project_desc","salary_title","salary_desc","courses","course_id","nodeName","toLowerCase","push","v_course_id","src","img_url","alt","recmd_title","recmd_desc","c_type","price_sale","price_original","to","second_btn","Component","connect","WithFullSize"],"mappings":"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","file":"mrstaticjs/intelligent-recommend.f7bc22bd.chunk.js","sourcesContent":["/* eslint-disable default-case */\nimport React, { Component } from \"react\"\nimport \"./index.scss\"\nimport { Link } from \"react-router-dom\"\nimport { browser, getParam, http } from \"src/utils\"\nimport { Toast } from \"antd-mobile\"\nimport { connect } from \"react-redux\"\nimport { WithFullSize } from \"src/HOCs\"\nimport { isEmpty } from \"lodash\"\nimport { addMessage, addResult, reselect } from \"./store\"\n\nconst messageType = {\n SYSTEM_MESSAGE: 1,\n USER_MESSAGE: 2,\n OPTIONS: 3,\n}\n\nclass IntelligentRecommend extends Component {\n state = {\n showAnalyzing: false,\n systemAvatar:\n \"https://img-public.julyedu.com/Public/Image/home/avatar_20191104.png\",\n options: {\n data: [],\n messageId: 0,\n },\n next: {\n oid: 0,\n rid: 0,\n },\n }\n\n componentDidMount() {\n const { intelligentRecommend, reselect } = this.props\n if (isEmpty(intelligentRecommend.result)) {\n reselect()\n this.getMessage()\n }\n }\n\n handleSelect = (item) => {\n this.props.addMessage({\n type: messageType.USER_MESSAGE,\n content: item.describe,\n id: item.id,\n })\n this.setState(\n (state) => ({\n options: { data: [], messageId: 0 },\n next: {\n ...state.next,\n oid: item.id,\n },\n }),\n () => {\n this.getMessage()\n }\n )\n }\n\n getMessage = () => {\n const { oid, rid } = this.state.next\n http.get(`${API.home}/sys/icc/communicate/${oid}/${rid}`).then((res) => {\n const { data, code, msg } = res.data\n if (code === 200) {\n if (data.answer_type === 1) {\n this.setState(\n {\n showAnalyzing: true,\n },\n () => {\n setTimeout(() => {\n this.setState({ showAnalyzing: false })\n this.props.addResult({ ...data })\n }, Math.random() * 500 + 1000)\n }\n )\n } else {\n const message = {\n type: messageType.SYSTEM_MESSAGE,\n content: data.contents.find((item) => item.is_question),\n }\n const optionsData = data.contents.filter((item) => !item.is_question)\n this.props.addMessage(message)\n this.setState({\n options: {\n messageId: message.content.id,\n data: optionsData,\n },\n next: { rid: data.rid },\n })\n }\n } else {\n Toast.fail(msg)\n }\n })\n }\n\n consult = (e) => {\n e.preventDefault()\n let target = e.target\n http\n .post(`${API.home}/sys/icc/consult`, {\n rid: this.props.intelligentRecommend.result.rid,\n })\n .finally(() => {\n window.location.href = target.getAttribute(\"href\")\n })\n }\n\n displayPrice = (price) => {\n let _price = price.toString()\n let decimal = _price.split(\".\")\n return parseInt(decimal[1]) === 0 ? decimal[0] : price\n }\n\n goBack = () => {\n const { state } = this.props.location\n if (browser.isWeixin && getParam(\"code\") && getParam(\"state\")) {\n window.history.go(-2)\n }\n if (state.records && state.records.length > 1) {\n window.history.go(-1)\n } else if (state.from && state.from.pathname) {\n window.location.replace(`${state.from.pathname}${state.from.search}`)\n } else {\n window.location.href = window.location.origin\n }\n }\n\n render() {\n const { showAnalyzing, systemAvatar, options } = this.state\n const {\n user,\n intelligentRecommend: { result, processing },\n reselect,\n } = this.props\n const recommends = result.contents\n return (\n <div id={\"intelligent-recommend\"}>\n <div className=\"head\">\n <div>\n <div className=\"go-back\">\n <i\n className=\"iconfont iconiconfront-68\"\n onClick={this.goBack}\n ></i>\n </div>\n <div className={\"title\"}>七月在线智能选课</div>\n </div>\n <button\n onClick={() => {\n this.setState(\n {\n next: { oid: 0, rid: 0 },\n options: { messageId: 0, data: [] },\n },\n () => {\n reselect()\n this.getMessage()\n }\n )\n }}\n >\n 重新选课\n </button>\n </div>\n <div className=\"dialog-box\">\n {!!processing.length &&\n // eslint-disable-next-line array-callback-return\n processing.map((item, index) => {\n switch (item.type) {\n case messageType.SYSTEM_MESSAGE:\n return (\n <React.Fragment key={index}>\n <Message\n text={item.content.describe}\n identity={\"system\"}\n avatar={systemAvatar}\n />\n {options.messageId === item.content.id && (\n <Options\n options={options.data}\n handleSelect={this.handleSelect}\n />\n )}\n </React.Fragment>\n )\n case messageType.USER_MESSAGE:\n return (\n <Message\n text={item.content}\n identity={\"user\"}\n avatar={user.data.avatar}\n key={index + 2}\n />\n )\n }\n })}\n {showAnalyzing && <div className=\"analyzing\">努力分析中...</div>}\n </div>\n\n {!isEmpty(recommends) && (\n <div className=\"result\">\n <div className=\"title\">根据您目前的情况,推荐结果如下</div>\n <div className=\"obtained\">\n <div\n className={\"subtitle\"}\n dangerouslySetInnerHTML={{ __html: recommends.skill_title }}\n ></div>\n <div\n className={\"skill\"}\n dangerouslySetInnerHTML={{ __html: recommends.skill_desc }}\n ></div>\n </div>\n <div className=\"obtained\">\n <div\n className={\"subtitle\"}\n dangerouslySetInnerHTML={{ __html: recommends.project_title }}\n ></div>\n <div\n className={\"skill project\"}\n dangerouslySetInnerHTML={{ __html: recommends.project_desc }}\n ></div>\n {/*<ul>\n <li className={'skill project'}>·技能描述、技能描述</li>\n <li className={'skill project'}>·工作及项目描述、工作及项目描述、项目描述</li>\n </ul>*/}\n </div>\n <div className={\"salary-section\"}>\n <div\n className={\"subtitle\"}\n dangerouslySetInnerHTML={{ __html: recommends.salary_title }}\n ></div>\n <div\n className={\"salary\"}\n dangerouslySetInnerHTML={{ __html: recommends.salary_desc }}\n ></div>\n </div>\n <div className=\"recommends\">\n <div>想获得以上技能,向您推荐:</div>\n <ul className={\"courses\"}>\n {!!recommends.courses.length &&\n recommends.courses.map((item) => {\n return (\n <li\n className={\"course\"}\n key={item.course_id}\n onClick={(e) => {\n if (e.target.nodeName.toLowerCase() !== \"a\") {\n if (item.course_id) {\n this.props.history.push(\n `/detail?id=${item.course_id}`\n )\n } else {\n this.props.history.push(\n `/play?id=${item.v_course_id}`\n )\n }\n }\n }}\n >\n <div className=\"cover\">\n <img src={item.img_url} alt=\"\" />\n </div>\n <div className=\"info\">\n <div className={\"title\"}>{item.recmd_title}</div>\n <div className={\"des\"}>{item.recmd_desc}</div>\n <div className=\"bar\">\n {item.c_type === 1 && (\n <React.Fragment key={item.course_id}>\n <div className=\"prices\">\n <span className={\"price\"}>\n ¥{this.displayPrice(item.price_sale)}\n </span>\n <span className={\"old-price\"}>\n ¥{this.displayPrice(item.price_original)}\n </span>\n </div>\n <Link\n className={\"register\"}\n to={`/detail?id=${item.course_id}`}\n >\n {item.second_btn}\n </Link>\n </React.Fragment>\n )}\n {item.c_type === 2 && (\n <React.Fragment key={item.course_id}>\n <a\n href=\"https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372\"\n className={\"contact\"}\n onClick={this.consult}\n >\n {item.consult}\n </a>\n <Link\n className={\"register\"}\n to={`/detail?id=${item.course_id}`}\n >\n {item.second_btn}\n </Link>\n </React.Fragment>\n )}\n {item.c_type === 0 && (\n <Link\n className={\"study\"}\n to={`/play?id=${item.v_course_id}`}\n >\n {item.second_btn}\n </Link>\n )}\n </div>\n </div>\n </li>\n )\n })}\n </ul>\n </div>\n </div>\n )}\n </div>\n )\n }\n}\n\nfunction Message({ text, avatar, identity }) {\n return (\n <div className={`message clearfix ${identity}`}>\n <div className=\"avatar\">\n <img src={avatar} alt=\"\" />\n </div>\n <div className={`text`}>{text}</div>\n </div>\n )\n}\n\nfunction Options({ options, handleSelect }) {\n return (\n <ul className={\"options\"}>\n {!!options.length &&\n options.map((item) => {\n return (\n <li onClick={() => handleSelect(item)} key={item.id}>\n <button>{item.describe}</button>\n </li>\n )\n })}\n </ul>\n )\n}\n\nexport default connect(\n ({ user, intelligentRecommend }) => ({ user, intelligentRecommend }),\n { addMessage, addResult, reselect }\n)(WithFullSize(IntelligentRecommend))\n"],"sourceRoot":""}
\ No newline at end of file \ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
(this["webpackJsonpmr-julyedu"]=this["webpackJsonpmr-julyedu"]||[]).push([[46],{1071:function(e,t,a){},1072:function(e,t,a){},1073:function(e,t,a){},1074:function(e,t,a){},1075:function(e,t,a){},1076:function(e,t,a){},1077:function(e,t,a){},1078:function(e,t,a){},1188:function(e,t,a){"use strict";a.r(t);a(36);var n,r,s=a(10),o=a.n(s),c=a(3),i=a(5),l=a(6),u=a(7),m=a(0),p=a.n(m),d=(a(1071),a(4)),h=a(58),f=(a(1072),a(1)),g=a(28),v=a(419),b=a.n(v),y=a(20),_=Object(y.b)((function(e){return{user:e.user}}))(n=function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(e){var n;return Object(c.a)(this,a),(n=t.call(this,e)).getLength=function(){var e=Object(h.a)(n);f.f.get("".concat(API.home,"/activity/wish_sum")).then((function(t){var a=t.data,n=a.code,r=a.data;200==n&&e.setState({sum:r.sum})}))},n.fetchBigCourse=function(){var e=n.state.bigcourse;f.f.get("".concat(API.home,"/activity/preheat_data")).then((function(t){var a=t.data,r=a.code,s=a.data;200===r&&n.setState({bigcourse:Object.assign({},e,{isMore:!1,course:s,courseList:s})})}))},n.fetchFreeCourse=function(){var e=n.state.freecourse;f.f.get("".concat(API["base-api"],"/assistance/detail")).then((function(t){var a=t.data,r=a.errno,s=a.data;200===r&&n.setState({freecourse:Object.assign({},e,{isMore:s.course_info.length>4,course:s.course_info.length>4?s.course_info.filter((function(e,t){return t<4})):s.course_info,courseList:s.course_info})})}))},n.fetchGroupCourse=function(){var e=n.state.groupcourse;f.f.get("".concat(API.home,"/activity/excellent_course")).then((function(t){var a=t.data,r=a.code,s=a.data;200===r&&n.setState({groupcourse:Object.assign({},e,{isMore:s.length>4,course:s.length>4?s.filter((function(e,t){return t<4})):s,courseList:s})})}))},n.fetchAICourse=function(e,t){f.f.get("".concat(API.home,"/activity/four_stage/").concat(e)).then((function(a){var r=a.data,s=r.code,o=r.data;200===s&&n.getList(e,o,t)}))},n.getList=function(e,t,a){var r=n.state,s=r.basic,o=r.advanced,c=r.higher,i=r.expand;"one"===e&&n.setState({basic:Object.assign({},s,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})}),"two"===e&&n.setState({advanced:Object.assign({},o,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})}),"three"===e&&n.setState({higher:Object.assign({},c,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})}),"four"===e&&n.setState({expand:Object.assign({},i,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})})},n.toQQque=function(){Object(f.c)("version")?Object(f.a)("toQQ","https://q.url.cn/AB8aue?_type=wpa&qidian=true"):window.location.href="http://q.url.cn/s/Vbkup6m?_type=wpa"},n.toCourse=function(e){var t=n.props.history;Object(f.c)("version")?Object(f.a)("toCourse",e):t.push("/detail?id=".concat(e))},n.handleToMore=function(e){var t={};n.state[e].isMore?(t[e]={isMore:!n.state[e].isMore,course:n.state[e].courseList,courseList:n.state[e].courseList,addshowMore:!n.state[e].addshowMore},n.setState(Object(d.a)({},t))):(t[e]={isMore:!n.state[e].isMore,course:n.state[e].courseList.filter((function(e,t){return t<4})),courseList:n.state[e].courseList,addshowMore:!n.state[e].addshowMore},n.setState(Object(d.a)({},t)))},n.toLogin=function(){Object(f.c)("version")?Object(f.a)("toLogin"):n.props.history.push("/passport/login")},n.freeStudy=function(){n.setState({tofreeStudy:!0})},n.closePopup=function(){n.setState({tofreeStudy:!1})},n.closePopupWish=function(){var e=Object(h.a)(n);e.setState({isshowFollow:!1}),setTimeout((function(){e.toJoinList(e.state.wish.id,e.state.wish.key)}),200)},n.getQRcodeUrl=function(){var e=Object(h.a)(n);f.f.get("".concat(API["base-api"],"/wx/user_temporary_qrcode/").concat(e.props.user.data.uid)).then((function(e){var t=e.data,a=t.errno,r=t.data,s=t.msg;0==a?(n.setState({qrUrl:r.url}),b.a.toDataURL(r.url,(function(e,t){n.setState({followBarcode:t})}))):o.a.info(s,2)}))},n.addWishList=function(e,t){var a=Object(h.a)(n),r=!n.props.user.hasError;a.setState({wish:{id:e,key:t}}),r?a.isFollow(e,t):a.toLogin()},n.isFollow=function(e,t){var a=Object(h.a)(n);f.f.get("".concat(API.home,"/sys/user/isFollowWeChat")).then((function(n){var r=n.data,s=r.code,c=r.data,i=r.msg;200===s?(a.setState({isshowFollow:!c.is_follow}),a.state.isshowFollow?a.getQRcodeUrl():a.toJoinList(e,t)):o.a.info(i,2)}))},n.toJoinList=function(e,t){var a=Object(h.a)(n);f.f.post("".concat(API.home,"/activity/join_list"),{course_id:e}).then((function(e){var n=e.data,r=n.code,s=n.msg;200==r?(o.a.success("\u5df2\u6210\u529f\u52a0\u5165\u5fc3\u613f\u5355",3),a.getLength(),"1"===t&&a.fetchAICourse("one",a.state.basic.addshowMore),"2"===t&&a.fetchAICourse("two",a.state.advanced.addshowMore),"3"===t&&a.fetchAICourse("three",a.state.higher.addshowMore),"4"===t&&a.fetchAICourse("four",a.state.expand.addshowMore),"group"===t&&a.fetchGroupCourse()):o.a.info(s,2)}))},n.saveImage=function(){var e=Object(f.c)("version");e="string"===typeof e?e.replace(".","").replace(".","").slice(0,3):"";var t=n.state.qrUrl;e&&parseInt(e)<451?o.a.info("\u5f53\u524d\u4e0d\u652f\u6301\u6b64\u529f\u80fd\uff0c\u5347\u7ea7\u5230\u6700\u65b0\u7248\u672capp\u53ef\u4ee5\u70b9\u51fb\u4fdd\u5b58\u4e8c\u7ef4\u7801\uff01",3,null,!1):Object(f.a)("generateQRCode",t)},n.saveImage2=function(){var e=Object(f.c)("version");(e="string"===typeof e?e.replace(".","").replace(".","").slice(0,3):"")&&parseInt(e)<451?o.a.info("\u5f53\u524d\u4e0d\u652f\u6301\u6b64\u529f\u80fd\uff0c\u5347\u7ea7\u5230\u6700\u65b0\u7248\u672capp\u53ef\u4ee5\u70b9\u51fb\u4fdd\u5b58\u4e8c\u7ef4\u7801\uff01",3,null,!1):Object(f.a)("saveImage","https://cdn.julyedu.com/2018christyear/h5/qrcode.jpg")},n.getTeamInfo=function(){f.f.get("".concat(API.home,"/sys/treasure/teamInfo")).then((function(e){var t=e.data,a=t.code,r=t.data,s=t.msg;if(200===a){var c=r.info,i=r.removable_data;n.setState({removable:c.removable,currentId:c.removable>0?i[0].id:null})}else o.a.info(s)}))},n.toBoxList=function(){var e=!n.props.user.hasError,t=n.state.currentId,a="";t&&(a="?id=".concat(t)),e?Object(f.c)("version")?n.props.history.push("/box/yearTreasure".concat(a,"?version=").concat(Object(f.c)("version"))):n.props.history.push("/box/yearTreasure".concat(a)):n.toLogin()},n.toYearWish=function(){!n.props.user.hasError?Object(f.c)("version")?n.props.history.push("/year/yearWish?version=".concat(Object(f.c)("version"))):n.props.history.push("/year/yearWish"):n.toLogin()},n.toInviteFriends=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=n.props.history;if(Object(f.c)("version")){var r={title:"\u3010\u4ec5\u5269".concat(t.number,"\u4e2a\u540d\u989d\u3011\u6211").concat(t.price,"\u5143\u62fc\u4e86\u300a").concat(t.course_title,"\u300b"),desc:t.course_title,link:"".concat(API.m,"/togroup?id=").concat(e,"&is_originator=1"),imgUrl:t.image_name};Object(f.a)("toShare",r)}else a.push("/togroup?id=".concat(e))},n.isCountDown=function(e,t){return e?t:""},n.formatTitleAndKey=function(e){var t=null;switch(e){case 1:t={title:"\u57fa\u7840",key:"basic"};break;case 2:t={title:"\u8fdb\u9636",key:"advanced"};break;case 3:t={title:"\u9ad8\u9636",key:"higher"};break;case 4:t={title:"\u6269\u5c55",key:"expand"};break;default:t=null}return t},n.formatCourseData=function(e){var t=n.state,a=t.basic,r=t.advanced,s=t.higher,o=t.expand,c=null;switch(e){case 1:c=a;break;case 2:c=r;break;case 3:c=s;break;case 4:c=o;break;default:c=null}return c},n.toCart=function(e){var t=n.props.history;f.f.post("".concat(API.home,"/m/cart/add"),{course_id:e}).then((function(e){var a=e.data,r=a.code,s=a.msg;200===r||15001===r?Object(f.c)("version")?Object(f.a)("toShoppingCart"):t.push("/shopcart"):4030===r||4040===r?n.toLogin():o.a.info(s,2)}))},n.toContinueBargain=function(e,t,a,r){var s=n.props.history;if(Object(f.c)("version")){var o={title:"\u6211\u53d1\u73b0\u4e00\u95e8\u597d\u8bfe\uff0c\u5feb\u6765\u5e2e\u6211\u780d\u4ef7\u5427\uff01",desc:"\u6211\u5df2\u7ecf\u780d\u4e86".concat(t,"\u5143\uff0c\u770b\u770b\u4f60\u80fd\u780d\u591a\u5c11"),link:"".concat(API.m,"/bargain-middle-page?id=").concat(e,"&bargaincode=").concat(a,"&is_originator=1"),imgUrl:r};Object(f.a)("toShare",o)}else s.push("/bargain-middle-page?id=".concat(e,"&bargaincode=").concat(a,"&is_originator=1"))},n.bargainToOrder=function(e){var t=n.props,a=t.history;t.user.hasError?n.toLogin():Object(f.c)("version")?Object(f.a)("toPay",e):f.f.get("".concat(API["base-api"],"/m/cart/addtopreorder/[").concat(e,"]")).then((function(t){var n=t.data,r=n.errno,s=n.msg;0===r?a.push("/order?id=[".concat(e,"]"),{bargain:1}):o.a.info(s,2)}))},n.state={tofreeStudy:!1,basic:{course:[],courseList:[],isMore:!1,addshowMore:!1},advanced:{course:[],courseList:[],isMore:!1,addshowMore:!1},higher:{course:[],courseList:[],isMore:!1,addshowMore:!1},expand:{course:[],courseList:[],isMore:!1,addshowMore:!1},bigcourse:{course:[],courseList:[],isMore:!1},freecourse:{course:[],courseList:[],isMore:!1},groupcourse:{course:[],courseList:[],isMore:!1},isshowFollow:!1,wish:{id:"",key:""},followBarcode:"",qrUrl:"",sum:"",removable:"",currentId:""},n}return Object(i.a)(a,[{key:"componentDidMount",value:function(){this.getTeamInfo(),this.getLength(),this.fetchBigCourse(),this.fetchGroupCourse(),this.fetchAICourse("one",!1),this.fetchAICourse("two",!1),this.fetchAICourse("three",!1),this.fetchAICourse("four",!1)}},{key:"shouldComponentUpdate",value:function(e,t,a){return this.props.isAppUpdate===e.isAppUpdate||(this.getTeamInfo(),this.getLength(),this.fetchBigCourse(),this.fetchGroupCourse(),this.fetchAICourse("one"),this.fetchAICourse("two"),this.fetchAICourse("three"),this.fetchAICourse("four"),!1)}},{key:"render",value:function(){var e=this.state.removable;return p.a.createElement("div",{className:"year-index-course"},e>0&&p.a.createElement("div",{className:"nav-right-wish nav-right"},p.a.createElement("span",{onClick:this.toBoxList,className:"nav-right__link"},"\u672a\u5f00\u5b9d\u7bb1",p.a.createElement("i",{className:"nav-right__number"},e))))}}]),a}(m.Component))||n,j=Object(g.g)(_),E=(a(1073),function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(){return Object(c.a)(this,a),t.apply(this,arguments)}return Object(i.a)(a,[{key:"render",value:function(){var e=this.props.id;return p.a.createElement("div",{className:"common_container",id:e},p.a.createElement("div",{className:"container_top"}),p.a.createElement("div",{className:"container_content"},this.props.title&&p.a.createElement("div",{className:"title_container"},p.a.createElement("i",null),p.a.createElement("p",null,this.props.title),p.a.createElement("i",null)),p.a.Children.map(this.props.children,(function(e){return p.a.createElement(p.a.Fragment,null,e)}))),p.a.createElement("div",{className:"container_bottom"}))}}]),a}(m.Component)),k=(a(1074),function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(e){var n;return Object(c.a)(this,a),(n=t.call(this,e)).fetchRankInfo=function(){f.f.get("".concat(API.home,"/sys/treasure/ranking")).then((function(e){var t=e.data,a=t.code,r=t.data;200===a&&"{}"!==JSON.stringify(r)&&(r.length>5?n.setState({rank:r.filter((function(e,t){return t<5})),rankList:r,isMore:!0}):n.setState({rank:r,rankList:r,isMore:!1}))}))},n.switchMoreRank=function(){var e=n.state,t=e.rankList;e.isMore?n.setState({rank:t,isMore:!1}):n.setState({rank:t.filter((function(e,t){return t<5})),isMore:!0})},n.handleToVip=function(e){var t=n.props.history;e&&(Object(f.c)("version")?Object(f.a)("toCourse",e):t.push("/detail?id=".concat(e)))},n.state={rank:[],rankList:[],isMore:!1},n}return Object(i.a)(a,[{key:"componentDidMount",value:function(){this.fetchRankInfo()}},{key:"render",value:function(){var e=this,t=this.state,a=t.rank,n=t.isMore;return p.a.createElement(p.a.Fragment,null,0!==a.length&&p.a.createElement("div",{"data-skip":"rank"},p.a.createElement("div",{className:"rank-title"},p.a.createElement("i",{className:"rank-title__decorate"}),p.a.createElement("h2",{className:"rank-title__txt"},"\u5b9d\u7bb1\u8fbe\u4eba\u699c"),p.a.createElement("i",{className:"rank-title__decorate"})),p.a.createElement("p",{className:"rank-desc"},"\u5b9d\u7bb1\u6570\u91cf\u524d50\u540d\u53ef\u989d\u5916\u83b7\u5f97\u4e00\u4efd\u5956\u54c1\uff0c\u6570\u91cf\u76f8\u540c\u7684\u7528\u65f6\u77ed\u8005\u6392\u540d\u5728\u524d"),p.a.createElement("dl",{className:"rank-header"},p.a.createElement("dd",{className:"rank-column"},"\u6392\u540d"),p.a.createElement("dd",{className:"rank-column"},"\u7528\u6237"),p.a.createElement("dd",{className:"rank-column"},"\u5b9d\u7bb1\u6570\u91cf"),p.a.createElement("dd",{className:"rank-column"},"\u5956\u54c1")),p.a.createElement("div",{className:"rank-body"},a.map((function(t,a){return p.a.createElement("dl",{className:"rank-item",key:a},p.a.createElement("dd",{className:"rank-column"},a<=2?p.a.createElement("span",{className:"rank-column__number","data-num":a}):p.a.createElement("span",null,a+1)),p.a.createElement("dd",{className:"rank-column"},p.a.createElement("span",{className:"rank-column__name"},t.user_name)),p.a.createElement("dd",{className:"rank-column"},p.a.createElement("span",null,t.num)),p.a.createElement("dd",{className:"rank-column"},t.url?p.a.createElement("a",{className:"rank-column__txt",onClick:function(){return e.handleToVip(t.url)}},t.prize_name):p.a.createElement("span",{className:"rank-column__txt"},t.prize_name)))})),p.a.createElement("div",{className:"rank-more",onClick:this.switchMoreRank},p.a.createElement("span",{className:"rank-more__txt"},n?"\u5c55\u5f00":"\u6536\u8d77"),p.a.createElement("i",{className:"rank-more__icon","data-more":n})))))}}]),a}(m.Component)),w=(a(1075),a(24)),O=a(38),N=a.n(O),I=function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(e){var n;return Object(c.a)(this,a),(n=t.call(this,e)).getTeamInfo=function(){f.f.get("".concat(API.home,"/sys/treasure/teamInfo")).then((function(e){var t=e.data,a=t.code,r=t.data,s=t.msg;if(200===a){var c=r.prize_info,i=r.is_my_team,l=r.info,u=r.member,m=r.removable_data,p=r.my_team;n.setState({prize_info:c,is_my_team:i,info:l,member:n.fillTeam(u,i),removable_data:m,my_team:p});var d=null;l.removable>0&&(d=m[0].id),n.props.getRemovable(l.removable,d)}else o.a.info(s)}))},n.toYearTreasure=function(e){if(n.props.user.hasError)n.toLogin();else{var t="";if(e){var a=n.state,r=a.removable_data;if(a.info.removable>0){var s=r[0];t="?id=".concat(s.id)}}Object(f.c)("version")?n.props.history.push("/box/yearTreasure".concat(t,"?version=").concat(Object(f.c)("version"))):n.props.history.push("/box/yearTreasure".concat(t))}},n.toLogin=function(){Object(f.c)("version")?Object(f.a)("toLogin"):n.props.history.push("/passport/login")},n.createTeam=function(){if(n.props.user.hasError)n.toLogin();else{sessionStorage.setItem("showShareTip","1");var e=n.state,t=e.is_my_team,a=e.my_team.treasure_code;t?Object(f.c)("version")?window.location.assign("https://m.julyedu.com/box/landing?origin=1&treasure_code="+a+"&version="+Object(f.c)("version")):window.location.assign("https://m.julyedu.com/box/landing?origin=1&treasure_code="+a):f.f.get("".concat(API.home,"/sys/treasure/createMyTeam")).then((function(e){var t=e.data,a=t.code,n=t.data,r=t.msg;if(200===a){var s=n.treasure_code;Object(f.c)("version")?window.location.assign("https://m.julyedu.com/box/landing?origin=1&treasure_code="+s+"&version="+Object(f.c)("version")):window.location.assign("https://m.julyedu.com/box/landing?origin=1&treasure_code="+s)}else o.a.info(r)}))}},n.fillTeam=function(e,t){var a=e.length;if(n.props.user.hasError)for(var r=0;r<5-a;r++)e.push({head_img:"",user_name:"",nobody:!0});else if(0!==a||t)for(var s=0;s<5-a;s++)e.push({head_img:"",user_name:"",nobody:!0});else{e.push({head_img:N.a.get("avatar_file"),user_name:N.a.get("user_name")});for(var o=0;o<4;o++)e.push({head_img:"",user_name:"",nobody:!0})}return e},n.state={is_my_team:!1,prize_info:[],info:{removable:0,total:0},member:[],removable_data:[],my_team:{}},n}return Object(i.a)(a,[{key:"componentDidMount",value:function(){this.getTeamInfo()}},{key:"shouldComponentUpdate",value:function(e,t,a){return this.props.isAppUpdate===e.isAppUpdate||(this.getTeamInfo(),!1)}},{key:"render",value:function(){var e=this,t=this.state,a=t.prize_info,n=t.is_my_team,r=t.info,s=r.removable,o=r.total,c=t.member,i="",l=0;a.length>0&&(i=a[0].name,l=a[0].stage_no);var u="";return u=0===o?"\u6211\u7684\u5b9d\u7bb1":0===s?"\u5171".concat(o,"\u4e2a\u5b9d\u7bb1"):"\u5171".concat(o,"\u4e2a\u5b9d\u7bb1/").concat(s,"\u4e2a\u672a\u5f00"),p.a.createElement("div",{className:"team_info__container"},p.a.createElement("div",{className:"team__member"},p.a.createElement("ul",{className:"member__list"},c&&c.length>0&&c.map((function(e,t){return p.a.createElement("li",{key:t,className:"member__item"},p.a.createElement("div",{className:"avatar__container"},e.nobody?p.a.createElement("img",{className:"head__image",src:"https://cdn.julyedu.com/newyear20/H5/default-member-avatar.png",alt:""}):p.a.createElement("img",{className:"head__image",src:e.head_img,alt:""}),0===t?p.a.createElement("img",{className:"caption__flag",src:"https://cdn.julyedu.com/newyear20/H5/caption.png",alt:""}):null,p.a.createElement("div",{className:"shadow"})),p.a.createElement("div",{className:"member__join ".concat(e.nobody?"":"join")}))}))),p.a.createElement("div",{className:"box__number"},p.a.createElement("img",{onClick:function(){return e.toYearTreasure(!0)},src:"https://cdn.julyedu.com/newyear20/H5/treasure-box-icon.png",alt:""}),p.a.createElement("p",{onClick:function(){return e.toYearTreasure(!1)},className:"box__text"},u),p.a.createElement("img",{className:"position__arrow",src:"https://cdn.julyedu.com/newyear20/H5/arrow_jinzhan.png",alt:""}),s>0&&p.a.createElement("div",{className:"position__number"},s))),p.a.createElement("div",{onClick:this.createTeam,className:"invite__btn"},n?"\u7ee7\u7eed\u7ec4\u961f":"\u7ec4\u961f\u5f00\u5b9d\u7bb1"),l>0&&i&&p.a.createElement("p",{className:"stage_prize"},"\u7b2c".concat(l,"\u4e2a\u5b9d\u7bb1\u5fc5\u4e2d").concat(i)))}}]),a}(m.Component),S=Object(w.d)(Object(y.b)((function(e){return{user:e.user}}),null),g.g)(I),L=(a(1076),a(25)),C=a(8),M=Object(C.a)((function(){return a.e(44).then(a.bind(null,1135))})),x=function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(){var e;Object(c.a)(this,a);for(var n=arguments.length,r=new Array(n),s=0;s<n;s++)r[s]=arguments[s];return(e=t.call.apply(t,[this].concat(r))).closeIcon="https://cdn.julyedu.com/newyear20/H5/close-btn.png",e.state={prizes:[],notices:[],rule:[],unfoldList:!1},e.getPrizes=function(){f.f.get("".concat(API.home,"/sys/prize_data")).then((function(t){var a=t.data,n=a.code,r=a.data,s=a.msg;200==n?e.setState({prizes:r.prize_data,notices:r.notices,rule:r.rule}):o.a.info(s,2,null,!1)}))},e.showRules=function(){Object(L.h)({title:"\u7ec4\u961f\u5f00\u5b9d\u7bb1\u6d3b\u52a8\u89c4\u5219",className:"landing-treasure-rules",content:p.a.createElement("div",{dangerouslySetInnerHTML:{__html:e.state.rule}}),closeIcon:e.closeIcon})},e.showMore=function(){e.setState((function(t){if(e.state.unfoldList)e.bg.style=e.innerBox.style=e.prizeBox.style="";else{var a=parseFloat(getComputedStyle(e.prizeBox,":before").getPropertyValue("height")),n=parseFloat(getComputedStyle(e.prizeBox,":after").getPropertyValue("height")),r=e.prizeList.scrollHeight,s=a+r-.12458*a-.595*n+n;e.prizeBox.style.height="".concat(s+27,"px"),e.innerBox.style.height="".concat(r,"px"),e.bg.style.height="".concat(r-n+.12458*a+27,"px")}return{unfoldList:!t.unfoldList}}))},e}return Object(i.a)(a,[{key:"componentDidMount",value:function(){this.getPrizes()}},{key:"render",value:function(){var e=this,t=this.props.showSystemNotices,a=this.state.notices;return p.a.createElement(p.a.Fragment,null,t&&a&&a.length?p.a.createElement(M,{bullets:a}):null,p.a.createElement("div",{className:"prizes-box",ref:function(t){return e.prizeBox=t}},p.a.createElement("a",{href:"javascript:;",className:"rule-btn",onClick:this.showRules},"\u6d3b\u52a8\u89c4\u5219 >"," "),p.a.createElement("div",{className:"bg",ref:function(t){return e.bg=t}}),p.a.createElement("div",{className:"inner-box",ref:function(t){return e.innerBox=t}},p.a.createElement("ul",{className:"prize-list",ref:function(t){return e.prizeList=t}},this.state.prizes.map((function(e,t){return p.a.createElement("li",{key:t},e.img_name?p.a.createElement("i",{className:"prize-list__image",style:{backgroundImage:"url(".concat(e.img_name,")")}}):p.a.createElement("i",{className:"prize-list__image"}),0!=e.is_captain&&p.a.createElement("span",{className:"captain top-tag"},"\u961f\u957f\u4e13\u5c5e"),2===e.mode&&p.a.createElement("span",{className:"stage top-tag"},"\u7b2c",e.stage_no,"\u4e2a\u5fc5\u4e2d"),e.grant_max?p.a.createElement("div",{className:"bottom-bar"},p.a.createElement("div",{className:"progress-bar"},p.a.createElement("span",{className:"progress",style:{width:"".concat(e.surplus/e.grant_max*100,"%")}})),p.a.createElement("span",null,"\u9650\u91cf",e.grant_max,"\u4efd")):p.a.createElement("span",{className:"no-limit"},"\u4e0d\u9650\u91cf"))})),p.a.createElement("li",null,p.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/prize-placeholder.png",alt:""})))),p.a.createElement("div",{className:"show-more",onClick:this.showMore},this.state.unfoldList?p.a.createElement("div",null,"\u6536\u8d77",p.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/fold-icon.png",alt:""})):p.a.createElement("div",null,"\u67e5\u770b\u5168\u90e8\u5956\u54c1",p.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/unfold-icon.png",alt:""})))))}}]),a}(m.Component),A=a(73),P=a(139),z=(a(205),a(1077),function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(){var e;Object(c.a)(this,a);for(var n=arguments.length,r=new Array(n),s=0;s<n;s++)r[s]=arguments[s];return(e=t.call.apply(t,[this].concat(r))).state={bulletScreenData:[]},e.initializeBulletScreen=function(){var t=Object(h.a)(e),a=Object(A.a)(Array(19).keys()),n=!1;e.swiper=new P.a(".swiper-container",{direction:"vertical",allowTouchMove:!1,autoplay:!0,on:{transitionEnd:function(){var e=this;this.slides.length>20&&(this.removeSlide(0),this.autoplay.start()),this.activeIndex!==this.slides.length-1||n||(this.autoplay.stop(),t.getBulletScreenData().then((function(r){n=!0,e.removeSlide(a),e.appendSlide(t.getSlides(r)),setTimeout((function(){e.autoplay.start(),n=!1}))})))}}})},e.getSlides=function(e){return e.map((function(e){return'\n <li class="swiper-slide">\n <img class="avatar" src="'.concat(e.avatar_file,'" alt="">\n <span>').concat(e.user_name," ").concat(e.msg,"</span>\n </li>\n ")}))},e.getBulletScreenData=function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return f.f.get("".concat(API.home,"/sys/barrage_data")).then((function(a){var n=a.data,r=n.data;if(200===n.code){if(!t)return r;e.setState({bulletScreenData:r},(function(){e.initializeBulletScreen()}))}}))},e}return Object(i.a)(a,[{key:"componentDidMount",value:function(){this.getBulletScreenData(!0)}},{key:"componentWillUnmount",value:function(){this.swiper&&this.swiper.destroy()}},{key:"render",value:function(){var e=this.state.bulletScreenData;return p.a.createElement("div",{id:"user-bullet-screen",className:"swiper-container"},p.a.createElement("ul",{className:"swiper-wrapper"},e.length&&e.map((function(e,t){return p.a.createElement("li",{className:"swiper-slide",key:t},p.a.createElement("img",{src:e.avatar_file,alt:"",className:"avatar"}),p.a.createElement("span",null,e.user_name," ",e.msg))}))))}}]),a}(m.Component)),T=function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(){return Object(c.a)(this,a),t.apply(this,arguments)}return Object(i.a)(a,[{key:"render",value:function(){return p.a.createElement(E,{id:"year-treasure",title:"\u7ec4\u961f\u5f00\u5b9d\u7bb1"},p.a.createElement("div",{style:{textAlign:"center",fontSize:"12px",color:"#FFDC1E",marginTop:"10px"}},"\u9080\u8bf7\u597d\u53cb\u7ec4\u961f\u4e00\u8d77\u5f00\u5b9d\u7bb1\uff0c\u6ee15\u4eba\u540e\u5c06\u968f\u673a\u83b7\u5f97\u4ee5\u4e0b\u5956\u54c1~"),p.a.createElement(x,{showSystemNotices:!0}),p.a.createElement(z,null),p.a.createElement(S,{isAppUpdate:this.props.isAppUpdate,getRemovable:this.props.getRemovable}),p.a.createElement(k,{history:this.props.history}))}}]),a}(m.Component),U=Object(g.g)(T),B=(a(1078),function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(){var e;Object(c.a)(this,a);for(var n=arguments.length,r=new Array(n),s=0;s<n;s++)r[s]=arguments[s];return(e=t.call.apply(t,[this].concat(r))).computedStyle=function(){return{top:"".concat(e.props.top,"px"),width:"".concat(e.props.width,"px")}},e.closePopup=function(){e.props.mark&&e.props.closePopup()},e}return Object(i.a)(a,[{key:"render",value:function(){return p.a.createElement("div",{className:"popup__container",onClick:this.closePopup},p.a.createElement("div",{className:"content__container",style:this.computedStyle(),onClick:function(e){e.stopPropagation()}},p.a.createElement("img",{className:"close__btn",onClick:this.props.closePopup,src:"https://cdn.julyedu.com/newyear20/H5/close-btn.png",alt:""}),p.a.Children.map(this.props.children,(function(e){return p.a.createElement(p.a.Fragment,null,e)}))))}}]),a}(m.Component)),F=a(23),D=a(404),R=Object(y.b)((function(e){return{user:e.user}}),{setCurrentUser:F.i,startFetchUser:F.j})(r=function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(){var e;Object(c.a)(this,a);for(var n=arguments.length,r=new Array(n),s=0;s<n;s++)r[s]=arguments[s];return(e=t.call.apply(t,[this].concat(r))).state={removable:0,currentOpenId:0,treasure_stage:0,activity_stage:0,userInfoList:[],userInfo:{},isAppUpdate:!1,showMark:!1,banner:"https://img-public.julyedu.com/Public/Image/3c56a64bc1.jpeg"},e.loginInfo=function(t){e.setState({userInfoList:t},(function(){e.state.userInfoList.length&&(e.props.startFetchUser(),e.appLogin())}))},e.appLogin=function(){var t=Object(D.a)(new Date,90);e.state.userInfoList.forEach((function(e,a){N.a.set("token",e.token,{expires:t,path:"/",domain:".julyedu.com"}),N.a.set("plat",e.plat,{expires:t,path:"/",domain:".julyedu.com"}),N.a.set("uid",e.uid,{expires:t,path:"/",domain:".julyedu.com"}),N.a.set("uname",e.uname,{expires:t,path:"/",domain:".julyedu.com"}),N.a.set("avatar_file",e.avatar_file,{expires:t,path:"/",domain:".julyedu.com"})})),N.a.get("token")&&N.a.get("uid")&&e.setState({isAppUpdate:!0}),e.props.setCurrentUser(e.transformUser(e.state.userInfoList))},e.transformUser=function(e){var t;return e.forEach((function(e,a){t={hasError:!1,data:{username:e.uname,avatar:e.avatar_file,token:e.token,uid:e.uid},isFetching:!1}})),t},e.closePopup=function(){e.setState({showMark:!1})},e.getRemovable=function(e,t){},e.getStage=function(){f.f.get("".concat(API.home,"/activity/stage")).then((function(t){var a=t.data,n=a.code,r=a.data,s=a.msg;if(200===n){if(0===Number(r.treasure_stage))return void e.props.history.push("/");e.setState({activity_stage:r.activity_stage,treasure_stage:r.treasure_stage}),r.activity_stage,e.setState({banner:"https://img-public.julyedu.com/Public/Image/3c56a64bc1.jpeg"})}else o.a.info(s,2)}))},e}return Object(i.a)(a,[{key:"componentDidMount",value:function(){var e=this;window.loginInfo=function(t){e.loginInfo(t)},e.getStage(),document.title="\u0041\u0049\u5145\u7535\u5b63\uff0c\u5f00\u5b9d\u7bb1\u514d\u8d39\u5b66\u6b63\u4ef7\u8bfe\uff0c\u0032\u0030\u0030\u672c\u7eb8\u8d28\u4e66\u7b49\u5305\u90ae\u9001\uff01\u002d\u4e03\u6708\u5728\u7ebf"}},{key:"render",value:function(){var e=this.state,t=e.banner,a=e.activity_stage,n=e.treasure_stage;return p.a.createElement("div",{className:"year-index"},p.a.createElement("div",{className:"banner-treasure"},p.a.createElement("img",{src:t,alt:""})),1===n&&p.a.createElement(U,{isAppUpdate:this.state.isAppUpdate,getRemovable:this.getRemovable}),p.a.createElement(j,{stage:a,treasureStage:n,isAppUpdate:this.state.isAppUpdate}),this.state.showMark&&p.a.createElement(B,{top:50,closePopup:this.closePopup,mark:!0},p.a.createElement("div",{className:"sub__code_container"},p.a.createElement("p",{className:"sub__title"},"\u63d0\u9192\u670d\u52a1"),p.a.createElement("p",{className:"sub__tip"},"\u6709\u597d\u53cb\u52a0\u5165\u961f\u4f0d\u540e\u7b2c\u4e00\u65f6\u95f4\u901a\u77e5\u6211~"),p.a.createElement("img",{className:"sub__qr_code",id:"live-qr-code",src:"//cdn.julyedu.com/2018christyear/h5/qrcode.jpg",alt:""}),p.a.createElement("p",{className:"sub__tip"},"\u957f\u6309\u8bc6\u522b/\u626b\u7801 \u5173\u6ce8\u3010\u4e03\u6708\u5728\u7ebf\u3011\u670d\u52a1\u53f7\u5373\u53ef\u9884\u7ea6"))),this.state.showMark&&p.a.createElement(B,{top:50,closePopup:this.closePopup,mark:!0},p.a.createElement("div",{className:"sub__code_container"},p.a.createElement("p",{className:"sub__title"},"\u7ec4\u961f\u5f00\u5b9d\u7bb1\u6d3b\u52a8\u89c4\u5219"),p.a.createElement("p",{className:"sub__rule"},"1. \u6d3b\u52a8\u671f\u95f4\uff083\u670826\u65e5-3\u670831\u65e5\uff09\u53ef\u968f\u65f6\u53c2\u4e0e\u5f00\u5b9d\u7bb1\uff1b",p.a.createElement("br",null),"2. \u5f53\u524d\u961f\u4f0d\u6ee1\u5458\u540e\u53ef\u7ee7\u7eed\u521b\u5efa\u65b0\u961f\u4f0d\uff1b",p.a.createElement("br",null),"3. \u6bcf\u4eba\u6709\u4e00\u6b21\u673a\u4f1a\u52a0\u5165\u597d\u53cb\u7684\u961f\u4f0d\uff1b",p.a.createElement("br",null),"4. \u961f\u4f0d\u6ee1\u5458\u540e\u6240\u6709\u6210\u5458\u5747\u53ef\u968f\u673a\u83b7\u5f97\u5b9d\u7bb1\u5185\u5956\u54c1\uff0c\u961f\u957f\u5956\u52b1\u66f4\u4e30\u539a\u54e6~",p.a.createElement("br",null),"5. \u4ee3\u91d1\u5238\u3001\u8bfe\u7a0b\u7b49\u865a\u62df\u5956\u54c1\u5c06\u76f4\u63a5\u53d1\u653e\u81f3\u8d26\u6237\uff0c\u5b9e\u7269\u5956\u54c1\u6d3b\u52a8\u7ed3\u675f\u540e\u7edf\u4e00\u90ae\u5bc4\uff1b",p.a.createElement("br",null),"6. \u73b0\u91d1\u53ef\u63d0\u73b0\uff1a\u6211\u7684 \u2192 \u8d5a\u5956\u5b66\u91d1 \u2192 \u63d0\u73b0\u3002"))),p.a.createElement("div",{className:"btm-rule"},"* \u672c\u6d3b\u52a8\u89e3\u91ca\u6743\u5f52\u5317\u4eac\u4e03\u6708\u5728\u7ebf\u79d1\u6280\u6709\u9650\u516c\u53f8\u6240\u6709 *"))}}]),a}(m.Component))||r;t.default=R}}]); (this["webpackJsonpmr-julyedu"]=this["webpackJsonpmr-julyedu"]||[]).push([[46],{1071:function(e,t,a){},1072:function(e,t,a){},1073:function(e,t,a){},1074:function(e,t,a){},1075:function(e,t,a){},1076:function(e,t,a){},1077:function(e,t,a){},1078:function(e,t,a){},1188:function(e,t,a){"use strict";a.r(t);a(36);var n,r,s=a(10),o=a.n(s),c=a(3),i=a(5),l=a(6),u=a(7),m=a(0),p=a.n(m),d=(a(1071),a(4)),h=a(58),f=(a(1072),a(1)),g=a(28),v=a(419),b=a.n(v),y=a(20),_=Object(y.b)((function(e){return{user:e.user}}))(n=function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(e){var n;return Object(c.a)(this,a),(n=t.call(this,e)).getLength=function(){var e=Object(h.a)(n);f.f.get("".concat(API.home,"/activity/wish_sum")).then((function(t){var a=t.data,n=a.code,r=a.data;200==n&&e.setState({sum:r.sum})}))},n.fetchBigCourse=function(){var e=n.state.bigcourse;f.f.get("".concat(API.home,"/activity/preheat_data")).then((function(t){var a=t.data,r=a.code,s=a.data;200===r&&n.setState({bigcourse:Object.assign({},e,{isMore:!1,course:s,courseList:s})})}))},n.fetchFreeCourse=function(){var e=n.state.freecourse;f.f.get("".concat(API["base-api"],"/assistance/detail")).then((function(t){var a=t.data,r=a.errno,s=a.data;200===r&&n.setState({freecourse:Object.assign({},e,{isMore:s.course_info.length>4,course:s.course_info.length>4?s.course_info.filter((function(e,t){return t<4})):s.course_info,courseList:s.course_info})})}))},n.fetchGroupCourse=function(){var e=n.state.groupcourse;f.f.get("".concat(API.home,"/activity/excellent_course")).then((function(t){var a=t.data,r=a.code,s=a.data;200===r&&n.setState({groupcourse:Object.assign({},e,{isMore:s.length>4,course:s.length>4?s.filter((function(e,t){return t<4})):s,courseList:s})})}))},n.fetchAICourse=function(e,t){f.f.get("".concat(API.home,"/activity/four_stage/").concat(e)).then((function(a){var r=a.data,s=r.code,o=r.data;200===s&&n.getList(e,o,t)}))},n.getList=function(e,t,a){var r=n.state,s=r.basic,o=r.advanced,c=r.higher,i=r.expand;"one"===e&&n.setState({basic:Object.assign({},s,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})}),"two"===e&&n.setState({advanced:Object.assign({},o,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})}),"three"===e&&n.setState({higher:Object.assign({},c,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})}),"four"===e&&n.setState({expand:Object.assign({},i,{isMore:t.length>4&&!a,course:t.length>4&&!a?t.filter((function(e,t){return t<4})):t,courseList:t,addshowMore:a})})},n.toQQque=function(){Object(f.c)("version")?Object(f.a)("toQQ","https://q.url.cn/AB8aue?_type=wpa&qidian=true"):window.location.href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"},n.toCourse=function(e){var t=n.props.history;Object(f.c)("version")?Object(f.a)("toCourse",e):t.push("/detail?id=".concat(e))},n.handleToMore=function(e){var t={};n.state[e].isMore?(t[e]={isMore:!n.state[e].isMore,course:n.state[e].courseList,courseList:n.state[e].courseList,addshowMore:!n.state[e].addshowMore},n.setState(Object(d.a)({},t))):(t[e]={isMore:!n.state[e].isMore,course:n.state[e].courseList.filter((function(e,t){return t<4})),courseList:n.state[e].courseList,addshowMore:!n.state[e].addshowMore},n.setState(Object(d.a)({},t)))},n.toLogin=function(){Object(f.c)("version")?Object(f.a)("toLogin"):n.props.history.push("/passport/login")},n.freeStudy=function(){n.setState({tofreeStudy:!0})},n.closePopup=function(){n.setState({tofreeStudy:!1})},n.closePopupWish=function(){var e=Object(h.a)(n);e.setState({isshowFollow:!1}),setTimeout((function(){e.toJoinList(e.state.wish.id,e.state.wish.key)}),200)},n.getQRcodeUrl=function(){var e=Object(h.a)(n);f.f.get("".concat(API["base-api"],"/wx/user_temporary_qrcode/").concat(e.props.user.data.uid)).then((function(e){var t=e.data,a=t.errno,r=t.data,s=t.msg;0==a?(n.setState({qrUrl:r.url}),b.a.toDataURL(r.url,(function(e,t){n.setState({followBarcode:t})}))):o.a.info(s,2)}))},n.addWishList=function(e,t){var a=Object(h.a)(n),r=!n.props.user.hasError;a.setState({wish:{id:e,key:t}}),r?a.isFollow(e,t):a.toLogin()},n.isFollow=function(e,t){var a=Object(h.a)(n);f.f.get("".concat(API.home,"/sys/user/isFollowWeChat")).then((function(n){var r=n.data,s=r.code,c=r.data,i=r.msg;200===s?(a.setState({isshowFollow:!c.is_follow}),a.state.isshowFollow?a.getQRcodeUrl():a.toJoinList(e,t)):o.a.info(i,2)}))},n.toJoinList=function(e,t){var a=Object(h.a)(n);f.f.post("".concat(API.home,"/activity/join_list"),{course_id:e}).then((function(e){var n=e.data,r=n.code,s=n.msg;200==r?(o.a.success("\u5df2\u6210\u529f\u52a0\u5165\u5fc3\u613f\u5355",3),a.getLength(),"1"===t&&a.fetchAICourse("one",a.state.basic.addshowMore),"2"===t&&a.fetchAICourse("two",a.state.advanced.addshowMore),"3"===t&&a.fetchAICourse("three",a.state.higher.addshowMore),"4"===t&&a.fetchAICourse("four",a.state.expand.addshowMore),"group"===t&&a.fetchGroupCourse()):o.a.info(s,2)}))},n.saveImage=function(){var e=Object(f.c)("version");e="string"===typeof e?e.replace(".","").replace(".","").slice(0,3):"";var t=n.state.qrUrl;e&&parseInt(e)<451?o.a.info("\u5f53\u524d\u4e0d\u652f\u6301\u6b64\u529f\u80fd\uff0c\u5347\u7ea7\u5230\u6700\u65b0\u7248\u672capp\u53ef\u4ee5\u70b9\u51fb\u4fdd\u5b58\u4e8c\u7ef4\u7801\uff01",3,null,!1):Object(f.a)("generateQRCode",t)},n.saveImage2=function(){var e=Object(f.c)("version");(e="string"===typeof e?e.replace(".","").replace(".","").slice(0,3):"")&&parseInt(e)<451?o.a.info("\u5f53\u524d\u4e0d\u652f\u6301\u6b64\u529f\u80fd\uff0c\u5347\u7ea7\u5230\u6700\u65b0\u7248\u672capp\u53ef\u4ee5\u70b9\u51fb\u4fdd\u5b58\u4e8c\u7ef4\u7801\uff01",3,null,!1):Object(f.a)("saveImage","https://cdn.julyedu.com/2018christyear/h5/qrcode.jpg")},n.getTeamInfo=function(){f.f.get("".concat(API.home,"/sys/treasure/teamInfo")).then((function(e){var t=e.data,a=t.code,r=t.data,s=t.msg;if(200===a){var c=r.info,i=r.removable_data;n.setState({removable:c.removable,currentId:c.removable>0?i[0].id:null})}else o.a.info(s)}))},n.toBoxList=function(){var e=!n.props.user.hasError,t=n.state.currentId,a="";t&&(a="?id=".concat(t)),e?Object(f.c)("version")?n.props.history.push("/box/yearTreasure".concat(a,"?version=").concat(Object(f.c)("version"))):n.props.history.push("/box/yearTreasure".concat(a)):n.toLogin()},n.toYearWish=function(){!n.props.user.hasError?Object(f.c)("version")?n.props.history.push("/year/yearWish?version=".concat(Object(f.c)("version"))):n.props.history.push("/year/yearWish"):n.toLogin()},n.toInviteFriends=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=n.props.history;if(Object(f.c)("version")){var r={title:"\u3010\u4ec5\u5269".concat(t.number,"\u4e2a\u540d\u989d\u3011\u6211").concat(t.price,"\u5143\u62fc\u4e86\u300a").concat(t.course_title,"\u300b"),desc:t.course_title,link:"".concat(API.m,"/togroup?id=").concat(e,"&is_originator=1"),imgUrl:t.image_name};Object(f.a)("toShare",r)}else a.push("/togroup?id=".concat(e))},n.isCountDown=function(e,t){return e?t:""},n.formatTitleAndKey=function(e){var t=null;switch(e){case 1:t={title:"\u57fa\u7840",key:"basic"};break;case 2:t={title:"\u8fdb\u9636",key:"advanced"};break;case 3:t={title:"\u9ad8\u9636",key:"higher"};break;case 4:t={title:"\u6269\u5c55",key:"expand"};break;default:t=null}return t},n.formatCourseData=function(e){var t=n.state,a=t.basic,r=t.advanced,s=t.higher,o=t.expand,c=null;switch(e){case 1:c=a;break;case 2:c=r;break;case 3:c=s;break;case 4:c=o;break;default:c=null}return c},n.toCart=function(e){var t=n.props.history;f.f.post("".concat(API.home,"/m/cart/add"),{course_id:e}).then((function(e){var a=e.data,r=a.code,s=a.msg;200===r||15001===r?Object(f.c)("version")?Object(f.a)("toShoppingCart"):t.push("/shopcart"):4030===r||4040===r?n.toLogin():o.a.info(s,2)}))},n.toContinueBargain=function(e,t,a,r){var s=n.props.history;if(Object(f.c)("version")){var o={title:"\u6211\u53d1\u73b0\u4e00\u95e8\u597d\u8bfe\uff0c\u5feb\u6765\u5e2e\u6211\u780d\u4ef7\u5427\uff01",desc:"\u6211\u5df2\u7ecf\u780d\u4e86".concat(t,"\u5143\uff0c\u770b\u770b\u4f60\u80fd\u780d\u591a\u5c11"),link:"".concat(API.m,"/bargain-middle-page?id=").concat(e,"&bargaincode=").concat(a,"&is_originator=1"),imgUrl:r};Object(f.a)("toShare",o)}else s.push("/bargain-middle-page?id=".concat(e,"&bargaincode=").concat(a,"&is_originator=1"))},n.bargainToOrder=function(e){var t=n.props,a=t.history;t.user.hasError?n.toLogin():Object(f.c)("version")?Object(f.a)("toPay",e):f.f.get("".concat(API["base-api"],"/m/cart/addtopreorder/[").concat(e,"]")).then((function(t){var n=t.data,r=n.errno,s=n.msg;0===r?a.push("/order?id=[".concat(e,"]"),{bargain:1}):o.a.info(s,2)}))},n.state={tofreeStudy:!1,basic:{course:[],courseList:[],isMore:!1,addshowMore:!1},advanced:{course:[],courseList:[],isMore:!1,addshowMore:!1},higher:{course:[],courseList:[],isMore:!1,addshowMore:!1},expand:{course:[],courseList:[],isMore:!1,addshowMore:!1},bigcourse:{course:[],courseList:[],isMore:!1},freecourse:{course:[],courseList:[],isMore:!1},groupcourse:{course:[],courseList:[],isMore:!1},isshowFollow:!1,wish:{id:"",key:""},followBarcode:"",qrUrl:"",sum:"",removable:"",currentId:""},n}return Object(i.a)(a,[{key:"componentDidMount",value:function(){this.getTeamInfo(),this.getLength(),this.fetchBigCourse(),this.fetchGroupCourse(),this.fetchAICourse("one",!1),this.fetchAICourse("two",!1),this.fetchAICourse("three",!1),this.fetchAICourse("four",!1)}},{key:"shouldComponentUpdate",value:function(e,t,a){return this.props.isAppUpdate===e.isAppUpdate||(this.getTeamInfo(),this.getLength(),this.fetchBigCourse(),this.fetchGroupCourse(),this.fetchAICourse("one"),this.fetchAICourse("two"),this.fetchAICourse("three"),this.fetchAICourse("four"),!1)}},{key:"render",value:function(){var e=this.state.removable;return p.a.createElement("div",{className:"year-index-course"},e>0&&p.a.createElement("div",{className:"nav-right-wish nav-right"},p.a.createElement("span",{onClick:this.toBoxList,className:"nav-right__link"},"\u672a\u5f00\u5b9d\u7bb1",p.a.createElement("i",{className:"nav-right__number"},e))))}}]),a}(m.Component))||n,j=Object(g.g)(_),E=(a(1073),function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(){return Object(c.a)(this,a),t.apply(this,arguments)}return Object(i.a)(a,[{key:"render",value:function(){var e=this.props.id;return p.a.createElement("div",{className:"common_container",id:e},p.a.createElement("div",{className:"container_top"}),p.a.createElement("div",{className:"container_content"},this.props.title&&p.a.createElement("div",{className:"title_container"},p.a.createElement("i",null),p.a.createElement("p",null,this.props.title),p.a.createElement("i",null)),p.a.Children.map(this.props.children,(function(e){return p.a.createElement(p.a.Fragment,null,e)}))),p.a.createElement("div",{className:"container_bottom"}))}}]),a}(m.Component)),k=(a(1074),function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(e){var n;return Object(c.a)(this,a),(n=t.call(this,e)).fetchRankInfo=function(){f.f.get("".concat(API.home,"/sys/treasure/ranking")).then((function(e){var t=e.data,a=t.code,r=t.data;200===a&&"{}"!==JSON.stringify(r)&&(r.length>5?n.setState({rank:r.filter((function(e,t){return t<5})),rankList:r,isMore:!0}):n.setState({rank:r,rankList:r,isMore:!1}))}))},n.switchMoreRank=function(){var e=n.state,t=e.rankList;e.isMore?n.setState({rank:t,isMore:!1}):n.setState({rank:t.filter((function(e,t){return t<5})),isMore:!0})},n.handleToVip=function(e){var t=n.props.history;e&&(Object(f.c)("version")?Object(f.a)("toCourse",e):t.push("/detail?id=".concat(e)))},n.state={rank:[],rankList:[],isMore:!1},n}return Object(i.a)(a,[{key:"componentDidMount",value:function(){this.fetchRankInfo()}},{key:"render",value:function(){var e=this,t=this.state,a=t.rank,n=t.isMore;return p.a.createElement(p.a.Fragment,null,0!==a.length&&p.a.createElement("div",{"data-skip":"rank"},p.a.createElement("div",{className:"rank-title"},p.a.createElement("i",{className:"rank-title__decorate"}),p.a.createElement("h2",{className:"rank-title__txt"},"\u5b9d\u7bb1\u8fbe\u4eba\u699c"),p.a.createElement("i",{className:"rank-title__decorate"})),p.a.createElement("p",{className:"rank-desc"},"\u5b9d\u7bb1\u6570\u91cf\u524d50\u540d\u53ef\u989d\u5916\u83b7\u5f97\u4e00\u4efd\u5956\u54c1\uff0c\u6570\u91cf\u76f8\u540c\u7684\u7528\u65f6\u77ed\u8005\u6392\u540d\u5728\u524d"),p.a.createElement("dl",{className:"rank-header"},p.a.createElement("dd",{className:"rank-column"},"\u6392\u540d"),p.a.createElement("dd",{className:"rank-column"},"\u7528\u6237"),p.a.createElement("dd",{className:"rank-column"},"\u5b9d\u7bb1\u6570\u91cf"),p.a.createElement("dd",{className:"rank-column"},"\u5956\u54c1")),p.a.createElement("div",{className:"rank-body"},a.map((function(t,a){return p.a.createElement("dl",{className:"rank-item",key:a},p.a.createElement("dd",{className:"rank-column"},a<=2?p.a.createElement("span",{className:"rank-column__number","data-num":a}):p.a.createElement("span",null,a+1)),p.a.createElement("dd",{className:"rank-column"},p.a.createElement("span",{className:"rank-column__name"},t.user_name)),p.a.createElement("dd",{className:"rank-column"},p.a.createElement("span",null,t.num)),p.a.createElement("dd",{className:"rank-column"},t.url?p.a.createElement("a",{className:"rank-column__txt",onClick:function(){return e.handleToVip(t.url)}},t.prize_name):p.a.createElement("span",{className:"rank-column__txt"},t.prize_name)))})),p.a.createElement("div",{className:"rank-more",onClick:this.switchMoreRank},p.a.createElement("span",{className:"rank-more__txt"},n?"\u5c55\u5f00":"\u6536\u8d77"),p.a.createElement("i",{className:"rank-more__icon","data-more":n})))))}}]),a}(m.Component)),w=(a(1075),a(24)),O=a(38),N=a.n(O),I=function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(e){var n;return Object(c.a)(this,a),(n=t.call(this,e)).getTeamInfo=function(){f.f.get("".concat(API.home,"/sys/treasure/teamInfo")).then((function(e){var t=e.data,a=t.code,r=t.data,s=t.msg;if(200===a){var c=r.prize_info,i=r.is_my_team,l=r.info,u=r.member,m=r.removable_data,p=r.my_team;n.setState({prize_info:c,is_my_team:i,info:l,member:n.fillTeam(u,i),removable_data:m,my_team:p});var d=null;l.removable>0&&(d=m[0].id),n.props.getRemovable(l.removable,d)}else o.a.info(s)}))},n.toYearTreasure=function(e){if(n.props.user.hasError)n.toLogin();else{var t="";if(e){var a=n.state,r=a.removable_data;if(a.info.removable>0){var s=r[0];t="?id=".concat(s.id)}}Object(f.c)("version")?n.props.history.push("/box/yearTreasure".concat(t,"?version=").concat(Object(f.c)("version"))):n.props.history.push("/box/yearTreasure".concat(t))}},n.toLogin=function(){Object(f.c)("version")?Object(f.a)("toLogin"):n.props.history.push("/passport/login")},n.createTeam=function(){if(n.props.user.hasError)n.toLogin();else{sessionStorage.setItem("showShareTip","1");var e=n.state,t=e.is_my_team,a=e.my_team.treasure_code;t?Object(f.c)("version")?window.location.assign("https://m.julyedu.com/box/landing?origin=1&treasure_code="+a+"&version="+Object(f.c)("version")):window.location.assign("https://m.julyedu.com/box/landing?origin=1&treasure_code="+a):f.f.get("".concat(API.home,"/sys/treasure/createMyTeam")).then((function(e){var t=e.data,a=t.code,n=t.data,r=t.msg;if(200===a){var s=n.treasure_code;Object(f.c)("version")?window.location.assign("https://m.julyedu.com/box/landing?origin=1&treasure_code="+s+"&version="+Object(f.c)("version")):window.location.assign("https://m.julyedu.com/box/landing?origin=1&treasure_code="+s)}else o.a.info(r)}))}},n.fillTeam=function(e,t){var a=e.length;if(n.props.user.hasError)for(var r=0;r<5-a;r++)e.push({head_img:"",user_name:"",nobody:!0});else if(0!==a||t)for(var s=0;s<5-a;s++)e.push({head_img:"",user_name:"",nobody:!0});else{e.push({head_img:N.a.get("avatar_file"),user_name:N.a.get("user_name")});for(var o=0;o<4;o++)e.push({head_img:"",user_name:"",nobody:!0})}return e},n.state={is_my_team:!1,prize_info:[],info:{removable:0,total:0},member:[],removable_data:[],my_team:{}},n}return Object(i.a)(a,[{key:"componentDidMount",value:function(){this.getTeamInfo()}},{key:"shouldComponentUpdate",value:function(e,t,a){return this.props.isAppUpdate===e.isAppUpdate||(this.getTeamInfo(),!1)}},{key:"render",value:function(){var e=this,t=this.state,a=t.prize_info,n=t.is_my_team,r=t.info,s=r.removable,o=r.total,c=t.member,i="",l=0;a.length>0&&(i=a[0].name,l=a[0].stage_no);var u="";return u=0===o?"\u6211\u7684\u5b9d\u7bb1":0===s?"\u5171".concat(o,"\u4e2a\u5b9d\u7bb1"):"\u5171".concat(o,"\u4e2a\u5b9d\u7bb1/").concat(s,"\u4e2a\u672a\u5f00"),p.a.createElement("div",{className:"team_info__container"},p.a.createElement("div",{className:"team__member"},p.a.createElement("ul",{className:"member__list"},c&&c.length>0&&c.map((function(e,t){return p.a.createElement("li",{key:t,className:"member__item"},p.a.createElement("div",{className:"avatar__container"},e.nobody?p.a.createElement("img",{className:"head__image",src:"https://cdn.julyedu.com/newyear20/H5/default-member-avatar.png",alt:""}):p.a.createElement("img",{className:"head__image",src:e.head_img,alt:""}),0===t?p.a.createElement("img",{className:"caption__flag",src:"https://cdn.julyedu.com/newyear20/H5/caption.png",alt:""}):null,p.a.createElement("div",{className:"shadow"})),p.a.createElement("div",{className:"member__join ".concat(e.nobody?"":"join")}))}))),p.a.createElement("div",{className:"box__number"},p.a.createElement("img",{onClick:function(){return e.toYearTreasure(!0)},src:"https://cdn.julyedu.com/newyear20/H5/treasure-box-icon.png",alt:""}),p.a.createElement("p",{onClick:function(){return e.toYearTreasure(!1)},className:"box__text"},u),p.a.createElement("img",{className:"position__arrow",src:"https://cdn.julyedu.com/newyear20/H5/arrow_jinzhan.png",alt:""}),s>0&&p.a.createElement("div",{className:"position__number"},s))),p.a.createElement("div",{onClick:this.createTeam,className:"invite__btn"},n?"\u7ee7\u7eed\u7ec4\u961f":"\u7ec4\u961f\u5f00\u5b9d\u7bb1"),l>0&&i&&p.a.createElement("p",{className:"stage_prize"},"\u7b2c".concat(l,"\u4e2a\u5b9d\u7bb1\u5fc5\u4e2d").concat(i)))}}]),a}(m.Component),S=Object(w.d)(Object(y.b)((function(e){return{user:e.user}}),null),g.g)(I),L=(a(1076),a(25)),C=a(8),M=Object(C.a)((function(){return a.e(44).then(a.bind(null,1135))})),x=function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(){var e;Object(c.a)(this,a);for(var n=arguments.length,r=new Array(n),s=0;s<n;s++)r[s]=arguments[s];return(e=t.call.apply(t,[this].concat(r))).closeIcon="https://cdn.julyedu.com/newyear20/H5/close-btn.png",e.state={prizes:[],notices:[],rule:[],unfoldList:!1},e.getPrizes=function(){f.f.get("".concat(API.home,"/sys/prize_data")).then((function(t){var a=t.data,n=a.code,r=a.data,s=a.msg;200==n?e.setState({prizes:r.prize_data,notices:r.notices,rule:r.rule}):o.a.info(s,2,null,!1)}))},e.showRules=function(){Object(L.h)({title:"\u7ec4\u961f\u5f00\u5b9d\u7bb1\u6d3b\u52a8\u89c4\u5219",className:"landing-treasure-rules",content:p.a.createElement("div",{dangerouslySetInnerHTML:{__html:e.state.rule}}),closeIcon:e.closeIcon})},e.showMore=function(){e.setState((function(t){if(e.state.unfoldList)e.bg.style=e.innerBox.style=e.prizeBox.style="";else{var a=parseFloat(getComputedStyle(e.prizeBox,":before").getPropertyValue("height")),n=parseFloat(getComputedStyle(e.prizeBox,":after").getPropertyValue("height")),r=e.prizeList.scrollHeight,s=a+r-.12458*a-.595*n+n;e.prizeBox.style.height="".concat(s+27,"px"),e.innerBox.style.height="".concat(r,"px"),e.bg.style.height="".concat(r-n+.12458*a+27,"px")}return{unfoldList:!t.unfoldList}}))},e}return Object(i.a)(a,[{key:"componentDidMount",value:function(){this.getPrizes()}},{key:"render",value:function(){var e=this,t=this.props.showSystemNotices,a=this.state.notices;return p.a.createElement(p.a.Fragment,null,t&&a&&a.length?p.a.createElement(M,{bullets:a}):null,p.a.createElement("div",{className:"prizes-box",ref:function(t){return e.prizeBox=t}},p.a.createElement("a",{href:"javascript:;",className:"rule-btn",onClick:this.showRules},"\u6d3b\u52a8\u89c4\u5219 >"," "),p.a.createElement("div",{className:"bg",ref:function(t){return e.bg=t}}),p.a.createElement("div",{className:"inner-box",ref:function(t){return e.innerBox=t}},p.a.createElement("ul",{className:"prize-list",ref:function(t){return e.prizeList=t}},this.state.prizes.map((function(e,t){return p.a.createElement("li",{key:t},e.img_name?p.a.createElement("i",{className:"prize-list__image",style:{backgroundImage:"url(".concat(e.img_name,")")}}):p.a.createElement("i",{className:"prize-list__image"}),0!=e.is_captain&&p.a.createElement("span",{className:"captain top-tag"},"\u961f\u957f\u4e13\u5c5e"),2===e.mode&&p.a.createElement("span",{className:"stage top-tag"},"\u7b2c",e.stage_no,"\u4e2a\u5fc5\u4e2d"),e.grant_max?p.a.createElement("div",{className:"bottom-bar"},p.a.createElement("div",{className:"progress-bar"},p.a.createElement("span",{className:"progress",style:{width:"".concat(e.surplus/e.grant_max*100,"%")}})),p.a.createElement("span",null,"\u9650\u91cf",e.grant_max,"\u4efd")):p.a.createElement("span",{className:"no-limit"},"\u4e0d\u9650\u91cf"))})),p.a.createElement("li",null,p.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/prize-placeholder.png",alt:""})))),p.a.createElement("div",{className:"show-more",onClick:this.showMore},this.state.unfoldList?p.a.createElement("div",null,"\u6536\u8d77",p.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/fold-icon.png",alt:""})):p.a.createElement("div",null,"\u67e5\u770b\u5168\u90e8\u5956\u54c1",p.a.createElement("img",{src:"https://cdn.julyedu.com/newyear20/H5/unfold-icon.png",alt:""})))))}}]),a}(m.Component),A=a(73),P=a(139),z=(a(205),a(1077),function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(){var e;Object(c.a)(this,a);for(var n=arguments.length,r=new Array(n),s=0;s<n;s++)r[s]=arguments[s];return(e=t.call.apply(t,[this].concat(r))).state={bulletScreenData:[]},e.initializeBulletScreen=function(){var t=Object(h.a)(e),a=Object(A.a)(Array(19).keys()),n=!1;e.swiper=new P.a(".swiper-container",{direction:"vertical",allowTouchMove:!1,autoplay:!0,on:{transitionEnd:function(){var e=this;this.slides.length>20&&(this.removeSlide(0),this.autoplay.start()),this.activeIndex!==this.slides.length-1||n||(this.autoplay.stop(),t.getBulletScreenData().then((function(r){n=!0,e.removeSlide(a),e.appendSlide(t.getSlides(r)),setTimeout((function(){e.autoplay.start(),n=!1}))})))}}})},e.getSlides=function(e){return e.map((function(e){return'\n <li class="swiper-slide">\n <img class="avatar" src="'.concat(e.avatar_file,'" alt="">\n <span>').concat(e.user_name," ").concat(e.msg,"</span>\n </li>\n ")}))},e.getBulletScreenData=function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return f.f.get("".concat(API.home,"/sys/barrage_data")).then((function(a){var n=a.data,r=n.data;if(200===n.code){if(!t)return r;e.setState({bulletScreenData:r},(function(){e.initializeBulletScreen()}))}}))},e}return Object(i.a)(a,[{key:"componentDidMount",value:function(){this.getBulletScreenData(!0)}},{key:"componentWillUnmount",value:function(){this.swiper&&this.swiper.destroy()}},{key:"render",value:function(){var e=this.state.bulletScreenData;return p.a.createElement("div",{id:"user-bullet-screen",className:"swiper-container"},p.a.createElement("ul",{className:"swiper-wrapper"},e.length&&e.map((function(e,t){return p.a.createElement("li",{className:"swiper-slide",key:t},p.a.createElement("img",{src:e.avatar_file,alt:"",className:"avatar"}),p.a.createElement("span",null,e.user_name," ",e.msg))}))))}}]),a}(m.Component)),T=function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(){return Object(c.a)(this,a),t.apply(this,arguments)}return Object(i.a)(a,[{key:"render",value:function(){return p.a.createElement(E,{id:"year-treasure",title:"\u7ec4\u961f\u5f00\u5b9d\u7bb1"},p.a.createElement("div",{style:{textAlign:"center",fontSize:"12px",color:"#FFDC1E",marginTop:"10px"}},"\u9080\u8bf7\u597d\u53cb\u7ec4\u961f\u4e00\u8d77\u5f00\u5b9d\u7bb1\uff0c\u6ee15\u4eba\u540e\u5c06\u968f\u673a\u83b7\u5f97\u4ee5\u4e0b\u5956\u54c1~"),p.a.createElement(x,{showSystemNotices:!0}),p.a.createElement(z,null),p.a.createElement(S,{isAppUpdate:this.props.isAppUpdate,getRemovable:this.props.getRemovable}),p.a.createElement(k,{history:this.props.history}))}}]),a}(m.Component),U=Object(g.g)(T),B=(a(1078),function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(){var e;Object(c.a)(this,a);for(var n=arguments.length,r=new Array(n),s=0;s<n;s++)r[s]=arguments[s];return(e=t.call.apply(t,[this].concat(r))).computedStyle=function(){return{top:"".concat(e.props.top,"px"),width:"".concat(e.props.width,"px")}},e.closePopup=function(){e.props.mark&&e.props.closePopup()},e}return Object(i.a)(a,[{key:"render",value:function(){return p.a.createElement("div",{className:"popup__container",onClick:this.closePopup},p.a.createElement("div",{className:"content__container",style:this.computedStyle(),onClick:function(e){e.stopPropagation()}},p.a.createElement("img",{className:"close__btn",onClick:this.props.closePopup,src:"https://cdn.julyedu.com/newyear20/H5/close-btn.png",alt:""}),p.a.Children.map(this.props.children,(function(e){return p.a.createElement(p.a.Fragment,null,e)}))))}}]),a}(m.Component)),F=a(23),D=a(404),R=Object(y.b)((function(e){return{user:e.user}}),{setCurrentUser:F.i,startFetchUser:F.j})(r=function(e){Object(l.a)(a,e);var t=Object(u.a)(a);function a(){var e;Object(c.a)(this,a);for(var n=arguments.length,r=new Array(n),s=0;s<n;s++)r[s]=arguments[s];return(e=t.call.apply(t,[this].concat(r))).state={removable:0,currentOpenId:0,treasure_stage:0,activity_stage:0,userInfoList:[],userInfo:{},isAppUpdate:!1,showMark:!1,banner:"https://img-public.julyedu.com/Public/Image/3c56a64bc1.jpeg"},e.loginInfo=function(t){e.setState({userInfoList:t},(function(){e.state.userInfoList.length&&(e.props.startFetchUser(),e.appLogin())}))},e.appLogin=function(){var t=Object(D.a)(new Date,90);e.state.userInfoList.forEach((function(e,a){N.a.set("token",e.token,{expires:t,path:"/",domain:".julyedu.com"}),N.a.set("plat",e.plat,{expires:t,path:"/",domain:".julyedu.com"}),N.a.set("uid",e.uid,{expires:t,path:"/",domain:".julyedu.com"}),N.a.set("uname",e.uname,{expires:t,path:"/",domain:".julyedu.com"}),N.a.set("avatar_file",e.avatar_file,{expires:t,path:"/",domain:".julyedu.com"})})),N.a.get("token")&&N.a.get("uid")&&e.setState({isAppUpdate:!0}),e.props.setCurrentUser(e.transformUser(e.state.userInfoList))},e.transformUser=function(e){var t;return e.forEach((function(e,a){t={hasError:!1,data:{username:e.uname,avatar:e.avatar_file,token:e.token,uid:e.uid},isFetching:!1}})),t},e.closePopup=function(){e.setState({showMark:!1})},e.getRemovable=function(e,t){},e.getStage=function(){f.f.get("".concat(API.home,"/activity/stage")).then((function(t){var a=t.data,n=a.code,r=a.data,s=a.msg;if(200===n){if(0===Number(r.treasure_stage))return void e.props.history.push("/");e.setState({activity_stage:r.activity_stage,treasure_stage:r.treasure_stage}),r.activity_stage,e.setState({banner:"https://img-public.julyedu.com/Public/Image/3c56a64bc1.jpeg"})}else o.a.info(s,2)}))},e}return Object(i.a)(a,[{key:"componentDidMount",value:function(){var e=this;window.loginInfo=function(t){e.loginInfo(t)},e.getStage(),document.title="\u0041\u0049\u5145\u7535\u5b63\uff0c\u5f00\u5b9d\u7bb1\u514d\u8d39\u5b66\u6b63\u4ef7\u8bfe\uff0c\u0032\u0030\u0030\u672c\u7eb8\u8d28\u4e66\u7b49\u5305\u90ae\u9001\uff01\u002d\u4e03\u6708\u5728\u7ebf"}},{key:"render",value:function(){var e=this.state,t=e.banner,a=e.activity_stage,n=e.treasure_stage;return p.a.createElement("div",{className:"year-index"},p.a.createElement("div",{className:"banner-treasure"},p.a.createElement("img",{src:t,alt:""})),1===n&&p.a.createElement(U,{isAppUpdate:this.state.isAppUpdate,getRemovable:this.getRemovable}),p.a.createElement(j,{stage:a,treasureStage:n,isAppUpdate:this.state.isAppUpdate}),this.state.showMark&&p.a.createElement(B,{top:50,closePopup:this.closePopup,mark:!0},p.a.createElement("div",{className:"sub__code_container"},p.a.createElement("p",{className:"sub__title"},"\u63d0\u9192\u670d\u52a1"),p.a.createElement("p",{className:"sub__tip"},"\u6709\u597d\u53cb\u52a0\u5165\u961f\u4f0d\u540e\u7b2c\u4e00\u65f6\u95f4\u901a\u77e5\u6211~"),p.a.createElement("img",{className:"sub__qr_code",id:"live-qr-code",src:"//cdn.julyedu.com/2018christyear/h5/qrcode.jpg",alt:""}),p.a.createElement("p",{className:"sub__tip"},"\u957f\u6309\u8bc6\u522b/\u626b\u7801 \u5173\u6ce8\u3010\u4e03\u6708\u5728\u7ebf\u3011\u670d\u52a1\u53f7\u5373\u53ef\u9884\u7ea6"))),this.state.showMark&&p.a.createElement(B,{top:50,closePopup:this.closePopup,mark:!0},p.a.createElement("div",{className:"sub__code_container"},p.a.createElement("p",{className:"sub__title"},"\u7ec4\u961f\u5f00\u5b9d\u7bb1\u6d3b\u52a8\u89c4\u5219"),p.a.createElement("p",{className:"sub__rule"},"1. \u6d3b\u52a8\u671f\u95f4\uff083\u670826\u65e5-3\u670831\u65e5\uff09\u53ef\u968f\u65f6\u53c2\u4e0e\u5f00\u5b9d\u7bb1\uff1b",p.a.createElement("br",null),"2. \u5f53\u524d\u961f\u4f0d\u6ee1\u5458\u540e\u53ef\u7ee7\u7eed\u521b\u5efa\u65b0\u961f\u4f0d\uff1b",p.a.createElement("br",null),"3. \u6bcf\u4eba\u6709\u4e00\u6b21\u673a\u4f1a\u52a0\u5165\u597d\u53cb\u7684\u961f\u4f0d\uff1b",p.a.createElement("br",null),"4. \u961f\u4f0d\u6ee1\u5458\u540e\u6240\u6709\u6210\u5458\u5747\u53ef\u968f\u673a\u83b7\u5f97\u5b9d\u7bb1\u5185\u5956\u54c1\uff0c\u961f\u957f\u5956\u52b1\u66f4\u4e30\u539a\u54e6~",p.a.createElement("br",null),"5. \u4ee3\u91d1\u5238\u3001\u8bfe\u7a0b\u7b49\u865a\u62df\u5956\u54c1\u5c06\u76f4\u63a5\u53d1\u653e\u81f3\u8d26\u6237\uff0c\u5b9e\u7269\u5956\u54c1\u6d3b\u52a8\u7ed3\u675f\u540e\u7edf\u4e00\u90ae\u5bc4\uff1b",p.a.createElement("br",null),"6. \u73b0\u91d1\u53ef\u63d0\u73b0\uff1a\u6211\u7684 \u2192 \u8d5a\u5956\u5b66\u91d1 \u2192 \u63d0\u73b0\u3002"))),p.a.createElement("div",{className:"btm-rule"},"* \u672c\u6d3b\u52a8\u89e3\u91ca\u6743\u5f52\u5317\u4eac\u4e03\u6708\u5728\u7ebf\u79d1\u6280\u6709\u9650\u516c\u53f8\u6240\u6709 *"))}}]),a}(m.Component))||r;t.default=R}}]);
//# sourceMappingURL=treasure-box-home.4ca21867.chunk.js.map //# sourceMappingURL=treasure-box-home.4ca21867.chunk.js.map
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -45,17 +45,21 @@ const Module = function CourseList({ module, toDetail }) { ...@@ -45,17 +45,21 @@ const Module = function CourseList({ module, toDetail }) {
return ( return (
<div className="category home-course-list"> <div className="category home-course-list">
{module.name !== "双11秒杀课"?<h2 className="title"> {module.name !== "双11秒杀课" ? (
{module.name} <h2 className="title">{module.name}</h2>
</h2>:(<h2 className="bq"><img className="hot2" src={require('./../image/11.png')} alt=""/></h2>)} ) : (
{module.name === "限时免费" && <span className={"hot"}>hot</span>} <h2 className="bq">
<img className="hot2" src={require("./../image/11.png")} alt="" />
</h2>
)}
{module.name === "限时免费" && <span className={"hot"}>hot</span>}
{module.show_more === 1 && ( {module.show_more === 1 && (
<Link className="more" to="/classify"> <Link className="more" to="/classify">
查看更多 &gt; 查看更多 &gt;
</Link> </Link>
)} )}
{module.show_more === 2 ? ( {module.show_more === 2 ? (
module.name === "限时免费" ? ( module.name === "限时免费" ? (
<Link className="more" to={"/free"}> <Link className="more" to={"/free"}>
...@@ -67,125 +71,130 @@ const Module = function CourseList({ module, toDetail }) { ...@@ -67,125 +71,130 @@ const Module = function CourseList({ module, toDetail }) {
</Link> </Link>
) )
) : null} ) : null}
{module.name==="初级入门课"?( {module.name === "初级入门课" ? (
<ul className="index-course-detail"> <ul className="index-course-detail">
{module.name !== "限时免费" && {module.name !== "限时免费" &&
!isOdd && !isOdd &&
module.list[0].course_img !== module.list[0].course_img_small && ( module.list[0].course_img !== module.list[0].course_img_small && (
<div <div
className="category-vip" className="category-vip"
onClick={() => toDetail(module.list[0].course_id)} onClick={() => toDetail(module.list[0].course_id)}
> >
<img src={module.list[0].course_img} alt="" /> <img src={module.list[0].course_img} alt="" />
</div> </div>
)} )}
{filterList.map((item, index) => { {filterList.map((item, index) => {
const top = item.is_limit_free ? null : ( const top = item.is_limit_free ? null : (
<div> <div>
{item.is_audition === true && ( {item.is_audition === true && (
<span className="audition"> <span className="audition">
<i className={"iconfont iconerji"}></i>试听 <i className={"iconfont iconerji"}></i>试
</span> </span>
)} )}
{item.is_aist && <span className="return_bash"></span>} {item.is_aist && <span className="return_bash"></span>}
</div> </div>
) )
const bottom = <Bottom course={item} course1={module} /> const bottom = <Bottom course={item} course1={module} />
const status = item.is_limit_free ? null : ( const status = item.is_limit_free ? null : (
<div> <div>
{item.is_bargain && ( {item.is_bargain && (
<p className="course-status">砍价减{item.bargain_price}元</p> <p className="course-status">砍价减{item.bargain_price}</p>
)} )}
{item.is_groupon && ( {item.is_groupon && (
<p className="course-status">拼团价{item.groupon_price}元</p> <p className="course-status">拼团价{item.groupon_price}</p>
)} )}
</div> </div>
) )
return ( return (
<Course <Course
key={index} key={index}
top={top} top={top}
data={item} data={item}
bottom={bottom} bottom={bottom}
status={status} status={status}
img={item.course_img_small} img={item.course_img_small}
title={item.course_title} title={item.course_title}
id={item.course_id} id={item.course_id}
toDetail={toDetail} toDetail={toDetail}
className="text-overflow-2" className="text-overflow-2"
/> />
) )
})} })}
<div className="vip"> <div className="vip">
<Link to={"/vip/newvip"}> <Link to={"/vip/newvip"}>
<img src="https://julyedu-img.oss-cn-beijing.aliyuncs.com/huiyuanganggaowei.png" alt=""/> <img
</Link> src="https://julyedu-img.oss-cn-beijing.aliyuncs.com/huiyuanganggaowei.png"
<a href="http://q.url.cn/s/Vbkup6m?_type=wpa" className="consult" target="_blank"> alt=""
<img className="govip" src={require('./../image/kt.png')} alt=""/> />
</a> </Link>
<a
href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
</div> className="consult"
</ul> target="_blank"
):(<ul className="index-course-detail">
{module.name !== "限时免费" &&
!isOdd &&
module.list[0].course_img !== module.list[0].course_img_small && (
<div
className="category-vip"
onClick={() => toDetail(module.list[0].course_id)}
> >
<img src={module.list[0].course_img} alt="" /> <img
</div> className="govip"
)} src={require("./../image/kt.png")}
{filterList.map((item, index) => { alt=""
const top = item.is_limit_free ? null : ( />
<div> </a>
{item.is_audition === true && ( </div>
<span className="audition"> </ul>
<i className={"iconfont iconerji"}></i>试听 ) : (
</span> <ul className="index-course-detail">
)} {module.name !== "限时免费" &&
{item.is_aist && <span className="return_bash"></span>} !isOdd &&
</div> module.list[0].course_img !== module.list[0].course_img_small && (
) <div
className="category-vip"
const bottom = <Bottom course={item} course1={module} /> onClick={() => toDetail(module.list[0].course_id)}
>
const status = item.is_limit_free ? null : ( <img src={module.list[0].course_img} alt="" />
<div> </div>
{item.is_bargain && ( )}
<p className="course-status">砍价减{item.bargain_price}元</p> {filterList.map((item, index) => {
)} const top = item.is_limit_free ? null : (
{item.is_groupon && ( <div>
<p className="course-status">拼团价{item.groupon_price}元</p> {item.is_audition === true && (
)} <span className="audition">
</div> <i className={"iconfont iconerji"}></i>试
) </span>
return ( )}
<Course {item.is_aist && <span className="return_bash"></span>}
key={index} </div>
top={top} )
data={item}
bottom={bottom}
status={status}
img={item.course_img_small}
title={item.course_title}
id={item.course_id}
toDetail={toDetail}
className="text-overflow-2"
/>
)
})}
</ul>
) const bottom = <Bottom course={item} course1={module} />
} const status = item.is_limit_free ? null : (
<div>
{item.is_bargain && (
<p className="course-status">砍价减{item.bargain_price}</p>
)}
{item.is_groupon && (
<p className="course-status">拼团价{item.groupon_price}</p>
)}
</div>
)
return (
<Course
key={index}
top={top}
data={item}
bottom={bottom}
status={status}
img={item.course_img_small}
title={item.course_title}
id={item.course_id}
toDetail={toDetail}
className="text-overflow-2"
/>
)
})}
</ul>
)}
{/* <LazyLoad offset={50}> */} {/* <LazyLoad offset={50}> */}
{/* </LazyLoad> */} {/* </LazyLoad> */}
...@@ -222,7 +231,7 @@ function LimitFree({ course }) { ...@@ -222,7 +231,7 @@ function LimitFree({ course }) {
} }
//课程底部 //课程底部
function Bottom({ course,course1 }) { function Bottom({ course, course1 }) {
if (course.is_buy) { if (course.is_buy) {
if (course.is_limit_free && course.limit_free_status === 1) { if (course.is_limit_free && course.limit_free_status === 1) {
return <div className={"isbuy"}>已领取</div> return <div className={"isbuy"}>已领取</div>
...@@ -235,17 +244,17 @@ function Bottom({ course,course1 }) { ...@@ -235,17 +244,17 @@ function Bottom({ course,course1 }) {
) : ( ) : (
<div> <div>
{course1.name === "1分起购课" ? ( {course1.name === "1分起购课" ? (
<p className="course-price"> <p className="course-price">
<span className="new">特惠价:¥{course.discounts_price}</span> <span className="new">特惠价:¥{course.discounts_price}</span>
<span className="old">¥{course.price}</span> <span className="old">¥{course.price}</span>
</p> </p>
) :<p className="course-price"> ) : (
<span className="new">¥{course.discounts_price}</span> <p className="course-price">
<span className="old">¥{course.price}</span> <span className="new">¥{course.discounts_price}</span>
</p>} <span className="old">¥{course.price}</span>
</p>
)}
</div> </div>
) )
} }
} }
......
...@@ -238,7 +238,7 @@ class Index extends Component { ...@@ -238,7 +238,7 @@ class Index extends Component {
<HomeCourseList modules={this.state.modules} /> <HomeCourseList modules={this.state.modules} />
<TeacherList /> <TeacherList />
<p className="borderTop" /> <p className="borderTop" />
{/* <botton className="fix"><a href="http://q.url.cn/s/Vbkup6m?_type=wpa"><span>点击</span><span>咨询</span></a></botton> */} {/* <botton className="fix"><a href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"><span>点击</span><span>咨询</span></a></botton> */}
<Teaching /> <Teaching />
{/* <AllCourseNavigation /> */} {/* <AllCourseNavigation /> */}
......
...@@ -8,71 +8,76 @@ class TeacherList extends Component { ...@@ -8,71 +8,76 @@ class TeacherList extends Component {
constructor(props) { constructor(props) {
super(props) super(props)
this.state = { this.state = {
data:[], data: [],
active: '', active: "",
isToggleOn: false, isToggleOn: false,
liClass1:'' liClass1: "",
} }
} }
bgChange = index => { bgChange = (index) => {
console.log(index,999) console.log(index, 999)
this.setState({ this.setState({
active: index, active: index,
}); })
this.setState(prevState => ({ this.setState((prevState) => ({
isToggleOn: !prevState.isToggleOn, isToggleOn: !prevState.isToggleOn,
liClass1: prevState.isToggleOn ? '': 'active1' liClass1: prevState.isToggleOn ? "" : "active1",
})); }))
}; }
componentDidMount() { componentDidMount() {
http.get(`${API.home}/m/mobTeachers`).then((res) => { http.get(`${API.home}/m/mobTeachers`).then((res) => {
if (res.data.code === 200) { if (res.data.code === 200) {
this.setState({ this.setState({
data:res.data.data data: res.data.data,
}); })
} else { } else {
Toast.info(res.data.msg, 2) Toast.info(res.data.msg, 2)
} }
}) })
} }
render() { render() {
const { active,liClass1,isToggleOn } = this.state; const { active, liClass1, isToggleOn } = this.state
return ( return (
<div className="teacher"> <div className="teacher">
<p className="cont">超强师资团队</p> <p className="cont">超强师资团队</p>
<div className="teabox"> <div className="teabox">
{this.state.data.map((item, i) => { {this.state.data.map((item, i) => {
const liClass = active === i && isToggleOn? 'active1' : ''; const liClass = active === i && isToggleOn ? "active1" : ""
// const liClass1 = isToggleOn ? 'active1' : ''; // const liClass1 = isToggleOn ? 'active1' : '';
return <div key={i} className={`tealist ${liClass}`} onClick={() => { return (
this.bgChange(i); <div
}}> key={i}
<div className="pic"> className={`tealist ${liClass}`}
<img src={item.thumb_img} alt=""/> onClick={() => {
</div> this.bgChange(i)
<div className="detail"> }}
<h2 className="name"><b>{item.teacher_name}</b></h2> >
<p><span className="title">{item.title}</span></p> <div className="pic">
<p className="desc">{item.desc} </p> <img src={item.thumb_img} alt="" />
</div> </div>
<div className="detail">
<h2 className="name">
<b>{item.teacher_name}</b>
</h2>
<p>
<span className="title">{item.title}</span>
</p>
<p className="desc">{item.desc} </p>
</div>
</div>
)
})}
</div>
<div className="consult">
<a href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372">
咨询更多师资信息
</a>
</div> </div>
})}
</div> </div>
<div className="consult">
<a href="http://q.url.cn/s/Vbkup6m?_type=wpa">咨询更多师资信息</a>
</div>
</div>
) )
} }
} }
export default TeacherList export default TeacherList
...@@ -236,7 +236,8 @@ class YearCourse extends Component { ...@@ -236,7 +236,8 @@ class YearCourse extends Component {
toQQque = () => { toQQque = () => {
if (!getParam("version")) { if (!getParam("version")) {
window.location.href = "http://q.url.cn/s/Vbkup6m?_type=wpa" window.location.href =
"https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
} else { } else {
SendMessageToApp("toQQ", "https://q.url.cn/AB8aue?_type=wpa&qidian=true") SendMessageToApp("toQQ", "https://q.url.cn/AB8aue?_type=wpa&qidian=true")
} }
......
...@@ -233,7 +233,8 @@ class YearCourse extends Component { ...@@ -233,7 +233,8 @@ class YearCourse extends Component {
toQQque = () => { toQQque = () => {
if (!getParam("version")) { if (!getParam("version")) {
window.location.href = "http://q.url.cn/s/Vbkup6m?_type=wpa" window.location.href =
"https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
} else { } else {
SendMessageToApp("toQQ", "https://q.url.cn/AB8aue?_type=wpa&qidian=true") SendMessageToApp("toQQ", "https://q.url.cn/AB8aue?_type=wpa&qidian=true")
} }
......
...@@ -370,7 +370,7 @@ class BtnStatus extends Component { ...@@ -370,7 +370,7 @@ class BtnStatus extends Component {
<div className="btns-box"> <div className="btns-box">
<a <a
className="consult consult-s" className="consult consult-s"
href="http://q.url.cn/s/Vbkup6m?_type=wpa" href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
> >
<i className="iconfont iconerji"></i> <i className="iconfont iconerji"></i>
<span>课程咨询</span> <span>课程咨询</span>
...@@ -402,7 +402,7 @@ class BtnStatus extends Component { ...@@ -402,7 +402,7 @@ class BtnStatus extends Component {
<div className="btns-box"> <div className="btns-box">
<a <a
className="consult consult-m" className="consult consult-m"
href="http://q.url.cn/s/Vbkup6m?_type=wpa" href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
> >
<i className="iconfont iconerji" /> <i className="iconfont iconerji" />
<span>课程咨询</span> <span>课程咨询</span>
...@@ -421,7 +421,7 @@ class BtnStatus extends Component { ...@@ -421,7 +421,7 @@ class BtnStatus extends Component {
<div className="btns-box"> <div className="btns-box">
<a <a
className="consult consult-m" className="consult consult-m"
href="http://q.url.cn/s/Vbkup6m?_type=wpa" href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
> >
<i className="iconfont iconerji" /> <i className="iconfont iconerji" />
<span>课程咨询</span> <span>课程咨询</span>
...@@ -439,7 +439,7 @@ class BtnStatus extends Component { ...@@ -439,7 +439,7 @@ class BtnStatus extends Component {
<div className="btns-box"> <div className="btns-box">
<a <a
className="consult consult-s" className="consult consult-s"
href="http://q.url.cn/s/Vbkup6m?_type=wpa" href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
> >
<i className="iconfont iconerji"></i> <i className="iconfont iconerji"></i>
<span>课程咨询</span> <span>课程咨询</span>
...@@ -461,7 +461,7 @@ class BtnStatus extends Component { ...@@ -461,7 +461,7 @@ class BtnStatus extends Component {
<div className="btns-box"> <div className="btns-box">
<a <a
className="consult consult-s" className="consult consult-s"
href="http://q.url.cn/s/Vbkup6m?_type=wpa" href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
> >
<i className="iconfont iconerji"></i> <i className="iconfont iconerji"></i>
<span>课程咨询</span> <span>课程咨询</span>
...@@ -482,7 +482,7 @@ class BtnStatus extends Component { ...@@ -482,7 +482,7 @@ class BtnStatus extends Component {
<div className="btns-box"> <div className="btns-box">
<a <a
className="consult consult-s" className="consult consult-s"
href="http://q.url.cn/s/Vbkup6m?_type=wpa" href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
> >
<i className="iconfont iconerji"></i> <i className="iconfont iconerji"></i>
<span>课程咨询</span> <span>课程咨询</span>
...@@ -511,7 +511,10 @@ class BtnStatus extends Component { ...@@ -511,7 +511,10 @@ class BtnStatus extends Component {
{/*特殊课程*/} {/*特殊课程*/}
{this.state.isbuy === 20 && ( {this.state.isbuy === 20 && (
<div className="btns-box"> <div className="btns-box">
<a className="consult-l" href="http://q.url.cn/s/Vbkup6m?_type=wpa"> <a
className="consult-l"
href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
>
<i className="iconfont iconerji"></i> <i className="iconfont iconerji"></i>
<span>课程咨询</span> <span>课程咨询</span>
</a> </a>
...@@ -523,7 +526,7 @@ class BtnStatus extends Component { ...@@ -523,7 +526,7 @@ class BtnStatus extends Component {
<div className="btns-box"> <div className="btns-box">
<a <a
className="consult consult-m" className="consult consult-m"
href="http://q.url.cn/s/Vbkup6m?_type=wpa" href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
> >
<i className="iconfont iconerji"></i> <i className="iconfont iconerji"></i>
<span>课程咨询</span> <span>课程咨询</span>
...@@ -542,7 +545,7 @@ class BtnStatus extends Component { ...@@ -542,7 +545,7 @@ class BtnStatus extends Component {
<div className="btns-box"> <div className="btns-box">
<a <a
className="consult consult-m" className="consult consult-m"
href="http://q.url.cn/s/Vbkup6m?_type=wpa" href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
> >
<i className="iconfont iconerji"></i> <i className="iconfont iconerji"></i>
<span>课程咨询</span> <span>课程咨询</span>
...@@ -590,7 +593,7 @@ class BtnStatus extends Component { ...@@ -590,7 +593,7 @@ class BtnStatus extends Component {
<div className="btns-box"> <div className="btns-box">
<a <a
className="consult consult-m" className="consult consult-m"
href="http://q.url.cn/s/Vbkup6m?_type=wpa" href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
> >
<i className="iconfont iconerji"></i> <i className="iconfont iconerji"></i>
<span>课程咨询</span> <span>课程咨询</span>
......
...@@ -288,7 +288,7 @@ class IntelligentRecommend extends Component { ...@@ -288,7 +288,7 @@ class IntelligentRecommend extends Component {
{item.c_type === 2 && ( {item.c_type === 2 && (
<React.Fragment key={item.course_id}> <React.Fragment key={item.course_id}>
<a <a
href="http://q.url.cn/s/Vbkup6m?_type=wpa" href="https://live.easyliao.com/live/chat.do?c=27526&g=53481&config=81372"
className={"contact"} className={"contact"}
onClick={this.consult} onClick={this.consult}
> >
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment