Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mr-julyedu
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
baiguangyao
mr-julyedu
Commits
2057bf98
Commit
2057bf98
authored
Aug 28, 2020
by
zhanghaozhe
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
视频安全问题
parent
4eb766ab
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
41 changed files
with
69 additions
and
160 deletions
+69
-160
package.json
+1
-1
src/common/WxLogin/index.js
+0
-4
src/components/Index/liveRoom.js
+1
-1
src/components/activity/2020-717/question/index.js
+2
-1
src/components/activity/give-courses/index.js
+0
-0
src/components/activity/newyear-2019/common/commonContainer/index.js
+0
-3
src/components/activity/newyear-2019/common/commonPopup/index.js
+0
-3
src/components/activity/newyear-2019/common/user-bullet-screen/index.js
+1
-1
src/components/activity/newyear-2019/myTreasure/index.js
+1
-0
src/components/activity/newyear-2019/preheat/YearCourse/index.js
+1
-1
src/components/activity/newyear-2019/treasure-box/index.js
+0
-3
src/components/activity/treasure-box/common/commonContainer/index.js
+0
-3
src/components/activity/treasure-box/common/commonPopup/index.js
+0
-3
src/components/activity/treasure-box/common/user-bullet-screen/index.js
+1
-1
src/components/activity/treasure-box/myTreasure/index.js
+1
-0
src/components/activity/treasure-box/treasure-box/index.js
+0
-3
src/components/ai-test/scores/index.js
+3
-2
src/components/bargainMiddlePage/index.js
+9
-30
src/components/blessingPreheat/ReserveCourse/index.js
+5
-4
src/components/blessingPreheat/courseList/index.js
+0
-1
src/components/blessingPreheat/luckDraw/index.js
+2
-1
src/components/blessingPreheat/rankList/index.js
+1
-0
src/components/college/banner.js
+1
-11
src/components/coupons/Coupon/index.js
+6
-5
src/components/coupons/myCoupons/index.js
+4
-3
src/components/detail/audition/index.js
+0
-4
src/components/detail/group/togroup.js
+1
-6
src/components/detail/redPacket/index.js
+2
-2
src/components/detail/single/index.js
+2
-3
src/components/detail/single/singleSuccess.js
+1
-2
src/components/ml/pythomDes/index.js
+6
-24
src/components/order/orderinfo.js
+0
-4
src/components/python/pythomDes/Study/index.js
+1
-1
src/components/python/pythomDes/Test/index.js
+1
-1
src/components/python/pythonStudy/index.js
+2
-2
src/components/share-page/aist-share/index.js
+1
-2
src/components/sharePoster/index.js
+1
-16
src/components/study/myCourses/index.js
+3
-3
src/components/ts-test/index.tsx
+5
-3
src/components/video/video-catalog/index.js
+1
-0
src/router/privateRoute.js
+2
-2
No files found.
package.json
View file @
2057bf98
...
...
@@ -138,7 +138,7 @@
"API"
:
"readonly"
,
"NoCaptcha"
:
"readonly"
,
"WeixinJSBridge"
:
"readonly"
,
"_czc"
:
"
readonly
"
,
"_czc"
:
"
writable
"
,
"wx"
:
"readonly"
}
},
...
...
src/common/WxLogin/index.js
View file @
2057bf98
...
...
@@ -2,10 +2,6 @@ import React, { Component } from "react"
import
"./index.scss"
class
WxLogin
extends
Component
{
constructor
(
props
)
{
super
(
props
)
}
// 提示微信登录还是账号登录,微信授权登录不需要绑定手机号
wxLogin
=
()
=>
{
let
url
=
window
.
location
.
href
...
...
src/components/Index/liveRoom.js
View file @
2057bf98
...
...
@@ -132,7 +132,7 @@ class LiveRoom extends Component {
// 服务号预约
serverStep
=
()
=>
{
if
(
this
.
state
.
isfollow
==
2
)
{
if
(
Number
(
this
.
state
.
isfollow
)
=
==
2
)
{
window
.
location
.
href
=
"https://mp.weixin.qq.com/mp/profile_ext?action=home&__biz=MzIyMzMzMTIwNA==&scene=124#wechat_redirect"
}
else
{
...
...
src/components/activity/2020-717/question/index.js
View file @
2057bf98
/* eslint-disable eqeqeq */
import
React
,
{
Component
}
from
"react"
import
"./index.scss"
import
{
Toast
}
from
"antd-mobile"
import
classnames
from
"classnames"
import
{
browser
,
http
}
from
"src/utils"
import
{
http
}
from
"src/utils"
import
{
WithFullSize
}
from
"src/HOCs"
import
{
Link
}
from
"react-router-dom"
import
{
compose
}
from
"redux"
...
...
src/components/activity/give-courses/index.js
View file @
2057bf98
This diff is collapsed.
Click to expand it.
src/components/activity/newyear-2019/common/commonContainer/index.js
View file @
2057bf98
...
...
@@ -2,9 +2,6 @@ import React, { Component } from "react"
import
"./index.scss"
export
default
class
CommonContainer
extends
Component
{
constructor
(
props
)
{
super
(
props
)
}
render
()
{
const
{
id
}
=
this
.
props
return
(
...
...
src/components/activity/newyear-2019/common/commonPopup/index.js
View file @
2057bf98
...
...
@@ -2,9 +2,6 @@ import React, { Component } from "react"
import
"./index.scss"
export
default
class
index
extends
Component
{
constructor
(
props
)
{
super
(
props
)
}
computedStyle
=
()
=>
{
return
{
top
:
`
${
this
.
props
.
top
}
px`
,
...
...
src/components/activity/newyear-2019/common/user-bullet-screen/index.js
View file @
2057bf98
...
...
@@ -64,7 +64,7 @@ class UserBulletScreen extends Component {
getBulletScreenData
=
(
initializeSwiper
=
false
)
=>
{
return
http
.
get
(
`
${
API
.
home
}
/sys/barrage_data`
).
then
((
res
)
=>
{
const
{
data
,
code
}
=
res
.
data
if
(
code
==
200
)
{
if
(
code
==
=
200
)
{
if
(
initializeSwiper
)
{
this
.
setState
(
{
...
...
src/components/activity/newyear-2019/myTreasure/index.js
View file @
2057bf98
/* eslint-disable eqeqeq */
import
React
,
{
Component
}
from
"react"
import
{
connect
}
from
"react-redux"
import
{
HeaderBar
}
from
"src/common"
...
...
src/components/activity/newyear-2019/preheat/YearCourse/index.js
View file @
2057bf98
/* eslint-disable jsx-a11y/anchor-is-valid */
/* eslint-disable jsx-a11y/anchor-is-valid
, eqeqeq
*/
import
React
,
{
Component
}
from
"react"
import
"./index.scss"
import
{
http
,
SendMessageToApp
,
getParam
,
browser
}
from
"src/utils"
...
...
src/components/activity/newyear-2019/treasure-box/index.js
View file @
2057bf98
...
...
@@ -7,9 +7,6 @@ import Prizes from "src/components/activity/newyear-2019/common/prizes"
import
UserBulletScreen
from
"src/components/activity/newyear-2019/common/user-bullet-screen"
class
TreasureBox
extends
Component
{
constructor
(
props
)
{
super
(
props
)
}
render
()
{
return
(
<
CommonContainer
id
=
"year-treasure"
title
=
{
"组队开宝箱"
}
>
...
...
src/components/activity/treasure-box/common/commonContainer/index.js
View file @
2057bf98
...
...
@@ -2,9 +2,6 @@ import React, { Component } from "react"
import
"./index.scss"
export
default
class
CommonContainer
extends
Component
{
constructor
(
props
)
{
super
(
props
)
}
render
()
{
const
{
id
}
=
this
.
props
return
(
...
...
src/components/activity/treasure-box/common/commonPopup/index.js
View file @
2057bf98
...
...
@@ -2,9 +2,6 @@ import React, { Component } from "react"
import
"./index.scss"
export
default
class
index
extends
Component
{
constructor
(
props
)
{
super
(
props
)
}
computedStyle
=
()
=>
{
return
{
top
:
`
${
this
.
props
.
top
}
px`
,
...
...
src/components/activity/treasure-box/common/user-bullet-screen/index.js
View file @
2057bf98
...
...
@@ -64,7 +64,7 @@ class UserBulletScreen extends Component {
getBulletScreenData
=
(
initializeSwiper
=
false
)
=>
{
return
http
.
get
(
`
${
API
.
home
}
/sys/barrage_data`
).
then
((
res
)
=>
{
const
{
data
,
code
}
=
res
.
data
if
(
code
==
200
)
{
if
(
code
==
=
200
)
{
if
(
initializeSwiper
)
{
this
.
setState
(
{
...
...
src/components/activity/treasure-box/myTreasure/index.js
View file @
2057bf98
/* eslint-disable eqeqeq */
import
React
,
{
Component
}
from
"react"
import
{
connect
}
from
"react-redux"
import
{
HeaderBar
}
from
"src/common"
...
...
src/components/activity/treasure-box/treasure-box/index.js
View file @
2057bf98
...
...
@@ -7,9 +7,6 @@ import Prizes from "src/components/activity/treasure-box/common/prizes"
import
UserBulletScreen
from
"src/components/activity/treasure-box/common/user-bullet-screen"
class
TreasureBox
extends
Component
{
constructor
(
props
)
{
super
(
props
)
}
render
()
{
return
(
<
CommonContainer
id
=
"year-treasure"
title
=
{
"组队开宝箱"
}
>
...
...
src/components/ai-test/scores/index.js
View file @
2057bf98
/* eslint-disable jsx-a11y/anchor-is-valid */
import
React
,
{
Component
}
from
"react"
import
"./index.scss"
import
{
Tabs
,
Toast
}
from
"antd-mobile"
...
...
@@ -118,7 +119,7 @@ class Scores extends Component {
getUserAddress
=
()
=>
{
http
.
get
(
`
${
API
.
home
}
/sys/user_address_info`
).
then
((
res
)
=>
{
const
{
code
,
msg
,
data
}
=
res
.
data
const
{
code
,
data
}
=
res
.
data
if
(
code
===
200
)
{
this
.
setState
({
userAddress
:
data
,
...
...
@@ -150,7 +151,7 @@ class Scores extends Component {
return
}
http
.
post
(
`
${
API
.
home
}
/sys/update_address`
,
userAddress
).
then
((
res
)
=>
{
const
{
code
,
msg
,
data
}
=
res
.
data
const
{
code
,
msg
}
=
res
.
data
if
(
code
===
200
)
{
Toast
.
success
(
"提交成功"
,
2
,
null
,
false
)
this
.
setState
({
...
...
src/components/bargainMiddlePage/index.js
View file @
2057bf98
/* eslint-disable jsx-a11y/anchor-is-valid */
import
React
,
{
Component
}
from
"react"
import
"./bargain-middle-page.scss"
import
{
HeaderBar
,
VList
}
from
"src/common"
import
{
Course
}
from
"src/common"
import
{
api
,
getParam
,
http
,
browser
,
wxShare
}
from
"src/utils"
import
{
getParam
,
http
,
browser
,
wxShare
}
from
"src/utils"
import
{
Toast
}
from
"antd-mobile"
import
{
Link
,
withRouter
}
from
"react-router-dom"
import
Ranking
from
"./ranking"
...
...
@@ -13,9 +14,7 @@ import {
differenceInDays
,
}
from
"date-fns"
import
Overlay
from
"../detail/overlay"
import
{
compose
}
from
"redux"
import
{
connect
}
from
"react-redux"
import
{
getCourses
}
from
"./../detail/actions"
import
classnames
from
"classnames"
import
FollowBarcode
from
"./barcode/index"
...
...
@@ -159,7 +158,7 @@ class BargainMiddlePage extends Component {
list
:
res
.
data
.
data
.
list
,
outList
:
newList
,
})
}
else
if
(
res
.
data
.
code
==
4030
||
res
.
data
.
code
==
4040
)
{
}
else
if
(
res
.
data
.
code
==
=
4030
||
res
.
data
.
code
=
==
4040
)
{
}
else
{
Toast
.
info
(
res
.
data
.
msg
,
2
)
}
...
...
@@ -317,7 +316,7 @@ class BargainMiddlePage extends Component {
this
.
getBargainInfo
()
this
.
getBargainRankList
(
getParam
(
"id"
),
1
)
}
else
if
(
res
.
data
.
code
==
4030
||
res
.
data
.
code
==
4040
)
{
}
else
if
(
res
.
data
.
code
==
=
4030
||
res
.
data
.
code
=
==
4040
)
{
if
(
browser
.
isWeixin
)
{
let
redirectURI
=
window
.
location
.
href
if
(
...
...
@@ -390,15 +389,12 @@ class BargainMiddlePage extends Component {
}
toCourseDetail
=
(
id
)
=>
{
const
{
dispatch
,
history
}
=
this
.
props
// dispatch(getCourses(id, () => {
const
{
history
}
=
this
.
props
history
.
push
(
`/detail?id=
${
id
}
`
)
return
false
// }));
}
render
()
{
// console.log(this.props);
let
thirdRow
,
btn
// is_artifact 0-再邀请多少人可以使用 1-可以使用未领取 2-已领取 3-已使用
if
(
this
.
state
.
bargainData
.
is_artifact
===
0
)
{
...
...
@@ -513,8 +509,8 @@ class BargainMiddlePage extends Component {
/
>
<
/ul
>
<
div
className
=
"bargain-detail"
>
{(
this
.
state
.
data
.
bargain_status
==
0
||
this
.
state
.
data
.
bargain_status
==
1
)
&&
(
{(
Number
(
this
.
state
.
data
.
bargain_status
)
=
==
0
||
Number
(
this
.
state
.
data
.
bargain_status
)
=
==
1
)
&&
(
<
div
>
<
div
className
=
"top"
>
<
div
>
...
...
@@ -746,12 +742,12 @@ function CourseDes(props) {
<
div
className
=
"price-bar"
>
<
span
className
=
{
"discount-price"
}
>
¥
{
course
.
course_price
}
<
/span
>
{
/* is_originator 是否发起人 0-否 1-是 */
}
{
is_originator
==
1
&&
bargain_status
!
=
3
&&
(
{
Number
(
is_originator
)
===
1
&&
Number
(
bargain_status
)
!=
=
3
&&
(
<
button
className
=
{
"purchase-btn"
}
onClick
=
{
toCart
}
>
¥
{
course
.
pay_price
}
去支付
<
/button
>
)}
{
is_originator
==
1
&&
bargain_status
==
3
&&
(
{
Number
(
is_originator
)
===
1
&&
Number
(
bargain_status
)
=
==
3
&&
(
<
span
className
=
"course-button__buy--done"
>
已购买
<
/span
>
)}
<
/div
>
...
...
@@ -849,23 +845,6 @@ function CourseBottom(props) {
)
}
function
PublicNumber
(
props
)
{
return
(
<
div
className
=
"bargain-public-number"
>
<
img
className
=
"avait"
src
=
{
props
.
avatar
}
alt
=
""
/>
{
props
.
firendBaigainPrice
&&
(
<
p
className
=
"status-title ff4"
>
谢谢你帮我砍了
{
props
.
money
}
元!
<
/p
>
)}
<
p
className
=
"status-dec"
>
关注公众号,可以再砍一刀哦
~<
/p
>
<
img
className
=
"public-number-img"
src
=
"https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/tinypng-common/right_weixin.png"
alt
=
""
/>
<
/div
>
)
}
function
BargainFirst
(
props
)
{
return
(
<
div
className
=
"bargain-first"
>
...
...
src/components/blessingPreheat/ReserveCourse/index.js
View file @
2057bf98
...
...
@@ -4,7 +4,7 @@ import listFrame from "./../listFrame/index"
import
"./index.scss"
import
{
Toast
}
from
"antd-mobile"
import
{
connect
}
from
"react-redux"
import
{
Link
,
withRouter
}
from
"react-router-dom"
import
{
withRouter
}
from
"react-router-dom"
class
ReserveCourse
extends
Component
{
constructor
(
props
)
{
...
...
@@ -33,7 +33,7 @@ class ReserveCourse extends Component {
if
(
code
===
200
)
{
this
.
setState
({
courseData
:
JSON
.
stringify
(
data
)
==
"{}"
JSON
.
stringify
(
data
)
==
=
"{}"
?
[]
:
data
.
filter
((
item
,
index
)
=>
index
<
4
),
courseDataAll
:
data
,
...
...
@@ -46,7 +46,7 @@ class ReserveCourse extends Component {
// 立即付定金
expandPaydj
=
(
courseId
)
=>
{
const
{
user
,
history
}
=
this
.
props
const
{
user
}
=
this
.
props
const
uid
=
user
&&
user
.
data
&&
user
.
data
.
uid
if
(
!
uid
)
{
if
(
!
getParam
(
"version"
))
{
...
...
@@ -68,7 +68,7 @@ class ReserveCourse extends Component {
}
// 立即付尾款
expandPaywk
=
(
courseId
,
time
,
day
)
=>
{
const
{
user
,
history
}
=
this
.
props
const
{
user
}
=
this
.
props
const
uid
=
user
&&
user
.
data
&&
user
.
data
.
uid
if
(
!
uid
)
{
if
(
!
getParam
(
"version"
))
{
...
...
@@ -137,6 +137,7 @@ function CourseList(props) {
{
courseData
.
map
((
item
,
index
)
=>
{
return
(
<
li
className
=
"course-item-box"
key
=
{
index
}
>
{
/* eslint-disable-next-line jsx-a11y/anchor-is-valid */
}
<
a
onClick
=
{()
=>
tostudy
(
item
.
course_id
)}
>
<
div
className
=
"top"
>
<
div
className
=
"square"
>
...
...
src/components/blessingPreheat/courseList/index.js
View file @
2057bf98
...
...
@@ -7,7 +7,6 @@ import ListFrame from "./../listFrame/index"
import
CourseItem
from
"./../courseItem/index"
import
ListHeader
from
"./../listHeader"
import
"./index.scss"
import
cookie
from
"js-cookie"
class
CourseList
extends
Component
{
constructor
(
props
)
{
...
...
src/components/blessingPreheat/luckDraw/index.js
View file @
2057bf98
...
...
@@ -64,7 +64,8 @@ class LuckDraw extends Component {
key
=
{
`
${
val
.
id
}
-
${
k
}
`
}
>
<
div
className
=
"prize__image"
>
<
img
src
=
{
v
.
img
}
alt
=
"image"
/>
{
/* eslint-disable-next-line jsx-a11y/alt-text */
}
<
img
src
=
{
v
.
img
}
/
>
<
/div
>
<
p
className
=
"prize__desc"
>
{
v
.
name
}
<
/p
>
<
p
className
=
"prize__desc"
>
(
*
{
v
.
num
}
)
<
/p
>
...
...
src/components/blessingPreheat/rankList/index.js
View file @
2057bf98
/* eslint-disable jsx-a11y/alt-text */
import
React
,
{
Component
}
from
"react"
import
"./index.scss"
import
{
http
}
from
"src/utils"
...
...
src/components/college/banner.js
View file @
2057bf98
import
React
from
"react"
import
"./banner.scss"
export
default
(
props
)
=>
{
const
{
banner
=
""
}
=
props
const
style
=
()
=>
{
if
(
banner
)
{
return
{
backgroundImage
:
`url(
${
banner
}
)`
,
}
}
return
{}
}
export
default
()
=>
{
return
<
div
className
=
"college-banner"
><
/div
>
}
src/components/coupons/Coupon/index.js
View file @
2057bf98
...
...
@@ -58,7 +58,7 @@ class Coupon extends PureComponent {
})
.
then
((
res
)
=>
{
const
{
data
}
=
res
if
(
data
.
code
==
200
)
{
if
(
data
.
code
==
=
200
)
{
this
.
props
.
endExpansion
(
id
,
data
.
data
.
coupon_id
)
}
else
{
Toast
.
info
(
data
.
msg
)
...
...
@@ -82,7 +82,7 @@ class Coupon extends PureComponent {
}
=
this
.
props
let
top
,
bottom
/* eslint-disable default-case */
switch
(
ctype
)
{
case
this
.
VOUCHER
:
top
=
(
...
...
@@ -96,11 +96,11 @@ class Coupon extends PureComponent {
bottom
=
(
<>
<
span
className
=
{
"limit"
}
>
{
limit_course
==
0
{
Number
(
limit_course
)
=
==
0
?
"可用于大于代金券金额的课程"
:
`仅适用于《
${
course_title
}
》`
}
<
/span
>
{
showUseButton
&&
ctype
==
this
.
VOUCHER
&&
(
{
showUseButton
&&
Number
(
ctype
)
=
==
this
.
VOUCHER
&&
(
<
button
className
=
"use"
onClick
=
{
this
.
GoToUse
}
>
立即使用
<
/button
>
...
...
@@ -118,7 +118,7 @@ class Coupon extends PureComponent {
bottom
=
(
<>
<
span
className
=
{
"limit"
}
>
{
`仅适用于《
${
course_title
}
》`
}
<
/span
>
{
showUseButton
&&
ctype
==
this
.
FREE
&&
(
{
showUseButton
&&
Number
(
ctype
)
=
==
this
.
FREE
&&
(
<
button
className
=
"use"
onClick
=
{(
e
)
=>
this
.
ExchangeCourse
(
e
)}
>
立即兑换
<
/button
>
...
...
@@ -176,6 +176,7 @@ class Coupon extends PureComponent {
)
break
}
/* eslint-enable default-case */
return
(
<
BaseCoupon
...
...
src/components/coupons/myCoupons/index.js
View file @
2057bf98
...
...
@@ -67,7 +67,7 @@ class UseCoupon extends PureComponent {
const
coupon
=
data
.
data
if
(
state
.
from
===
"/my"
)
{
if
(
coupon
[
"ctype"
]
==
2
)
{
if
(
Number
(
coupon
[
"ctype"
])
=
==
2
)
{
this
.
setState
({
courseCouponData
:
coupon
,
courseCouponExchange
:
true
,
...
...
@@ -119,16 +119,17 @@ class UseCoupon extends PureComponent {
const
[
expansionCoupons
,
allCoupons
]
=
coupons
const
{
data
:
all
}
=
allCoupons
const
{
data
:
expansion
}
=
expansionCoupons
if
(
expansion
.
code
==
200
)
{
if
(
expansion
.
code
==
=
200
)
{
Array
.
isArray
(
expansion
.
data
)
&&
(
expansion
.
data
=
expansion
.
data
.
map
(
/* eslint-disable-next-line no-sequences */
(
item
)
=>
((
item
.
ctype
=
4
),
item
)
))
&&
(
myCoupons
=
myCoupons
.
concat
(
expansion
.
data
))
}
else
{
Toast
.
info
(
expansion
.
msg
)
}
if
(
all
.
code
==
200
)
{
if
(
all
.
code
==
=
200
)
{
Array
.
isArray
(
all
.
data
)
&&
(
myCoupons
=
myCoupons
.
concat
(
all
.
data
))
}
else
{
Toast
.
info
(
all
.
msg
)
...
...
src/components/detail/audition/index.js
View file @
2057bf98
...
...
@@ -3,10 +3,6 @@ import "./index.scss"
import
{
CallApp
}
from
"../../../common"
class
Audition
extends
Component
{
constructor
(
props
)
{
super
(
props
)
}
colse
=
()
=>
{
this
.
props
.
boxHide
(
false
)
}
...
...
src/components/detail/group/togroup.js
View file @
2057bf98
...
...
@@ -143,18 +143,13 @@ class ToGroup extends Component {
render
()
{
const
{
data
:
{
course_id
,
course_title
,
simpledescription
,
price0
,
price1
},
pdd_price
,
is_success
,
person_num
,
groupon_member
,
course_list
,
}
=
this
.
state
const
Info
=
(
<
div
className
=
"info"
>
<
p
className
=
"title"
onClick
=
{()
=>
this
.
toCourseDetail
(
course_id
)}
>
{
/* <Link to={`/detail?id=${course_id}`}> */
}
{
course_title
}
{
/* </Link> */
}
<
/p
>
<
p
className
=
"contact text-overflow-2"
>
{
simpledescription
}
<
/p
>
<
div
className
=
"des"
>
...
...
@@ -253,7 +248,7 @@ class ToGroup extends Component {
}
function
GorupContent
(
props
)
{
let
tip
,
btn
,
dec
,
groupTip
,
shareTip
,
groupSuccessMbc
let
tip
,
btn
,
dec
,
groupTip
const
{
pdd_price
,
data
,
...
...
src/components/detail/redPacket/index.js
View file @
2057bf98
...
...
@@ -3,7 +3,7 @@ import { CopyToClipboard } from "react-copy-to-clipboard"
import
classnames
from
"classnames"
import
{
isEmpty
}
from
"lodash"
import
{
browser
}
from
"src/utils"
import
{
http
,
getParam
,
validateTel
}
from
"src/utils"
import
{
http
,
getParam
}
from
"src/utils"
import
{
Formik
,
Form
,
Field
}
from
"formik"
import
{
Toast
}
from
"antd-mobile"
import
CaptchaAli
from
"src/common/Captcha-ali"
...
...
@@ -662,7 +662,7 @@ class RedPacket extends PureComponent {
{
type
!==
0
&&
(
<
div
className
=
{
cls
}
onClick
=
{
this
.
clickMask
}
>
{
/* wechat */
}
{
type
==
2
&&
(
{
type
==
=
2
&&
(
<
div
className
=
"pupup-wechat"
>
<
h4
className
=
"popup-wechat__title"
>
当前环境不支持领红包活动
...
...
src/components/detail/single/index.js
View file @
2057bf98
...
...
@@ -2,7 +2,7 @@ import React, { Component } from "react"
import
"./index.scss"
import
{
getParam
,
http
,
browser
}
from
"src/utils"
import
{
Toast
}
from
"antd-mobile"
import
{
Link
,
withRouter
}
from
"react-router-dom"
import
{
withRouter
}
from
"react-router-dom"
import
{
compose
}
from
"redux"
import
{
connect
}
from
"react-redux"
import
{
...
...
@@ -143,7 +143,7 @@ class Single extends Component {
paySign
:
data
.
paySign
,
//微信签名
},
function
(
res
)
{
if
(
res
.
err_msg
==
"get_brand_wcpay_request:ok"
)
{
if
(
res
.
err_msg
==
=
"get_brand_wcpay_request:ok"
)
{
Toast
.
info
(
"支付成功"
,
2
)
_this
.
intervalPayStatus
=
setInterval
(
function
()
{
http
...
...
@@ -354,7 +354,6 @@ class Single extends Component {
}
render
()
{
const
{
showSingleBox
}
=
this
.
state
if
(
this
.
state
.
endTime
)
{
let
date
=
this
.
state
.
endTime
*
1000
let
now
=
Date
.
now
()
...
...
src/components/detail/single/singleSuccess.js
View file @
2057bf98
...
...
@@ -2,7 +2,7 @@ import React, { Component } from "react"
import
"./index.scss"
import
{
getParam
,
http
,
browser
}
from
"src/utils"
import
{
Toast
}
from
"antd-mobile"
import
{
Link
,
withRouter
}
from
"react-router-dom"
import
{
withRouter
}
from
"react-router-dom"
import
{
compose
}
from
"redux"
import
{
connect
}
from
"react-redux"
import
{
...
...
@@ -193,7 +193,6 @@ class Single extends Component {
}
render
()
{
let
{
singleBox
}
=
this
.
state
if
(
this
.
state
.
endTime
)
{
let
date
=
this
.
state
.
endTime
*
1000
let
now
=
Date
.
now
()
...
...
src/components/ml/pythomDes/index.js
View file @
2057bf98
...
...
@@ -58,7 +58,7 @@ class PythonDes extends Component {
}
creatOid
=
(
type
)
=>
{
let
url
=
""
if
(
type
==
3
)
{
if
(
Number
(
type
)
=
==
3
)
{
url
=
`
${
API
[
"base-api"
]}
/sys/it_baoming/create`
}
else
{
url
=
`
${
API
[
"base-api"
]}
/sys/trial_create`
...
...
@@ -115,7 +115,7 @@ class PythonDes extends Component {
})
.
then
((
res
)
=>
{
const
{
code
,
msg
}
=
res
.
data
if
(
code
==
200
)
{
if
(
code
==
=
200
)
{
if
(
!
getParam
(
"version"
))
{
// H5
this
.
setState
({
...
...
@@ -230,7 +230,7 @@ class PythonDes extends Component {
)
.
then
((
res
)
=>
{
const
{
code
,
data
,
msg
}
=
res
.
data
if
(
code
==
200
)
{
if
(
code
==
=
200
)
{
this
.
setState
({
syllabus
:
data
.
syllabus
.
slice
(
0
,
2
),
allSyllabus
:
data
.
syllabus
,
...
...
@@ -319,7 +319,9 @@ class PythonDes extends Component {
<
/div
>
)}
{
this
.
state
.
isShowChannel
==
1
&&
<
CallApp
className
=
"toapp"
/>
}
{
Number
(
this
.
state
.
isShowChannel
)
===
1
&&
(
<
CallApp
className
=
"toapp"
/>
)}
{
/* 课程介绍 */
}
<
Description
/>
...
...
@@ -358,24 +360,4 @@ class PythonDes extends Component {
}
}
function
DefineItem
(
props
)
{
const
{
item
,
item
:
{
desInfo
},
}
=
props
return
(
<
div
className
=
{
"number_one"
}
>
<
img
className
=
{
"trophy"
}
src
=
{
item
.
titleUrl
}
><
/img
>
<
p
className
=
{
"item__title"
}
>
{
item
.
title
}
<
/p
>
<
p
className
=
{
"item__subtitle"
}
style
=
{{
width
:
item
.
subWidth
}}
>
{
item
.
subTitle
}
<
/p
>
<
img
style
=
{{
width
:
desInfo
.
width
,
height
:
desInfo
.
height
}}
src
=
{
item
.
bottomUrl
}
><
/img
>
<
/div
>
)
}
export
default
PythonDes
src/components/order/orderinfo.js
View file @
2057bf98
...
...
@@ -120,10 +120,6 @@ const MyForm = withFormik({
})(
InnerForm
)
class
Orderinfo
extends
Component
{
constructor
(
props
)
{
super
(
props
)
}
render
()
{
return
(
<
div
>
...
...
src/components/python/pythomDes/Study/index.js
View file @
2057bf98
...
...
@@ -10,7 +10,7 @@ export default class Study extends Component {
let
cs
=
Math
.
floor
(
Number
(
str
)
/
10
)
let
cv
=
""
if
(
str
.
length
>
1
)
{
if
(
cs
==
1
)
{
if
(
cs
==
=
1
)
{
cv
=
ci
>=
1
?
cn
[
9
]
+
cn
[
ci
-
1
]
:
cn
[
9
]
}
else
{
cv
=
ci
>
1
?
cn
[
cs
-
1
]
+
cn
[
9
]
+
cn
[
ci
-
1
]
:
cn
[
cs
-
1
]
+
cn
[
9
]
...
...
src/components/python/pythomDes/Test/index.js
View file @
2057bf98
...
...
@@ -10,7 +10,7 @@ export default class Test extends Component {
let
cs
=
Math
.
floor
(
Number
(
str
)
/
10
)
let
cv
=
""
if
(
str
.
length
>
1
)
{
if
(
cs
==
1
)
{
if
(
cs
==
=
1
)
{
cv
=
ci
>=
1
?
cn
[
9
]
+
cn
[
ci
-
1
]
:
cn
[
9
]
}
else
{
cv
=
ci
>
1
?
cn
[
cs
-
1
]
+
cn
[
9
]
+
cn
[
ci
-
1
]
:
cn
[
cs
-
1
]
+
cn
[
9
]
...
...
src/components/python/pythonStudy/index.js
View file @
2057bf98
/* eslint-disable eqeqeq */
import
React
,
{
Component
}
from
"react"
import
{
Accordion
,
Toast
}
from
"antd-mobile"
import
{
HeaderBar
,
CallApp
}
from
"src/common"
import
{
http
,
getParam
}
from
"src/utils"
import
"./index.scss"
import
{
Link
}
from
"react-router-dom"
import
{
connect
}
from
"react-redux"
import
Mask
from
"./../poup/index.js"
import
ShareRank
from
"src/components/detail/shareRank"
...
...
@@ -49,7 +49,7 @@ class PythonStudy extends Component {
let
cs
=
Math
.
floor
(
Number
(
str
)
/
10
)
let
cv
=
""
if
(
str
.
length
>
1
)
{
if
(
cs
==
1
)
{
if
(
cs
==
=
1
)
{
cv
=
ci
>=
1
?
cn
[
9
]
+
cn
[
ci
-
1
]
:
cn
[
9
]
}
else
{
cv
=
ci
>
1
?
cn
[
cs
-
1
]
+
cn
[
9
]
+
cn
[
ci
-
1
]
:
cn
[
cs
-
1
]
+
cn
[
9
]
...
...
src/components/share-page/aist-share/index.js
View file @
2057bf98
...
...
@@ -2,7 +2,6 @@ import React, { PureComponent } from "react"
import
"./aist-share.scss"
import
withFullSize
from
"src/HOCs/WithFullSize"
import
{
http
,
wxShare
}
from
"src/utils"
import
{
getWXObject
}
from
"src/utils/wechat/base"
import
{
Link
}
from
"react-router-dom"
class
AistShare
extends
PureComponent
{
...
...
@@ -34,7 +33,7 @@ class AistShare extends PureComponent {
)}
/
${
search
.
get
(
"vId"
)}
`
)
.
then
((
res
)
=>
{
if
(
res
.
data
.
errno
==
200
)
{
if
(
res
.
data
.
errno
==
=
200
)
{
const
data
=
res
.
data
.
data
this
.
setState
({
course
:
{
...
...
src/components/sharePoster/index.js
View file @
2057bf98
...
...
@@ -56,17 +56,9 @@ class SharePoster extends Component {
let
qrCodePositionX
=
imgList
[
index
].
qr_code_x
*
$width
// 二维码x轴位置
let
qrCodePositionY
=
imgList
[
index
].
qr_code_y
*
$height
+
7
// 二维码y轴位置
let
qrCodeWidth
=
imgList
[
index
].
qr_code_width
*
$width
// 二维码宽度
let
qrCodeHeight
=
imgList
[
index
].
qr_code_height
*
$height
-
avatarHeight
/
2
// 二维码高度
let
qrCodeLink
=
`https://m.julyedu.com/detail?id=
${
getParam
(
"courseId"
)}
&dist_code
${
getParam
(
"dist_code"
)}
`
var
canvas
=
document
.
getElementById
(
"canvas"
),
context
=
canvas
.
getContext
(
"2d"
)
// console.log(_this);
_this
.
getBase64
(
imgSrc1
)
// 背景图片合成
...
...
@@ -74,11 +66,6 @@ class SharePoster extends Component {
let
bgImage
=
new
Image
()
bgImage
.
src
=
img
let
qrCodeImg
=
document
.
getElementById
(
"qrcode"
)
let
ua
=
navigator
.
userAgent
.
toLowerCase
()
// Android终端
let
isAndroid
=
ua
.
indexOf
(
"Android"
)
>
-
1
||
ua
.
indexOf
(
"Adr"
)
>
-
1
// Ios终端
let
isiOS
=
!!
ua
.
match
(
/
\(
i
[^
;
]
+;
(
U;
)?
CPU.+Mac OS X/
)
if
(
/
(
iPhone|iPad|iPod|iOS
)
/i
.
test
(
navigator
.
userAgent
))
{
qrCodeImg
=
document
.
getElementById
(
"qrcode"
)
}
else
if
(
/
(
Android
)
/i
.
test
(
navigator
.
userAgent
))
{
...
...
@@ -167,7 +154,6 @@ class SharePoster extends Component {
// 合成图片位置
imgPosition
=
(
ctx
,
img
,
x
,
y
,
r
)
=>
{
ctx
.
save
()
var
d
=
2
*
r
var
cx
=
x
+
r
var
cy
=
y
+
r
ctx
.
beginPath
()
...
...
@@ -229,8 +215,7 @@ class SharePoster extends Component {
let
ctx
=
canvas
.
getContext
(
"2d"
)
ctx
.
drawImage
(
img
,
0
,
0
,
img
.
width
,
img
.
height
)
let
ext
=
img
.
src
.
substring
(
img
.
src
.
lastIndexOf
(
"."
)
+
1
).
toLowerCase
()
let
dataURL
=
canvas
.
toDataURL
(
"image/"
+
ext
)
return
dataURL
return
canvas
.
toDataURL
(
"image/"
+
ext
)
}
// canvas转换成img图片
...
...
src/components/study/myCourses/index.js
View file @
2057bf98
...
...
@@ -76,7 +76,7 @@ class MyCourses extends Component {
handleClick
=
(
id
,
item
)
=>
{
const
{
history
}
=
this
.
props
const
{
mode
,
course_id
}
=
item
if
(
mode
&&
mode
==
6
)
{
if
(
mode
&&
Number
(
mode
)
=
==
6
)
{
history
.
push
(
`/python?id=
${
course_id
}
`
)
return
}
...
...
@@ -131,13 +131,13 @@ class MyCourses extends Component {
)}
{
!
item
.
is_restricted
&&
!
item
.
is_aist
&&
item
.
contact_type
==
1
&&
Number
(
item
.
contact_type
)
=
==
1
&&
item
.
course_qq
&&
(
<
div
className
=
"contact"
>
QQ
群:
{
item
.
course_qq
}
<
/div
>
)}
{
!
item
.
is_restricted
&&
!
item
.
is_aist
&&
item
.
contact_type
==
2
&&
Number
(
item
.
contact_type
)
=
==
2
&&
item
.
course_qq
&&
(
<
div
className
=
"contact"
>
班主任微信:
{
item
.
course_qq
}
...
...
src/components/ts-test/index.tsx
View file @
2057bf98
...
...
@@ -2,9 +2,7 @@ import React, { useState } from "react"
import
{
withRouter
}
from
"react-router-dom"
const
TSTest
:
React
.
FC
=
()
=>
{
const
[
count
,
setCount
]
=
useState
(
0
)
const
[
count
,
setCount
]
=
useState
(
0
)
function
handleAlertClick
()
{
setTimeout
(()
=>
{
...
...
@@ -22,4 +20,8 @@ const TSTest: React.FC = () => {
)
}
function
C
(
a
=
2
,
b
=
3
,
c
=
4
,
d
=
5
,
e
=
6
)
{
return
d
}
export
default
withRouter
(
TSTest
)
src/components/video/video-catalog/index.js
View file @
2057bf98
/* eslint-disable jsx-a11y/anchor-is-valid, no-script-url */
import
React
,
{
Component
}
from
"react"
import
"./video-catalog.scss"
import
{
Link
}
from
"react-router-dom"
...
...
src/router/privateRoute.js
View file @
2057bf98
...
...
@@ -9,11 +9,11 @@ const PrivateRoute = ({ component: Component, path, user, ...rest }) => {
const
[
authenticated
,
setAuthorization
]
=
useState
(
false
)
useEffect
(()
=>
{
let
_auth
=
!
user
.
hasError
&&
user
.
code
!=
4040
let
_auth
=
!
user
.
hasError
&&
user
.
code
!=
=
4040
// eslint-disable-next-line no-unused-expressions
typeof
_auth
!==
"undefined"
&&
(
setAuthorization
(
_auth
),
setLoadingState
(
false
))
},
[
user
.
hasError
])
},
[
user
.
hasError
,
user
.
code
])
return
(
<
Route
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment