Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
T
transport-show-h5
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
EzijingWeb
transport-show-h5
Commits
c86f6e66
提交
c86f6e66
authored
7月 08, 2020
作者:
lihuihui
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'master' of
https://gitlab.ezijing.com/ezijing/transport-weapp-h5
上级
fb83ef89
3c6666a1
隐藏空白字符变更
内嵌
并排
正在显示
8 个修改的文件
包含
37 行增加
和
15 行删除
+37
-15
CourseItem.vue
src/components/CourseItem.vue
+12
-4
index.html
src/index.html
+1
-1
courseTagMessage.vue
src/pages/course/tag/courseTagMessage.vue
+3
-0
index.vue
src/pages/home/index.vue
+3
-0
login.vue
src/pages/login/login.vue
+1
-1
courseList.vue
src/pages/search/courseList.vue
+10
-1
tagList.vue
src/pages/search/tagList.vue
+3
-1
videoList.vue
src/pages/search/videoList.vue
+4
-7
没有找到文件。
src/components/CourseItem.vue
浏览文件 @
c86f6e66
...
...
@@ -19,14 +19,22 @@ export default {
computed
:
{
curriculum
()
{
return
this
.
data
.
curriculum
},
isWeapp
()
{
return
this
.
$store
.
state
.
isWeapp
}
},
methods
:
{
onClick
(
data
)
{
this
.
$router
.
push
({
name
:
'courseLearnItem'
,
params
:
{
id
:
data
.
course_id
}
})
if
(
this
.
isWeapp
)
{
const
url
=
`/pages/web/index?src=
${
window
.
location
.
origin
}
/course/learn/
${
data
.
course_id
}
`
wx
.
miniProgram
.
navigateTo
({
url
})
}
else
{
this
.
$router
.
push
({
name
:
'courseLearnItem'
,
params
:
{
id
:
data
.
course_id
}
})
}
}
}
}
...
...
src/index.html
浏览文件 @
c86f6e66
...
...
@@ -7,7 +7,7 @@
<meta
http-equiv=
"Cache-Control"
content=
"no-cache, no-store, must-revalidate"
/>
<meta
http-equiv=
"Pragma"
content=
"no-cache"
/>
<meta
http-equiv=
"Expires"
content=
"0"
/>
<title>
道路运输安全知识线上课
</title>
<title></title>
<meta
name=
"viewport"
id=
"viewport"
content=
"width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no, shrink-to-fit=no"
>
</head>
<body>
...
...
src/pages/course/tag/courseTagMessage.vue
浏览文件 @
c86f6e66
...
...
@@ -48,6 +48,9 @@ export default {
return
{
'has-more'
:
this
.
hasMore
&&
!
this
.
showMore
}
},
isWeapp
()
{
return
this
.
$store
.
state
.
isWeapp
}
},
methods
:
{
...
...
src/pages/home/index.vue
浏览文件 @
c86f6e66
...
...
@@ -38,6 +38,9 @@ import * as api from '@/api/course.js'
export
default
{
name
:
'Index'
,
components
:
{
SearchBar
,
Card
,
FreeCourseItem
},
metaInfo
:
{
title
:
'道路运输安全知识线上课'
},
data
()
{
return
{
courseList
:
[]
// 免费课程列表
...
...
src/pages/login/login.vue
浏览文件 @
c86f6e66
...
...
@@ -144,7 +144,7 @@ export default {
},
checkWechatLogin
()
{
return
!!
(
Cookies
.
get
(
'wechat_login_error'
)
&&
Cookies
.
get
(
'wechat_login_error'
)
||
Cookies
.
get
(
'wechat_login_no_phone_error'
)
)
}
...
...
src/pages/search/courseList.vue
浏览文件 @
c86f6e66
...
...
@@ -38,6 +38,11 @@ export default {
}
}
},
computed
:
{
isWeapp
()
{
return
this
.
$store
.
state
.
isWeapp
}
},
methods
:
{
getList
()
{
this
.
loaded
=
false
...
...
@@ -51,7 +56,11 @@ export default {
this
.
getList
()
},
onClick
(
data
)
{
this
.
$router
.
push
({
name
:
'courseLearnItem'
,
params
:
{
id
:
data
.
id
}
})
const
url
=
data
.
free
?
`/pages/free/item?id=
${
data
.
course_id
}
&chapter_id=
${
data
.
id
}
`
:
`/pages/web/index?src=
${
window
.
location
.
origin
}
/course/learn/
${
data
.
id
}
`
wx
.
miniProgram
.
navigateTo
({
url
})
// this.$router.push({ name: 'courseLearnItem', params: { id: data.id } })
}
},
beforeMount
()
{
...
...
src/pages/search/tagList.vue
浏览文件 @
c86f6e66
...
...
@@ -51,7 +51,9 @@ export default {
this
.
getList
()
},
onClick
(
data
)
{
this
.
$router
.
push
({
name
:
'courseTagItem'
,
params
:
{
id
:
data
.
id
}
})
const
url
=
`/pages/web/index?src=
${
window
.
location
.
origin
}
/course/tag/
${
data
.
id
}
`
wx
.
miniProgram
.
navigateTo
({
url
})
// this.$router.push({ name: 'courseTagItem', params: { id: data.id } })
}
},
beforeMount
()
{
...
...
src/pages/search/videoList.vue
浏览文件 @
c86f6e66
...
...
@@ -64,13 +64,10 @@ export default {
this
.
getList
()
},
onClick
(
data
)
{
if
(
this
.
isWeapp
)
{
wx
.
miniProgram
.
navigateTo
({
url
:
`/pages/course/item?id=
${
data
.
course_id
}
&chapter_id=
${
data
.
id
}
`
})
}
else
{
window
.
alert
(
'请在微信小程序中打开'
)
}
const
url
=
data
.
free
?
`/pages/free/item?id=
${
data
.
course_id
}
&chapter_id=
${
data
.
id
}
`
:
`/pages/course/item?id=
${
data
.
course_id
}
&chapter_id=
${
data
.
id
}
`
wx
.
miniProgram
.
navigateTo
({
url
})
}
},
beforeMount
()
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论