Commit 01a75570 by xuzhenghua

列表页

parent f920ec79
......@@ -6,8 +6,8 @@
"Classify.js": "/mrstatic/js/Classify.d5035e02.chunk.js",
"Classify.js.map": "/mrstatic/js/Classify.d5035e02.chunk.js.map",
"CourseList.css": "/mrstatic/css/CourseList.7b6f3dd7.chunk.css",
"CourseList.js": "/mrstatic/js/CourseList.e70d13fe.chunk.js",
"CourseList.js.map": "/mrstatic/js/CourseList.e70d13fe.chunk.js.map",
"CourseList.js": "/mrstatic/js/CourseList.ec9ad889.chunk.js",
"CourseList.js.map": "/mrstatic/js/CourseList.ec9ad889.chunk.js.map",
"DrawDocument.css": "/mrstatic/css/DrawDocument.aeb3f822.chunk.css",
"DrawDocument.js": "/mrstatic/js/DrawDocument.bd83dd5b.chunk.js",
"DrawDocument.js.map": "/mrstatic/js/DrawDocument.bd83dd5b.chunk.js.map",
......@@ -22,14 +22,14 @@
"Orderinfo.js": "/mrstatic/js/Orderinfo.3d618300.chunk.js",
"Orderinfo.js.map": "/mrstatic/js/Orderinfo.3d618300.chunk.js.map",
"PayOrder.css": "/mrstatic/css/PayOrder.7eb7d317.chunk.css",
"PayOrder.js": "/mrstatic/js/PayOrder.705a733b.chunk.js",
"PayOrder.js.map": "/mrstatic/js/PayOrder.705a733b.chunk.js.map",
"PayOrder.js": "/mrstatic/js/PayOrder.e10c7636.chunk.js",
"PayOrder.js.map": "/mrstatic/js/PayOrder.e10c7636.chunk.js.map",
"Preferential.css": "/mrstatic/css/Preferential.0c91fa43.chunk.css",
"Preferential.js": "/mrstatic/js/Preferential.d58e82ec.chunk.js",
"Preferential.js.map": "/mrstatic/js/Preferential.d58e82ec.chunk.js.map",
"Preferential.js": "/mrstatic/js/Preferential.5121b4cd.chunk.js",
"Preferential.js.map": "/mrstatic/js/Preferential.5121b4cd.chunk.js.map",
"SearchResult.css": "/mrstatic/css/SearchResult.530e102d.chunk.css",
"SearchResult.js": "/mrstatic/js/SearchResult.8111ced7.chunk.js",
"SearchResult.js.map": "/mrstatic/js/SearchResult.8111ced7.chunk.js.map",
"SearchResult.js": "/mrstatic/js/SearchResult.ad5e4be7.chunk.js",
"SearchResult.js.map": "/mrstatic/js/SearchResult.ad5e4be7.chunk.js.map",
"ShopCart.css": "/mrstatic/css/ShopCart.92ab48a3.chunk.css",
"ShopCart.js": "/mrstatic/js/ShopCart.9d4e9063.chunk.js",
"ShopCart.js.map": "/mrstatic/js/ShopCart.9d4e9063.chunk.js.map",
......@@ -40,8 +40,8 @@
"coupons.js": "/mrstatic/js/coupons.7963831a.chunk.js",
"coupons.js.map": "/mrstatic/js/coupons.7963831a.chunk.js.map",
"detail.css": "/mrstatic/css/detail.403c24a0.chunk.css",
"detail.js": "/mrstatic/js/detail.5ae9c154.chunk.js",
"detail.js.map": "/mrstatic/js/detail.5ae9c154.chunk.js.map",
"detail.js": "/mrstatic/js/detail.5b62102e.chunk.js",
"detail.js.map": "/mrstatic/js/detail.5b62102e.chunk.js.map",
"main.css": "/mrstatic/css/main.b81f5cd5.chunk.css",
"main.js": "/mrstatic/js/main.00c8769f.chunk.js",
"main.js.map": "/mrstatic/js/main.00c8769f.chunk.js.map",
......@@ -51,14 +51,14 @@
"purchased.css": "/mrstatic/css/purchased.19e06a3f.chunk.css",
"purchased.js": "/mrstatic/js/purchased.f14435b1.chunk.js",
"purchased.js.map": "/mrstatic/js/purchased.f14435b1.chunk.js.map",
"runtime~main.js": "/mrstatic/js/runtime~main.061e76eb.js",
"runtime~main.js.map": "/mrstatic/js/runtime~main.061e76eb.js.map",
"runtime~main.js": "/mrstatic/js/runtime~main.2f4f03d6.js",
"runtime~main.js.map": "/mrstatic/js/runtime~main.2f4f03d6.js.map",
"search.css": "/mrstatic/css/search.5716d9b3.chunk.css",
"search.js": "/mrstatic/js/search.7f3a3af7.chunk.js",
"search.js.map": "/mrstatic/js/search.7f3a3af7.chunk.js.map",
"search.js": "/mrstatic/js/search.60c14a0a.chunk.js",
"search.js.map": "/mrstatic/js/search.60c14a0a.chunk.js.map",
"shareposter.css": "/mrstatic/css/shareposter.76774ba4.chunk.css",
"shareposter.js": "/mrstatic/js/shareposter.7e2fd9cf.chunk.js",
"shareposter.js.map": "/mrstatic/js/shareposter.7e2fd9cf.chunk.js.map",
"shareposter.js": "/mrstatic/js/shareposter.198e7446.chunk.js",
"shareposter.js.map": "/mrstatic/js/shareposter.198e7446.chunk.js.map",
"study.css": "/mrstatic/css/study.e132441c.chunk.css",
"study.js": "/mrstatic/js/study.a609ff18.chunk.js",
"study.js.map": "/mrstatic/js/study.a609ff18.chunk.js.map",
......@@ -66,11 +66,11 @@
"togroup.js": "/mrstatic/js/togroup.e557ba6a.chunk.js",
"togroup.js.map": "/mrstatic/js/togroup.e557ba6a.chunk.js.map",
"video.css": "/mrstatic/css/video.7340509f.chunk.css",
"video.js": "/mrstatic/js/video.01bef16c.chunk.js",
"video.js.map": "/mrstatic/js/video.01bef16c.chunk.js.map",
"video.js": "/mrstatic/js/video.5e19f2c9.chunk.js",
"video.js.map": "/mrstatic/js/video.5e19f2c9.chunk.js.map",
"mrstatic/css/24.2821b463.chunk.css": "/mrstatic/css/24.2821b463.chunk.css",
"mrstatic/js/24.6f2338ba.chunk.js": "/mrstatic/js/24.6f2338ba.chunk.js",
"mrstatic/js/24.6f2338ba.chunk.js.map": "/mrstatic/js/24.6f2338ba.chunk.js.map",
"mrstatic/js/24.7042820a.chunk.js": "/mrstatic/js/24.7042820a.chunk.js",
"mrstatic/js/24.7042820a.chunk.js.map": "/mrstatic/js/24.7042820a.chunk.js.map",
"mrstatic/js/25.0c961d1b.chunk.js": "/mrstatic/js/25.0c961d1b.chunk.js",
"mrstatic/js/25.0c961d1b.chunk.js.map": "/mrstatic/js/25.0c961d1b.chunk.js.map",
"mrstatic/css/26.c76b300d.chunk.css": "/mrstatic/css/26.c76b300d.chunk.css",
......@@ -79,8 +79,8 @@
"mrstatic/js/27.9672a805.chunk.js": "/mrstatic/js/27.9672a805.chunk.js",
"mrstatic/js/27.9672a805.chunk.js.map": "/mrstatic/js/27.9672a805.chunk.js.map",
"mrstatic/css/28.820320a6.chunk.css": "/mrstatic/css/28.820320a6.chunk.css",
"mrstatic/js/28.fae95c73.chunk.js": "/mrstatic/js/28.fae95c73.chunk.js",
"mrstatic/js/28.fae95c73.chunk.js.map": "/mrstatic/js/28.fae95c73.chunk.js.map",
"mrstatic/js/28.e94852f6.chunk.js": "/mrstatic/js/28.e94852f6.chunk.js",
"mrstatic/js/28.e94852f6.chunk.js.map": "/mrstatic/js/28.e94852f6.chunk.js.map",
"mrstatic/css/29.bf839917.chunk.css": "/mrstatic/css/29.bf839917.chunk.css",
"mrstatic/js/29.54827766.chunk.js": "/mrstatic/js/29.54827766.chunk.js",
"mrstatic/js/29.54827766.chunk.js.map": "/mrstatic/js/29.54827766.chunk.js.map",
......@@ -88,8 +88,8 @@
"mrstatic/js/30.4c875bb5.chunk.js": "/mrstatic/js/30.4c875bb5.chunk.js",
"mrstatic/js/30.4c875bb5.chunk.js.map": "/mrstatic/js/30.4c875bb5.chunk.js.map",
"mrstatic/css/31.8046fb41.chunk.css": "/mrstatic/css/31.8046fb41.chunk.css",
"mrstatic/js/31.8b7987b7.chunk.js": "/mrstatic/js/31.8b7987b7.chunk.js",
"mrstatic/js/31.8b7987b7.chunk.js.map": "/mrstatic/js/31.8b7987b7.chunk.js.map",
"mrstatic/js/31.24d5b59d.chunk.js": "/mrstatic/js/31.24d5b59d.chunk.js",
"mrstatic/js/31.24d5b59d.chunk.js.map": "/mrstatic/js/31.24d5b59d.chunk.js.map",
"index.html": "/index.html",
"mrstatic/css/24.2821b463.chunk.css.map": "/mrstatic/css/24.2821b463.chunk.css.map",
"mrstatic/css/26.c76b300d.chunk.css.map": "/mrstatic/css/26.c76b300d.chunk.css.map",
......@@ -121,6 +121,6 @@
"mrstatic/media/iconfont.css": "/mrstatic/media/iconfont.f983caa7.svg",
"mrstatic/media/kanjia_cg_icon.png": "/mrstatic/media/kanjia_cg_icon.81a489ac.png",
"mrstatic/media/video.scss": "/mrstatic/media/progress-share-bg.80011994.png",
"precache-manifest.e1fbf674e62999fd0f4f14e1903fc35d.js": "/precache-manifest.e1fbf674e62999fd0f4f14e1903fc35d.js",
"precache-manifest.6535e7902e25bed8fb7bf8f739a53bd0.js": "/precache-manifest.6535e7902e25bed8fb7bf8f739a53bd0.js",
"service-worker.js": "/service-worker.js"
}
\ 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.
(window.webpackJsonp=window.webpackJsonp||[]).push([[31],{1148:function(e,t,a){},1168:function(e,t,a){"use strict";a.r(t);a(44);var n=a(14),c=a.n(n),o=a(8),r=a(9),i=a(11),s=a(7),l=a(153),u=a(10),m=a(0),d=a.n(m),p=(a(1148),a(30)),f=a(3),h=function(e){function t(e){var a;return Object(o.a)(this,t),(a=Object(i.a)(this,Object(s.a)(t).call(this,e))).toCourseDetail=function(e){Object(l.a)(a).state.fromApp?Object(f.a)("toCourse",e):a.props.history.push("/detail?id=".concat(e))},a.state={list:[],fromApp:!!Object(f.c)("from")},a}return Object(u.a)(t,e),Object(r.a)(t,[{key:"componentDidMount",value:function(){var e=this;f.d.get("".concat(API.home,"/sys/red_packet/share_course")).then(function(t){200===t.data.code?e.setState({list:t.data.data}):c.a.info(t.data.msg,2)})}},{key:"render",value:function(){var e=this,t=this.state.list;return d.a.createElement("div",{className:"share-course"},!this.state.fromApp&&d.a.createElement(p.e,{title:"\u5206\u4eab\u9886\u7ea2\u5305",arrow:!0}),t&&t.length>0?d.a.createElement("div",null,t.map(function(t,a){var n=d.a.createElement("div",{className:"info"},d.a.createElement("p",{className:"title text-overflow-1"},t.course_title),d.a.createElement("p",{className:"contact text-overflow-1"},t.simpledescription),d.a.createElement("button",null,"\u5206\u4eab\u9886\u7ea2\u5305"));return d.a.createElement("div",{key:a},d.a.createElement(p.j,{img:t.image_name,info:n,id:t.course_id,toDetail:e.toCourseDetail}))})):d.a.createElement("div",null,d.a.createElement("p",{className:"not-data"},"\u6682\u65f6\u6ca1\u6709\u53ef\u5206\u4eab\u7684\u8bfe\u7a0b\u54e6\u301c")))}}]),t}(m.Component);t.default=h}}]);
//# sourceMappingURL=31.24d5b59d.chunk.js.map
\ No newline at end of file
{"version":3,"sources":["components/ShareCourse/index.js"],"names":["ShareCourse","props","_this2","Object","_Users_xzh_dnmp_www_mr_julyedu_node_modules_babel_preset_react_app_node_modules_babel_runtime_helpers_esm_classCallCheck__WEBPACK_IMPORTED_MODULE_2__","this","_Users_xzh_dnmp_www_mr_julyedu_node_modules_babel_preset_react_app_node_modules_babel_runtime_helpers_esm_possibleConstructorReturn__WEBPACK_IMPORTED_MODULE_4__","_Users_xzh_dnmp_www_mr_julyedu_node_modules_babel_preset_react_app_node_modules_babel_runtime_helpers_esm_getPrototypeOf__WEBPACK_IMPORTED_MODULE_5__","call","toCourseDetail","id","_Users_xzh_dnmp_www_mr_julyedu_node_modules_babel_preset_react_app_node_modules_babel_runtime_helpers_esm_assertThisInitialized__WEBPACK_IMPORTED_MODULE_6__","state","fromApp","SendMessageToApp","history","push","concat","list","getParam","_this3","http","get","API","home","then","res","data","code","setState","antd_mobile_lib_toast__WEBPACK_IMPORTED_MODULE_1___default","a","info","msg","_this4","react__WEBPACK_IMPORTED_MODULE_8___default","createElement","className","_common__WEBPACK_IMPORTED_MODULE_10__","title","arrow","length","map","item","index","Info","course_title","simpledescription","key","img","image_name","course_id","toDetail","Component"],"mappings":"4OASMA,cAEF,SAAAA,EAAYC,GAAO,IAAAC,EAAA,OAAAC,OAAAC,EAAA,EAAAD,CAAAE,KAAAL,IACfE,EAAAC,OAAAG,EAAA,EAAAH,CAAAE,KAAAF,OAAAI,EAAA,EAAAJ,CAAAH,GAAAQ,KAAAH,KAAMJ,KAmBVQ,eAAiB,SAACC,GACHP,OAAAQ,EAAA,EAAAR,CAAAD,GACDU,MAAMC,QACZC,YAAiB,WAAYJ,GAEXR,EAAKD,MAAhBc,QACCC,KAAR,cAAAC,OAA2BP,KAxB/BR,EAAKU,MAAQ,CACTM,KAAM,GACNL,UAAUM,YAAS,SAJRjB,mFAQC,IAAAkB,EAAAf,KAChBgB,IAAKC,IAAL,GAAAL,OAAYM,IAAIC,KAAhB,iCAAoDC,KAAK,SAACC,GAChC,MAAlBA,EAAIC,KAAKC,KACTR,EAAKS,SAAS,CACVX,KAAMQ,EAAIC,KAAKA,OAGnBG,EAAAC,EAAMC,KAAKN,EAAIC,KAAKM,IAAK,sCAe5B,IAAAC,EAAA7B,KACEa,EAAQb,KAAKO,MAAbM,KACP,OACIiB,EAAAJ,EAAAK,cAAA,OAAKC,UAAW,iBAEPhC,KAAKO,MAAMC,SACZsB,EAAAJ,EAAAK,cAACE,EAAA,EAAD,CAAWC,MAAM,iCAAQC,OAAO,IAKhCtB,GAAQA,EAAKuB,OAAS,EAAIN,EAAAJ,EAAAK,cAAA,WAEdlB,EAAKwB,IAAI,SAACC,EAAMC,GACZ,IAAMC,EACFV,EAAAJ,EAAAK,cAAA,OAAKC,UAAU,QACXF,EAAAJ,EAAAK,cAAA,KAAGC,UAAW,yBAA0BM,EAAKG,cAC7CX,EAAAJ,EAAAK,cAAA,KAAGC,UAAW,2BAA4BM,EAAKI,mBAC/CZ,EAAAJ,EAAAK,cAAA,iDAGR,OACID,EAAAJ,EAAAK,cAAA,OAAKY,IAAKJ,GACNT,EAAAJ,EAAAK,cAACE,EAAA,EAAD,CACIW,IAAKN,EAAKO,WACVlB,KAAMa,EACNnC,GAAIiC,EAAKQ,UACTC,SAAUlB,EAAKzB,qBAQvC0B,EAAAJ,EAAAK,cAAA,WACID,EAAAJ,EAAAK,cAAA,KAAGC,UAAU,YAAb,qFApEFgB,aA6EXrD","file":"mrstatic/js/31.24d5b59d.chunk.js","sourcesContent":["import React, {Component} from 'react';\nimport './index.scss';\nimport {HeaderBar, VList} from '@/common';\nimport {http, getParam, SendMessageToApp} from '@/utils';\nimport {Toast} from 'antd-mobile';\nimport {Link} from \"react-router-dom\";\n\n// import FollowQRcode from \"../detail/followQRcode\";\n\nclass ShareCourse extends Component {\n\n constructor(props) {\n super(props);\n this.state = {\n list: [],\n fromApp: !getParam('from') ? false : true\n };\n }\n\n componentDidMount() {\n http.get(`${API.home}/sys/red_packet/share_course`).then((res) => {\n if (res.data.code === 200) {\n this.setState({\n list: res.data.data\n })\n } else {\n Toast.info(res.data.msg, 2)\n }\n })\n }\n\n toCourseDetail = (id) => {\n const _this = this\n if (_this.state.fromApp) {\n SendMessageToApp(\"toCourse\", id)\n } else {\n const {history} = this.props;\n history.push(`/detail?id=${id}`)\n }\n }\n\n render() {\n const {list} = this.state;\n return (\n <div className={'share-course'}>\n {\n !this.state.fromApp &&\n <HeaderBar title='分享领红包' arrow={true}/>\n }\n\n {/*<FollowQRcode/>*/}\n {\n list && list.length > 0 ? <div>\n {\n list.map((item, index) => {\n const Info = (\n <div className=\"info\">\n <p className={'title text-overflow-1'}>{item.course_title}</p>\n <p className={'contact text-overflow-1'}>{item.simpledescription}</p>\n <button>分享领红包</button>\n </div>\n )\n return (\n <div key={index}>\n <VList\n img={item.image_name}\n info={Info}\n id={item.course_id}\n toDetail={this.toCourseDetail}\n />\n </div>\n\n )\n })\n }\n </div> :\n <div>\n <p className='not-data'>暂时没有可分享的课程哦〜</p>\n </div>\n }\n\n </div>\n )\n }\n}\n\nexport default ShareCourse;\n"],"sourceRoot":""}
\ No newline at end of file
(window.webpackJsonp=window.webpackJsonp||[]).push([[31],{1148:function(e,t,a){},1168:function(e,t,a){"use strict";a.r(t);a(44);var n=a(14),c=a.n(n),o=a(8),r=a(9),i=a(11),s=a(7),l=a(10),u=a(0),m=a.n(u),d=(a(1148),a(30)),f=a(3),p=function(e){function t(e){var a;return Object(o.a)(this,t),(a=Object(i.a)(this,Object(s.a)(t).call(this,e))).toCourseDetail=function(e){Object(f.c)("from")?Object(f.a)("toCourse",e):a.props.history.push("/detail?id=".concat(e))},a.state={list:[]},a}return Object(l.a)(t,e),Object(r.a)(t,[{key:"componentDidMount",value:function(){var e=this;f.d.get("".concat(API.home,"/sys/red_packet/share_course")).then(function(t){200===t.data.code?e.setState({list:t.data.data}):c.a.info(t.data.msg,2)})}},{key:"render",value:function(){var e=this,t=this.state.list;return m.a.createElement("div",{className:"share-course"},m.a.createElement(d.e,{title:"\u5206\u4eab\u9886\u7ea2\u5305",arrow:!0}),t&&t.length>0?m.a.createElement("div",null,t.map(function(t,a){var n=m.a.createElement("div",{className:"info"},m.a.createElement("p",{className:"title text-overflow-1"},t.course_title),m.a.createElement("p",{className:"contact text-overflow-1"},t.simpledescription),m.a.createElement("button",null,"\u5206\u4eab\u9886\u7ea2\u5305"));return m.a.createElement("div",{key:a,onClick:function(){return e.toCourseDetail(t.course_id)}},m.a.createElement(d.j,{img:t.image_name,info:n}))})):m.a.createElement("div",null,m.a.createElement("p",{className:"not-data"},"\u6682\u65f6\u6ca1\u6709\u53ef\u5206\u4eab\u7684\u8bfe\u7a0b\u54e6\u301c")))}}]),t}(u.Component);t.default=p}}]);
//# sourceMappingURL=31.8b7987b7.chunk.js.map
\ No newline at end of file
{"version":3,"sources":["components/ShareCourse/index.js"],"names":["ShareCourse","props","_this","Object","_Users_xzh_dnmp_www_mr_julyedu_node_modules_babel_preset_react_app_node_modules_babel_runtime_helpers_esm_classCallCheck__WEBPACK_IMPORTED_MODULE_2__","this","_Users_xzh_dnmp_www_mr_julyedu_node_modules_babel_preset_react_app_node_modules_babel_runtime_helpers_esm_possibleConstructorReturn__WEBPACK_IMPORTED_MODULE_4__","_Users_xzh_dnmp_www_mr_julyedu_node_modules_babel_preset_react_app_node_modules_babel_runtime_helpers_esm_getPrototypeOf__WEBPACK_IMPORTED_MODULE_5__","call","toCourseDetail","id","getParam","SendMessageToApp","history","push","concat","state","list","_this2","http","get","API","home","then","res","data","code","setState","antd_mobile_lib_toast__WEBPACK_IMPORTED_MODULE_1___default","a","info","msg","_this3","react__WEBPACK_IMPORTED_MODULE_7___default","createElement","className","_common__WEBPACK_IMPORTED_MODULE_9__","title","arrow","length","map","item","index","Info","course_title","simpledescription","key","onClick","course_id","img","image_name","Component"],"mappings":"mOASMA,cAEF,SAAAA,EAAYC,GAAO,IAAAC,EAAA,OAAAC,OAAAC,EAAA,EAAAD,CAAAE,KAAAL,IACfE,EAAAC,OAAAG,EAAA,EAAAH,CAAAE,KAAAF,OAAAI,EAAA,EAAAJ,CAAAH,GAAAQ,KAAAH,KAAMJ,KAgBVQ,eAAiB,SAACC,GACTC,YAAS,QAIVC,YAAiB,WAAYF,GAHXR,EAAKD,MAAhBY,QACCC,KAAR,cAAAC,OAA2BL,KAlB/BR,EAAKc,MAAQ,CAACC,KAAM,IAFLf,mFAKC,IAAAgB,EAAAb,KAChBc,IAAKC,IAAL,GAAAL,OAAYM,IAAIC,KAAhB,iCAAoDC,KAAK,SAACC,GAChC,MAAlBA,EAAIC,KAAKC,KACTR,EAAKS,SAAS,CACVV,KAAMO,EAAIC,KAAKA,OAGnBG,EAAAC,EAAMC,KAAKN,EAAIC,KAAKM,IAAK,sCAc5B,IAAAC,EAAA3B,KACEY,EAAQZ,KAAKW,MAAbC,KACP,OACIgB,EAAAJ,EAAAK,cAAA,OAAKC,UAAW,gBACZF,EAAAJ,EAAAK,cAACE,EAAA,EAAD,CAAWC,MAAM,iCAAQC,OAAO,IAG5BrB,GAAQA,EAAKsB,OAAS,EAAIN,EAAAJ,EAAAK,cAAA,WAEdjB,EAAKuB,IAAI,SAACC,EAAMC,GACZ,IAAMC,EACFV,EAAAJ,EAAAK,cAAA,OAAKC,UAAU,QACXF,EAAAJ,EAAAK,cAAA,KAAGC,UAAW,yBAA0BM,EAAKG,cAC7CX,EAAAJ,EAAAK,cAAA,KAAGC,UAAW,2BAA4BM,EAAKI,mBAC/CZ,EAAAJ,EAAAK,cAAA,iDAGR,OACID,EAAAJ,EAAAK,cAAA,OAAKY,IAAKJ,EAAOK,QAAS,kBAAMf,EAAKvB,eAAegC,EAAKO,aACrDf,EAAAJ,EAAAK,cAACE,EAAA,EAAD,CACIa,IAAKR,EAAKS,WACVpB,KAAMa,QAQ9BV,EAAAJ,EAAAK,cAAA,WACID,EAAAJ,EAAAK,cAAA,KAAGC,UAAU,YAAb,qFA1DFgB,aAmEXnD","file":"mrstatic/js/31.8b7987b7.chunk.js","sourcesContent":["import React, {Component} from 'react';\nimport './index.scss';\nimport {HeaderBar, VList} from '@/common';\nimport {http, getParam, SendMessageToApp} from '@/utils';\nimport {Toast} from 'antd-mobile';\nimport {Link} from \"react-router-dom\";\n\n// import FollowQRcode from \"../detail/followQRcode\";\n\nclass ShareCourse extends Component {\n\n constructor(props) {\n super(props);\n this.state = {list: []};\n }\n\n componentDidMount() {\n http.get(`${API.home}/sys/red_packet/share_course`).then((res) => {\n if (res.data.code === 200) {\n this.setState({\n list: res.data.data\n })\n } else {\n Toast.info(res.data.msg, 2)\n }\n })\n }\n\n toCourseDetail = (id) => {\n if (!getParam('from')) {\n const {history} = this.props;\n history.push(`/detail?id=${id}`)\n } else {\n SendMessageToApp(\"toCourse\", id)\n }\n }\n\n render() {\n const {list} = this.state;\n return (\n <div className={'share-course'}>\n <HeaderBar title='分享领红包' arrow={true}/>\n {/*<FollowQRcode/>*/}\n {\n list && list.length > 0 ? <div>\n {\n list.map((item, index) => {\n const Info = (\n <div className=\"info\">\n <p className={'title text-overflow-1'}>{item.course_title}</p>\n <p className={'contact text-overflow-1'}>{item.simpledescription}</p>\n <button>分享领红包</button>\n </div>\n )\n return (\n <div key={index} onClick={() => this.toCourseDetail(item.course_id)}>\n <VList\n img={item.image_name}\n info={Info}\n />\n </div>\n\n )\n })\n }\n </div> :\n <div>\n <p className='not-data'>暂时没有可分享的课程哦〜</p>\n </div>\n }\n\n </div>\n )\n }\n}\n\nexport default ShareCourse;\n"],"sourceRoot":""}
\ No newline at end of file
!function(e){function r(r){for(var n,a,i=r[0],u=r[1],d=r[2],f=0,l=[];f<i.length;f++)a=i[f],o[a]&&l.push(o[a][0]),o[a]=0;for(n in u)Object.prototype.hasOwnProperty.call(u,n)&&(e[n]=u[n]);for(s&&s(r);l.length;)l.shift()();return c.push.apply(c,d||[]),t()}function t(){for(var e,r=0;r<c.length;r++){for(var t=c[r],n=!0,a=1;a<t.length;a++){var u=t[a];0!==o[u]&&(n=!1)}n&&(c.splice(r--,1),e=i(i.s=t[0]))}return e}var n={},a={18:0},o={18:0},c=[];function i(r){if(n[r])return n[r].exports;var t=n[r]={i:r,l:!1,exports:{}};return e[r].call(t.exports,t,t.exports,i),t.l=!0,t.exports}i.e=function(e){var r=[];a[e]?r.push(a[e]):0!==a[e]&&{0:1,1:1,2:1,3:1,4:1,6:1,8:1,9:1,10:1,11:1,12:1,13:1,14:1,16:1,17:1,19:1,20:1,21:1,22:1,23:1,26:1,28:1,29:1,30:1,31:1}[e]&&r.push(a[e]=new Promise(function(r,t){for(var n="mrstatic/css/"+({0:"BargainMiddlePage",1:"Classify",2:"CourseList",3:"DrawDocument",4:"Examination",5:"MyEdit",6:"Order",7:"Orderinfo",8:"PayOrder",9:"Preferential",10:"SearchResult",11:"ShopCart",12:"aist-share",13:"coupons",14:"detail",16:"myorders",17:"purchased",19:"search",20:"shareposter",21:"study",22:"togroup",23:"video"}[e]||e)+"."+{0:"417c8635",1:"fb4bedde",2:"7b6f3dd7",3:"aeb3f822",4:"7bb0622b",5:"31d6cfe0",6:"c0945477",7:"31d6cfe0",8:"7eb7d317",9:"0c91fa43",10:"530e102d",11:"92ab48a3",12:"a97e13d0",13:"f2c7a13b",14:"403c24a0",16:"67814bde",17:"19e06a3f",19:"5716d9b3",20:"76774ba4",21:"e132441c",22:"f08bc5f3",23:"7340509f",25:"31d6cfe0",26:"c76b300d",27:"31d6cfe0",28:"820320a6",29:"bf839917",30:"35e22f8c",31:"8046fb41"}[e]+".chunk.css",o=i.p+n,c=document.getElementsByTagName("link"),u=0;u<c.length;u++){var d=(s=c[u]).getAttribute("data-href")||s.getAttribute("href");if("stylesheet"===s.rel&&(d===n||d===o))return r()}var f=document.getElementsByTagName("style");for(u=0;u<f.length;u++){var s;if((d=(s=f[u]).getAttribute("data-href"))===n||d===o)return r()}var l=document.createElement("link");l.rel="stylesheet",l.type="text/css",l.onload=r,l.onerror=function(r){var n=r&&r.target&&r.target.src||o,c=new Error("Loading CSS chunk "+e+" failed.\n("+n+")");c.request=n,delete a[e],l.parentNode.removeChild(l),t(c)},l.href=o,document.getElementsByTagName("head")[0].appendChild(l)}).then(function(){a[e]=0}));var t=o[e];if(0!==t)if(t)r.push(t[2]);else{var n=new Promise(function(r,n){t=o[e]=[r,n]});r.push(t[2]=n);var c,u=document.createElement("script");u.charset="utf-8",u.timeout=120,i.nc&&u.setAttribute("nonce",i.nc),u.src=function(e){return i.p+"mrstatic/js/"+({0:"BargainMiddlePage",1:"Classify",2:"CourseList",3:"DrawDocument",4:"Examination",5:"MyEdit",6:"Order",7:"Orderinfo",8:"PayOrder",9:"Preferential",10:"SearchResult",11:"ShopCart",12:"aist-share",13:"coupons",14:"detail",16:"myorders",17:"purchased",19:"search",20:"shareposter",21:"study",22:"togroup",23:"video"}[e]||e)+"."+{0:"79002a23",1:"d5035e02",2:"e70d13fe",3:"bd83dd5b",4:"3ca410a8",5:"ebf685ac",6:"1b126bcd",7:"3d618300",8:"705a733b",9:"d58e82ec",10:"8111ced7",11:"9d4e9063",12:"a4ce1948",13:"7963831a",14:"5ae9c154",16:"9dcf961c",17:"f14435b1",19:"7f3a3af7",20:"7e2fd9cf",21:"a609ff18",22:"e557ba6a",23:"01bef16c",25:"0c961d1b",26:"65e12106",27:"9672a805",28:"fae95c73",29:"54827766",30:"4c875bb5",31:"8b7987b7"}[e]+".chunk.js"}(e),c=function(r){u.onerror=u.onload=null,clearTimeout(d);var t=o[e];if(0!==t){if(t){var n=r&&("load"===r.type?"missing":r.type),a=r&&r.target&&r.target.src,c=new Error("Loading chunk "+e+" failed.\n("+n+": "+a+")");c.type=n,c.request=a,t[1](c)}o[e]=void 0}};var d=setTimeout(function(){c({type:"timeout",target:u})},12e4);u.onerror=u.onload=c,document.head.appendChild(u)}return Promise.all(r)},i.m=e,i.c=n,i.d=function(e,r,t){i.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:t})},i.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,r){if(1&r&&(e=i(e)),8&r)return e;if(4&r&&"object"===typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(i.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var n in e)i.d(t,n,function(r){return e[r]}.bind(null,n));return t},i.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(r,"a",r),r},i.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},i.p="/",i.oe=function(e){throw console.error(e),e};var u=window.webpackJsonp=window.webpackJsonp||[],d=u.push.bind(u);u.push=r,u=u.slice();for(var f=0;f<u.length;f++)r(u[f]);var s=d;t()}([]);
//# sourceMappingURL=runtime~main.061e76eb.js.map
\ No newline at end of file
!function(e){function r(r){for(var n,a,i=r[0],d=r[1],u=r[2],f=0,l=[];f<i.length;f++)a=i[f],o[a]&&l.push(o[a][0]),o[a]=0;for(n in d)Object.prototype.hasOwnProperty.call(d,n)&&(e[n]=d[n]);for(s&&s(r);l.length;)l.shift()();return c.push.apply(c,u||[]),t()}function t(){for(var e,r=0;r<c.length;r++){for(var t=c[r],n=!0,a=1;a<t.length;a++){var d=t[a];0!==o[d]&&(n=!1)}n&&(c.splice(r--,1),e=i(i.s=t[0]))}return e}var n={},a={18:0},o={18:0},c=[];function i(r){if(n[r])return n[r].exports;var t=n[r]={i:r,l:!1,exports:{}};return e[r].call(t.exports,t,t.exports,i),t.l=!0,t.exports}i.e=function(e){var r=[];a[e]?r.push(a[e]):0!==a[e]&&{0:1,1:1,2:1,3:1,4:1,6:1,8:1,9:1,10:1,11:1,12:1,13:1,14:1,16:1,17:1,19:1,20:1,21:1,22:1,23:1,26:1,28:1,29:1,30:1,31:1}[e]&&r.push(a[e]=new Promise(function(r,t){for(var n="mrstatic/css/"+({0:"BargainMiddlePage",1:"Classify",2:"CourseList",3:"DrawDocument",4:"Examination",5:"MyEdit",6:"Order",7:"Orderinfo",8:"PayOrder",9:"Preferential",10:"SearchResult",11:"ShopCart",12:"aist-share",13:"coupons",14:"detail",16:"myorders",17:"purchased",19:"search",20:"shareposter",21:"study",22:"togroup",23:"video"}[e]||e)+"."+{0:"417c8635",1:"fb4bedde",2:"7b6f3dd7",3:"aeb3f822",4:"7bb0622b",5:"31d6cfe0",6:"c0945477",7:"31d6cfe0",8:"7eb7d317",9:"0c91fa43",10:"530e102d",11:"92ab48a3",12:"a97e13d0",13:"f2c7a13b",14:"403c24a0",16:"67814bde",17:"19e06a3f",19:"5716d9b3",20:"76774ba4",21:"e132441c",22:"f08bc5f3",23:"7340509f",25:"31d6cfe0",26:"c76b300d",27:"31d6cfe0",28:"820320a6",29:"bf839917",30:"35e22f8c",31:"8046fb41"}[e]+".chunk.css",o=i.p+n,c=document.getElementsByTagName("link"),d=0;d<c.length;d++){var u=(s=c[d]).getAttribute("data-href")||s.getAttribute("href");if("stylesheet"===s.rel&&(u===n||u===o))return r()}var f=document.getElementsByTagName("style");for(d=0;d<f.length;d++){var s;if((u=(s=f[d]).getAttribute("data-href"))===n||u===o)return r()}var l=document.createElement("link");l.rel="stylesheet",l.type="text/css",l.onload=r,l.onerror=function(r){var n=r&&r.target&&r.target.src||o,c=new Error("Loading CSS chunk "+e+" failed.\n("+n+")");c.request=n,delete a[e],l.parentNode.removeChild(l),t(c)},l.href=o,document.getElementsByTagName("head")[0].appendChild(l)}).then(function(){a[e]=0}));var t=o[e];if(0!==t)if(t)r.push(t[2]);else{var n=new Promise(function(r,n){t=o[e]=[r,n]});r.push(t[2]=n);var c,d=document.createElement("script");d.charset="utf-8",d.timeout=120,i.nc&&d.setAttribute("nonce",i.nc),d.src=function(e){return i.p+"mrstatic/js/"+({0:"BargainMiddlePage",1:"Classify",2:"CourseList",3:"DrawDocument",4:"Examination",5:"MyEdit",6:"Order",7:"Orderinfo",8:"PayOrder",9:"Preferential",10:"SearchResult",11:"ShopCart",12:"aist-share",13:"coupons",14:"detail",16:"myorders",17:"purchased",19:"search",20:"shareposter",21:"study",22:"togroup",23:"video"}[e]||e)+"."+{0:"79002a23",1:"d5035e02",2:"ec9ad889",3:"bd83dd5b",4:"3ca410a8",5:"ebf685ac",6:"1b126bcd",7:"3d618300",8:"e10c7636",9:"5121b4cd",10:"ad5e4be7",11:"9d4e9063",12:"a4ce1948",13:"7963831a",14:"5b62102e",16:"9dcf961c",17:"f14435b1",19:"60c14a0a",20:"198e7446",21:"a609ff18",22:"e557ba6a",23:"5e19f2c9",25:"0c961d1b",26:"65e12106",27:"9672a805",28:"e94852f6",29:"54827766",30:"4c875bb5",31:"24d5b59d"}[e]+".chunk.js"}(e),c=function(r){d.onerror=d.onload=null,clearTimeout(u);var t=o[e];if(0!==t){if(t){var n=r&&("load"===r.type?"missing":r.type),a=r&&r.target&&r.target.src,c=new Error("Loading chunk "+e+" failed.\n("+n+": "+a+")");c.type=n,c.request=a,t[1](c)}o[e]=void 0}};var u=setTimeout(function(){c({type:"timeout",target:d})},12e4);d.onerror=d.onload=c,document.head.appendChild(d)}return Promise.all(r)},i.m=e,i.c=n,i.d=function(e,r,t){i.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:t})},i.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,r){if(1&r&&(e=i(e)),8&r)return e;if(4&r&&"object"===typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(i.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var n in e)i.d(t,n,function(r){return e[r]}.bind(null,n));return t},i.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(r,"a",r),r},i.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},i.p="/",i.oe=function(e){throw console.error(e),e};var d=window.webpackJsonp=window.webpackJsonp||[],u=d.push.bind(d);d.push=r,d=d.slice();for(var f=0;f<d.length;f++)r(d[f]);var s=u;t()}([]);
//# sourceMappingURL=runtime~main.2f4f03d6.js.map
\ No newline at end of file
......@@ -16,12 +16,12 @@ self.__precacheManifest = [
"url": "/mrstatic/js/Classify.d5035e02.chunk.js"
},
{
"revision": "032b1633c3057b8a1443",
"revision": "6deec7c7772d00bc10e3",
"url": "/mrstatic/css/CourseList.7b6f3dd7.chunk.css"
},
{
"revision": "032b1633c3057b8a1443",
"url": "/mrstatic/js/CourseList.e70d13fe.chunk.js"
"revision": "6deec7c7772d00bc10e3",
"url": "/mrstatic/js/CourseList.ec9ad889.chunk.js"
},
{
"revision": "4e62aa5efb87f1226b98",
......@@ -56,28 +56,28 @@ self.__precacheManifest = [
"url": "/mrstatic/js/Orderinfo.3d618300.chunk.js"
},
{
"revision": "dd92dd5ebbe15d4a69e7",
"revision": "a9477e2b8a5722bf26eb",
"url": "/mrstatic/css/PayOrder.7eb7d317.chunk.css"
},
{
"revision": "dd92dd5ebbe15d4a69e7",
"url": "/mrstatic/js/PayOrder.705a733b.chunk.js"
"revision": "a9477e2b8a5722bf26eb",
"url": "/mrstatic/js/PayOrder.e10c7636.chunk.js"
},
{
"revision": "94c7a445318b0f439d12",
"revision": "eb67c3c66a841d0a8324",
"url": "/mrstatic/css/Preferential.0c91fa43.chunk.css"
},
{
"revision": "94c7a445318b0f439d12",
"url": "/mrstatic/js/Preferential.d58e82ec.chunk.js"
"revision": "eb67c3c66a841d0a8324",
"url": "/mrstatic/js/Preferential.5121b4cd.chunk.js"
},
{
"revision": "8a0fcec9847fac99ccb8",
"revision": "506b0efad90d520c91d7",
"url": "/mrstatic/css/SearchResult.530e102d.chunk.css"
},
{
"revision": "8a0fcec9847fac99ccb8",
"url": "/mrstatic/js/SearchResult.8111ced7.chunk.js"
"revision": "506b0efad90d520c91d7",
"url": "/mrstatic/js/SearchResult.ad5e4be7.chunk.js"
},
{
"revision": "c0acd8d35548d965e8c1",
......@@ -104,12 +104,12 @@ self.__precacheManifest = [
"url": "/mrstatic/js/coupons.7963831a.chunk.js"
},
{
"revision": "56f36b9563923ff55831",
"revision": "f5cda1a7442e52f7f037",
"url": "/mrstatic/css/detail.403c24a0.chunk.css"
},
{
"revision": "56f36b9563923ff55831",
"url": "/mrstatic/js/detail.5ae9c154.chunk.js"
"revision": "f5cda1a7442e52f7f037",
"url": "/mrstatic/js/detail.5b62102e.chunk.js"
},
{
"revision": "087b93894c9bed785ce4",
......@@ -136,24 +136,24 @@ self.__precacheManifest = [
"url": "/mrstatic/js/BargainMiddlePage.79002a23.chunk.js"
},
{
"revision": "90b4062d6f5a02e787e9",
"url": "/mrstatic/js/runtime~main.061e76eb.js"
"revision": "bac31b0bcb47bccd7e58",
"url": "/mrstatic/js/runtime~main.2f4f03d6.js"
},
{
"revision": "1c115c6292ca379c38a4",
"revision": "4117e1c5a9d76ed4db38",
"url": "/mrstatic/css/search.5716d9b3.chunk.css"
},
{
"revision": "1c115c6292ca379c38a4",
"url": "/mrstatic/js/search.7f3a3af7.chunk.js"
"revision": "4117e1c5a9d76ed4db38",
"url": "/mrstatic/js/search.60c14a0a.chunk.js"
},
{
"revision": "cf7a1d885cc3362cdddd",
"revision": "0c4ed56d4f44b9f3e389",
"url": "/mrstatic/css/shareposter.76774ba4.chunk.css"
},
{
"revision": "cf7a1d885cc3362cdddd",
"url": "/mrstatic/js/shareposter.7e2fd9cf.chunk.js"
"revision": "0c4ed56d4f44b9f3e389",
"url": "/mrstatic/js/shareposter.198e7446.chunk.js"
},
{
"revision": "92c1df05209272569ae8",
......@@ -172,20 +172,20 @@ self.__precacheManifest = [
"url": "/mrstatic/js/togroup.e557ba6a.chunk.js"
},
{
"revision": "91bbb7699836bc0e8bc5",
"revision": "9a39c59503ba8a77cd3a",
"url": "/mrstatic/css/video.7340509f.chunk.css"
},
{
"revision": "91bbb7699836bc0e8bc5",
"url": "/mrstatic/js/video.01bef16c.chunk.js"
"revision": "9a39c59503ba8a77cd3a",
"url": "/mrstatic/js/video.5e19f2c9.chunk.js"
},
{
"revision": "80011994e30adf599e5f47fcc81bc06d",
"url": "/mrstatic/media/progress-share-bg.80011994.png"
},
{
"revision": "d3f8cb725695a5f99e44",
"url": "/mrstatic/js/24.6f2338ba.chunk.js"
"revision": "5d1ea90371bb6cc4bddc",
"url": "/mrstatic/js/24.7042820a.chunk.js"
},
{
"revision": "7550c068f39d13bae44f",
......@@ -208,8 +208,8 @@ self.__precacheManifest = [
"url": "/mrstatic/media/iconfont.f983caa7.svg"
},
{
"revision": "71961c42e5b061f64afa",
"url": "/mrstatic/js/28.fae95c73.chunk.js"
"revision": "1e68dd60170eb7b69746",
"url": "/mrstatic/js/28.e94852f6.chunk.js"
},
{
"revision": "145742789ab409c81f28938b15b5dee7",
......@@ -232,11 +232,11 @@ self.__precacheManifest = [
"url": "/mrstatic/media/iconfont.7b542c77.woff"
},
{
"revision": "e8dd09eec0205c7ac04b",
"url": "/mrstatic/js/31.8b7987b7.chunk.js"
"revision": "64028f6897da2d53bd2f",
"url": "/mrstatic/js/31.24d5b59d.chunk.js"
},
{
"revision": "e8dd09eec0205c7ac04b",
"revision": "64028f6897da2d53bd2f",
"url": "/mrstatic/css/31.8046fb41.chunk.css"
},
{
......@@ -248,7 +248,7 @@ self.__precacheManifest = [
"url": "/mrstatic/css/29.bf839917.chunk.css"
},
{
"revision": "71961c42e5b061f64afa",
"revision": "1e68dd60170eb7b69746",
"url": "/mrstatic/css/28.820320a6.chunk.css"
},
{
......@@ -256,11 +256,11 @@ self.__precacheManifest = [
"url": "/mrstatic/css/26.c76b300d.chunk.css"
},
{
"revision": "d3f8cb725695a5f99e44",
"revision": "5d1ea90371bb6cc4bddc",
"url": "/mrstatic/css/24.2821b463.chunk.css"
},
{
"revision": "90c5b1f195c8867aec4a038da8b549fe",
"revision": "d25a757368702be7e114771f33e79f7c",
"url": "/index.html"
}
];
\ No newline at end of file
......@@ -14,7 +14,7 @@
importScripts("https://storage.googleapis.com/workbox-cdn/releases/3.6.3/workbox-sw.js");
importScripts(
"/precache-manifest.e1fbf674e62999fd0f4f14e1903fc35d.js"
"/precache-manifest.6535e7902e25bed8fb7bf8f739a53bd0.js"
);
workbox.clientsClaim();
......
......@@ -11,7 +11,10 @@ class ShareCourse extends Component {
constructor(props) {
super(props);
this.state = {list: []};
this.state = {
list: [],
fromApp: !getParam('from') ? false : true
};
}
componentDidMount() {
......@@ -27,11 +30,12 @@ class ShareCourse extends Component {
}
toCourseDetail = (id) => {
if (!getParam('from')) {
const _this = this
if (_this.state.fromApp) {
SendMessageToApp("toCourse", id)
} else {
const {history} = this.props;
history.push(`/detail?id=${id}`)
} else {
SendMessageToApp("toCourse", id)
}
}
......@@ -39,7 +43,11 @@ class ShareCourse extends Component {
const {list} = this.state;
return (
<div className={'share-course'}>
<HeaderBar title='分享领红包' arrow={true}/>
{
!this.state.fromApp &&
<HeaderBar title='分享领红包' arrow={true}/>
}
{/*<FollowQRcode/>*/}
{
list && list.length > 0 ? <div>
......@@ -53,10 +61,12 @@ class ShareCourse extends Component {
</div>
)
return (
<div key={index} onClick={() => this.toCourseDetail(item.course_id)}>
<div key={index}>
<VList
img={item.image_name}
info={Info}
id={item.course_id}
toDetail={this.toCourseDetail}
/>
</div>
......
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