Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
X
xiaomai-cloud-class-web
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
xiaomai-cloud-class
xiaomai-cloud-class-web
Commits
c420988c
Commit
c420988c
authored
Jan 12, 2021
by
zhangleyuan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat:处理mac端不支持
parent
9330ecb7
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
18 deletions
+24
-18
src/modules/course-manage/components/LiveCourseList.jsx
+10
-1
src/modules/course-manage/components/LiveCourseOpt.jsx
+14
-17
No files found.
src/modules/course-manage/components/LiveCourseList.jsx
View file @
c420988c
...
@@ -421,12 +421,21 @@ class LiveCourseList extends React.Component {
...
@@ -421,12 +421,21 @@ class LiveCourseList extends React.Component {
this
.
props
.
onChange
(
_query
)
this
.
props
.
onChange
(
_query
)
}
}
getDownloadVersion
()
{
getDownloadVersion
()
{
const
isMac
=
/macintosh|mac os x/i
.
test
(
navigator
.
userAgent
);
// 判断用户系统
let
platform
;
if
(
!
isMac
){
platform
=
1
}
else
{
platform
=
4
}
BaseService
BaseService
.
getLastedVersion
({
model
:
5
,
platform
:
1
})
.
getLastedVersion
({
model
:
5
,
platform
})
.
then
((
res
)
=>
{
.
then
((
res
)
=>
{
const
{
result
=
{}
}
=
res
;
const
{
result
=
{}
}
=
res
;
this
.
setState
({
downloadUrl
:
result
.
releaseUrl
});
this
.
setState
({
downloadUrl
:
result
.
releaseUrl
});
})
})
}
}
handleViewPlayBack
=
(
item
)
=>
{
handleViewPlayBack
=
(
item
)
=>
{
let
htmlUrl
;
let
htmlUrl
;
...
...
src/modules/course-manage/components/LiveCourseOpt.jsx
View file @
c420988c
...
@@ -24,24 +24,21 @@ class LiveCourseOpt extends React.Component {
...
@@ -24,24 +24,21 @@ class LiveCourseOpt extends React.Component {
handleDownloadClient
=
()
=>
{
handleDownloadClient
=
()
=>
{
const
isMac
=
/macintosh|mac os x/i
.
test
(
navigator
.
userAgent
);
const
isMac
=
/macintosh|mac os x/i
.
test
(
navigator
.
userAgent
);
// 判断用户系统
// 判断用户系统
if
(
!
isMac
)
{
let
platform
;
BaseService
if
(
!
isMac
){
.
getLastedVersion
({
model
:
5
,
platform
:
1
})
platform
=
1
.
then
((
res
)
=>
{
}
else
{
const
a
=
document
.
createElement
(
"a"
);
platform
=
4
document
.
body
.
appendChild
(
a
);
a
.
href
=
res
.
result
.
releaseUrl
;
a
.
click
();
document
.
body
.
removeChild
(
a
);
})
}
else
{
Modal
.
info
({
title
:
"抱歉,暂不支持Mac版"
,
content
:
"Mac版正在开发中,敬请期待"
,
icon
:
<
span
className=
"icon iconfont default-confirm-icon"
>

</
span
>,
okText
:
'我知道了'
});
}
}
BaseService
.
getLastedVersion
({
model
:
5
,
platform
})
.
then
((
res
)
=>
{
const
a
=
document
.
createElement
(
"a"
);
document
.
body
.
appendChild
(
a
);
a
.
href
=
res
.
result
.
releaseUrl
;
a
.
click
();
document
.
body
.
removeChild
(
a
);
})
}
}
render
()
{
render
()
{
return
(
return
(
...
...
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