Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
self-support
Project
Project
Details
Activity
Releases
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
李俊赕
self-support
Commits
10cc678c
Commit
10cc678c
authored
May 09, 2021
by
林文清
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update:学习模块
parent
d22a0f28
Changes
6
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
188 additions
and
158 deletions
+188
-158
pages.json
src/pages.json
+6
-3
learn.vue
src/pages/index/learn.vue
+90
-92
news-details.vue
src/pages/learn/news-details.vue
+28
-40
section.vue
src/pages/learn/section.vue
+64
-23
jianbian@3x.png
src/static/photo/jianbian@3x.png
+0
-0
jianbian@3x_bak.png
src/static/photo/jianbian@3x_bak.png
+0
-0
No files found.
src/pages.json
View file @
10cc678c
...
...
@@ -26,7 +26,8 @@
"path"
:
"pages/index/learn"
,
"style"
:
{
"navigationBarTitleText"
:
"学习"
,
"navigationStyle"
:
"custom"
//隐藏系统导航栏
"navigationStyle"
:
"custom"
,
//隐藏系统导航栏
"disableScroll"
:
true
}
},
{
...
...
@@ -89,13 +90,15 @@
{
"path"
:
"news-details"
,
"style"
:
{
"navigationBarTitleText"
:
""
"navigationBarTitleText"
:
""
,
"navigationStyle"
:
"default"
}
},
{
"path"
:
"section"
,
"style"
:{
"navigationBarTitleText"
:
""
"navigationBarTitleText"
:
""
,
"navigationStyle"
:
"default"
}
},
{
...
...
src/pages/index/learn.vue
View file @
10cc678c
This diff is collapsed.
Click to expand it.
src/pages/learn/news-details.vue
View file @
10cc678c
<
template
>
<view>
<view
class=
"title"
>
{{
newsInfo
.
title
}}
</view>
<view>
<view
class=
"title"
>
{{
title
}}
</view>
<view
class=
"u-content"
>
<u-parse
:html=
"newsInfo.
body"
:tag-style=
"style"
></u-parse>
</view>
</view>
<u-parse
:html=
"
body"
:tag-style=
"style"
></u-parse>
</view>
</view>
</
template
>
<
script
>
export
default
{
data
()
{
return
{
banner
:{},
obj
:{
},
newsInfo
:
{
title
:
''
,
body
:
''
}
}
},
methods
:
{
},
onLoad
()
{
},
onShow
(){
uni
.
$on
(
'news'
,(
news
)
=>
{
this
.
newsInfo
=
news
;
console
.
log
(
news
,
'news'
)
})
},
onLoad
()
{
this
.
$u
.
mpShare
.
path
=
''
},
}
export
default
{
data
()
{
return
{
title
:
''
,
body
:
''
}
},
onLoad
()
{
var
that
=
this
;
const
eventChannel
=
this
.
getOpenerEventChannel
()
eventChannel
.
on
(
'acceptDataFromLearn'
,
function
(
data
)
{
that
.
title
=
data
.
title
;
that
.
body
=
data
.
body
;
})
this
.
$u
.
mpShare
.
path
=
''
},
}
</
script
>
<
style
>
.title
{
.title
{
font-size
:
32
rpx
;
font-weight
:
bold
;
margin-left
:
30
rpx
;
margin-top
:
30
rpx
;
}
.
content
{
}
.u-
content
{
font-size
:
24
rpx
;
line-height
:
36
rpx
;
color
:
#666666
;
margin-left
:
30
rpx
;
margin-top
:
30
rpx
;
}
}
</
style
>
src/pages/learn/section.vue
View file @
10cc678c
...
...
@@ -18,23 +18,28 @@
<view
class=
"learn-view"
v-if=
"courseId >= 0"
>
<view
class=
"learn-view-title color-teacher"
>
课程讲师
</view>
<view
class=
""
style=
"padding-top: 30rpx;display: flex;padding-left: 30rpx;"
>
<u-avatar
:style=
"
{'width':'100rpx', 'height':'100rpx'}" :src="teacherImage" mode="circle">
</u-avatar>
<u-avatar
:style=
"
{'width':'100rpx', 'height':'100rpx'}" :src="teacherImage" mode="circle">
</u-avatar>
<view
style=
"height:120rpx;font-size: 30rpx;padding-left:30rpx;"
>
<view
class=
""
style=
"display: flex;font-size: 32rpx;"
>
<view
class=
""
style=
"font-size: 32rpx;font-weight: bold;"
>
{{
teacher
.
name
}}
</view>
<view
class=
""
style=
"font-size: 24rpx;margin-left: 30rpx;margin-top: 6rpx;color: #999999;"
>
课程讲师
</view>
<view
class=
""
style=
"font-size: 24rpx;margin-left: 30rpx;margin-top: 6rpx;color: #999999;"
>
课程讲师
</view>
</view>
<view
class=
""
style=
"font-size: 24rpx;margin-top: 30rpx;"
>
{{
teacherIntro
}}
</view>
</view>
</view>
<view
class=
"learn-view-title"
>
目录
</view>
<view
class=
"
"
style=
"display: flex;overflow: auto;padding-top: 30rpx;padding-bottom: 30rpx;
"
>
<view
class=
"
catalogue
"
>
<view
v-for=
"(item, index) in list"
:key=
"index"
>
<view
@
click=
"goNext(item)"
class=
"list-cell list-default"
:class=
"
{'list-default-active': item.isActive}" style="width:280rpx;height:150rpx;margin-left: 20rpx;padding: 20rpx;border-radius: 12rpx;">
<view
@
click=
"goNext(item)"
class=
"list-cell list-default"
:class=
"
{'list-default-active': item.isActive}"
style="width:280rpx;height:150rpx;margin-left: 20rpx;padding: 20rpx;border-radius: 12rpx;">
<view
class=
""
style=
"font-size: 24rpx;"
>
{{
item
.
title
}}
</view>
<view
class=
""
style=
"font-size: 26rpx;margin-top: 16rpx;"
>
{{
item
.
intro
}}
{{
item
.
intro
}}
</view>
</view>
</view>
...
...
@@ -70,14 +75,41 @@
section_id
:
0
,
active_section_id
:
0
,
isShowVideo
:
false
,
CourseSectionlist
:
{
name
:
''
,
content
:
''
},
//节信息
list
:
[
{
'title'
:
'第1节'
,
'intro'
:
'考核规则1:接单及 时率'
,
'isActive'
:
true
,
"id"
:
null
},
{
'title'
:
'第2节'
,
'intro'
:
'考核规则1:接单及 时率'
,
'isActive'
:
false
,
"id"
:
null
},
{
'title'
:
'第3节'
,
'intro'
:
'考核规则1:接单及 时率'
,
'isActive'
:
false
,
"id"
:
null
},
{
'title'
:
'第4节'
,
'intro'
:
'考核规则1:接单及 时率'
,
'isActive'
:
false
,
"id"
:
null
},
{
'title'
:
'第5节'
,
'intro'
:
'考核规则1:接单及 时率'
,
'isActive'
:
false
,
"id"
:
null
},
],
CourseSectionlist
:
{
name
:
''
,
content
:
''
},
//节信息
list
:
[{
'title'
:
'第1节'
,
'intro'
:
'考核规则1:接单及 时率'
,
'isActive'
:
true
,
"id"
:
null
},
{
'title'
:
'第2节'
,
'intro'
:
'考核规则1:接单及 时率'
,
'isActive'
:
false
,
"id"
:
null
},
{
'title'
:
'第3节'
,
'intro'
:
'考核规则1:接单及 时率'
,
'isActive'
:
false
,
"id"
:
null
},
{
'title'
:
'第4节'
,
'intro'
:
'考核规则1:接单及 时率'
,
'isActive'
:
false
,
"id"
:
null
},
{
'title'
:
'第5节'
,
'intro'
:
'考核规则1:接单及 时率'
,
'isActive'
:
false
,
"id"
:
null
},
],
teacher
:
{
name
:
""
,
avatar
:
""
...
...
@@ -100,8 +132,8 @@
fullscreenToggle
:
true
//全屏按钮
}
},
params
:{
course_id
:
null
,
params
:
{
course_id
:
null
,
},
gklog
:
''
,
videoTotalTime
:
0
,
...
...
@@ -154,7 +186,7 @@
// #endif
},
methods
:
{
goNext
(
info
){
goNext
(
info
)
{
uni
.
navigateTo
({
url
:
"./section?section_id="
+
info
.
id
+
"&course_id="
+
info
.
course_id
});
...
...
@@ -215,7 +247,7 @@
this
.
courseSrc
=
coureWareList
[
0
].
src
;
this
.
videoTotalTime
=
parseInt
(
JSON
.
parse
(
coureWareList
[
0
].
info
).
time
);
console
.
log
(
'视频时长信息:'
+
this
.
videoTotalTime
);
}
else
{
}
else
{
this
.
updateLearnedStatusForText
();
}
}
...
...
@@ -287,10 +319,11 @@
this
.
list
=
res
.
data
[
0
].
section
;
this
.
courseTotal
=
this
.
list
.
length
;
let
length
=
this
.
list
.
length
;
for
(
let
i
=
0
;
i
<
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
length
;
i
++
)
{
this
.
list
[
i
].
title
=
"第"
+
(
i
+
1
)
+
"节"
;
this
.
list
[
i
].
intro
=
this
.
list
[
i
].
name
;
this
.
list
[
i
].
isActive
=
this
.
active_section_id
==
this
.
list
[
i
].
id
?
true
:
false
;
this
.
list
[
i
].
isActive
=
this
.
active_section_id
==
this
.
list
[
i
].
id
?
true
:
false
;
}
console
.
log
(
'--select-list--'
)
console
.
log
(
this
.
list
)
...
...
@@ -443,13 +476,13 @@
padding
:
40rpx
30rpx
;
margin-bottom
:
20rpx
;
}
.list-default
{
background-color
:
#F4F5F7
;
border-radius
:
12rpx
;
color
:
#333333
;
}
.list-default-active
{
background-color
:
#ffffff
;
border-radius
:
12rpx
;
...
...
@@ -457,8 +490,16 @@
border
:
2rpx
solid
#2272FF
;
box-sizing
:
border-box
;
}
.color-teacher
{
color
:
#999999
;
}
.catalogue
{
display
:
flex
;
overflow
:
auto
;
padding-top
:
30rpx
;
padding-bottom
:
30rpx
;
padding-right
:
30rpx
;
}
</
style
>
src/static/photo/jianbian@3x.png
View replaced file @
d22a0f28
View file @
10cc678c
7.64 KB
|
W:
|
H:
21.9 KB
|
W:
|
H:
2-up
Swipe
Onion skin
src/static/photo/jianbian@3x_bak.png
deleted
100644 → 0
View file @
d22a0f28
21.9 KB
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