Commit e69324c9 by FE

app version modify

parent 0741897c
......@@ -99,10 +99,10 @@
"purchased.js": "/mrstatic/js/purchased.89577d91.chunk.js",
"purchased.js.map": "/mrstatic/js/purchased.89577d91.chunk.js.map",
"python-class.css": "/mrstatic/css/python-class.13b5b2f3.chunk.css",
"python-class.js": "/mrstatic/js/python-class.ff74df37.chunk.js",
"python-class.js.map": "/mrstatic/js/python-class.ff74df37.chunk.js.map",
"runtime~main.js": "/mrstatic/js/runtime~main.d99ce630.js",
"runtime~main.js.map": "/mrstatic/js/runtime~main.d99ce630.js.map",
"python-class.js": "/mrstatic/js/python-class.d1077304.chunk.js",
"python-class.js.map": "/mrstatic/js/python-class.d1077304.chunk.js.map",
"runtime~main.js": "/mrstatic/js/runtime~main.d0d514a3.js",
"runtime~main.js.map": "/mrstatic/js/runtime~main.d0d514a3.js.map",
"search.css": "/mrstatic/css/search.efa1dd44.chunk.css",
"search.js": "/mrstatic/js/search.bbed24b1.chunk.js",
"search.js.map": "/mrstatic/js/search.bbed24b1.chunk.js.map",
......@@ -200,6 +200,6 @@
"mrstatic/media/iconfont.css": "/mrstatic/media/iconfont.e0655d4d.woff",
"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.272af44efc8067082649b107243e89db.js": "/precache-manifest.272af44efc8067082649b107243e89db.js",
"precache-manifest.ad8f48c5df5c49385f322500599b86e2.js": "/precache-manifest.ad8f48c5df5c49385f322500599b86e2.js",
"service-worker.js": "/service-worker.js"
}
\ No newline at end of file
......@@ -260,16 +260,16 @@ self.__precacheManifest = [
"url": "/mrstatic/js/purchased.89577d91.chunk.js"
},
{
"revision": "b87ab22feb35c51dbfb6",
"revision": "c21ae776e8b7956aab5d",
"url": "/mrstatic/css/python-class.13b5b2f3.chunk.css"
},
{
"revision": "b87ab22feb35c51dbfb6",
"url": "/mrstatic/js/python-class.ff74df37.chunk.js"
"revision": "c21ae776e8b7956aab5d",
"url": "/mrstatic/js/python-class.d1077304.chunk.js"
},
{
"revision": "40ac079c823709069198",
"url": "/mrstatic/js/runtime~main.d99ce630.js"
"revision": "e125c6b1319f891608df",
"url": "/mrstatic/js/runtime~main.d0d514a3.js"
},
{
"revision": "dc607b2ee118c7ff1ac5",
......@@ -416,23 +416,23 @@ self.__precacheManifest = [
"url": "/mrstatic/media/progress-share-bg.80011994.png"
},
{
"revision": "c79abf5cb7ae8a82009cf68fe44d1078",
"url": "/mrstatic/media/redb_money_bj@2x.c79abf5c.png"
},
{
"revision": "6902434f8f18a23319d57d0ac8aaea8c",
"url": "/mrstatic/media/redb_sp_bj@2x.6902434f.png"
},
{
"revision": "79139f6aad350256e151f9f73c226348",
"url": "/mrstatic/media/hb_bj.79139f6a.png"
},
{
"revision": "8edaf2ff2566ed17e2dd22cf4f8ad7ae",
"url": "/mrstatic/media/redb_chai_bj@2x.8edaf2ff.png"
},
{
"revision": "79139f6aad350256e151f9f73c226348",
"url": "/mrstatic/media/hb_bj.79139f6a.png"
"revision": "c79abf5cb7ae8a82009cf68fe44d1078",
"url": "/mrstatic/media/redb_money_bj@2x.c79abf5c.png"
},
{
"revision": "4b747ce648a44d1947f96e34a701a1d4",
"revision": "9c5175ea41cda976f0b2515eb2b71c06",
"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.272af44efc8067082649b107243e89db.js"
"/precache-manifest.ad8f48c5df5c49385f322500599b86e2.js"
);
workbox.clientsClaim();
......
......@@ -62,7 +62,6 @@ class Python extends Component {
isAppUpdate: true
})
}
alert(`uid = ${cookie.get("uid")}`);
this.props.setCurrentUser(this.transformUser(this.state.userInfoList))
}
......@@ -94,21 +93,12 @@ class Python extends Component {
let version = getParam('version')
if(version) {
version = version.replace(/\./g, '').slice(0, 3)
alert(version);
if(browser.isAndroidApp && version < 453) { // 安卓的低版本
alert('低版本');
this.setState({
backwardVersion: true,
isPay: 0,
})
}else{
alert('高版本');
this.setState({
backwardVersion: false,
isPay: data.course_info.is_pay
})
}
if(browser.isIOSApp && version < 380) { // ISO的低版本
}else if(browser.isIOSApp && version < 380) { // ISO的低版本
this.setState({
backwardVersion: true,
isPay: 0,
......@@ -131,20 +121,17 @@ class Python extends Component {
render() {
const {isPay, isAppUpdate, backwardVersion} = this.state;
alert(isPay)
// 旧版本 无论购买未购买 都跳转到 未购买的详情页; 如果是已购买就提示更新APP
return (
<div>
{
// isPay === 0 && <PythonDes history={this.props.history} isAppUpdate={isAppUpdate} backwardVersion={backwardVersion} isPay={isPay}></PythonDes>
isPay === 0 && (
<div>
<div>为什么需要这么做</div>
<PythonDes
history={this.props.history}
isAppUpdate={isAppUpdate}
/>
</div>
<PythonDes
backwardVersion={backwardVersion}
history={this.props.history}
isAppUpdate={isAppUpdate}
isPay={isPay}
/>
)
}
{
......
......@@ -121,7 +121,7 @@ class PythonDes extends Component {
}
toLearn = () => {
const {backwardVersion, isPay} = this.props;
const {backwardVersion} = this.props;
http.post(`${API['home']}/m/it/user/trialCourse`, {course_id: getParam('id')}).then((res) => {
const {code, msg} = res.data
if (code == 200) {
......@@ -149,7 +149,7 @@ class PythonDes extends Component {
}
toDetail = () => {
const {backwardVersion, isPay} = this.props;
const {backwardVersion} = this.props;
const id = getParam('id')
if (!getParam('version')) { // H5
http.get(`${API['base-api']}/m/cart/addtopreorder/[${id}]`).then((res) => {
......
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