Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
educationStu
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
向伟
educationStu
Commits
135fc38d
Commit
135fc38d
authored
Jan 10, 2022
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
2
parent
96b0080f
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
57 additions
and
39 deletions
+57
-39
Pronunciation.vue
src/components/word/Pronunciation.vue
+2
-10
index.vue
src/pages/index/index.vue
+2
-1
studyComplete.vue
src/pages/word/studyComplete.vue
+2
-2
word.vue
src/pages/word/word.vue
+51
-26
No files found.
src/components/word/Pronunciation.vue
View file @
135fc38d
...
...
@@ -65,16 +65,8 @@
setup
(
props
)
{
const
methods
=
{
play
()
{
innerAudioContext
.
src
=
props
.
item
.
FileUrl
innerAudioContext
.
src
=
`https://fanyi.baidu.com/gettts?lan=jp&text=
${
encodeURIComponent
(
props
.
item
.
WordContent
)}
&spd=3&source=web`
innerAudioContext
.
play
()
// innerAudioContext.src =
// decodeURIComponent('http%3A%2F%2Fimgfile.oytour.com%2FEduSystem%2FTest%2FUpload%2FAttachment%2F20210413060328967.mp3')
// if(innerAudioContext.pause){
// }else{
// innerAudioContext.pause()
// }
// console.log(innerAudioContext)
}
}
return
{
...
...
@@ -168,4 +160,4 @@
color
:
#B8B8B8
;
text-align
:
center
;
}
</
style
>
</
style
>
\ No newline at end of file
src/pages/index/index.vue
View file @
135fc38d
...
...
@@ -107,7 +107,7 @@
</view>
<view
v-for=
"(item,index) in pageData.LearningGardenList"
:key=
"index"
v-if=
"item.List.length>0"
>
<view
class=
"learningGardenTitle"
>
{{
item
.
Name
}}
<text>
{{
item
.
Name
}}
</text>
</view>
<view
class=
"gardenCon"
v-for=
"(item1,index1) in item.List"
:key=
"index1"
id=
"img"
>
<image
:src=
"item1.Img"
mode=
"aspectFill"
...
...
@@ -524,6 +524,7 @@
font-weight
:
800
;
color
:
#111111
;
margin-bottom
:
35
rpx
;
display
:
flex
;
}
.gardenCon
{
...
...
src/pages/word/studyComplete.vue
View file @
135fc38d
...
...
@@ -143,7 +143,7 @@
<view
class=
"studyCompleta"
>
<view
class=
"stuComTop"
>
<view
style=
"margin-left:20rpx;flex-shrink: 0;"
>
<van-icon
name=
"arrow-left"
color=
"#FFF"
@
click=
"
back
"
/>
<van-icon
name=
"arrow-left"
color=
"#FFF"
@
click=
"
goIndex
"
/>
</view>
<view
style=
"width:100%;text-align: center;"
>
学习小结
</view>
</view>
...
...
@@ -202,7 +202,7 @@
let
methods
=
{
back
()
{
uni
.
redirectTo
({
url
:
'/pages/
index/index
'
url
:
'/pages/
word/word
'
})
},
goIndex
(){
...
...
src/pages/word/word.vue
View file @
135fc38d
<
template
>
<view
class=
"word"
>
<swiper
class=
"swiper"
next-margin=
"60rpx"
@
change=
"swiperChange"
:current=
"
85
"
>
<swiper-item
v-for=
"(item,index) in StudyList"
:key=
"index"
class=
"swiper-item"
>
<swiper
class=
"swiper"
next-margin=
"60rpx"
@
change=
"swiperChange"
:current=
"
current
"
>
<swiper-item
v-for=
"(item,index) in StudyList"
:key=
"index"
class=
"swiper-item"
>
<Pronunciation
:item=
"item"
:cur=
"index+1"
:total=
"StudyList.length"
></Pronunciation>
</swiper-item>
<swiper-item
v-for=
"(item,index) in ReviewList"
:key=
"index"
class=
"swiper-item"
>
<swiper-item
v-for=
"(item,index) in ReviewList"
:key=
"index"
class=
"swiper-item"
>
<Pronunciation
:item=
"item"
:cur=
"index+1"
:total=
"ReviewList.length"
:type=
"1"
></Pronunciation>
</swiper-item>
<swiper-item></swiper-item>
</swiper>
</view>
</
template
>
...
...
@@ -29,30 +30,48 @@
Pronunciation
},
setup
(
props
)
{
let
{
proxy
}
=
getCurrentInstance
();
let
{
proxy
}
=
getCurrentInstance
();
let
data
=
reactive
({
test
:
[
1
,
2
,
3
],
msg
:{
ChapterId
:
0
,
CourseId
:
0
,
PrevChapterId
:
0
,
test
:
[
1
,
2
,
3
],
msg
:
{
ChapterId
:
0
,
CourseId
:
0
,
PrevChapterId
:
0
,
},
StudyList
:[],
ReviewList
:[],
StudyList
:
[],
ReviewList
:
[],
current
:
0
,
readMsg
:
{
Id
:
0
,
ClassId
:
1
,
CourseId
:
1
,
Stu_Account_Id
:
1
,
ChapterId
:
1
,
StudyNum
:
1
}
})
let
methods
=
{
getData
(){
proxy
.
$request
(
'/AppletWords/GetStudyWords'
,
data
.
msg
).
then
(
res
=>
{
data
.
StudyList
=
res
.
Data
.
StudyList
data
.
ReviewList
=
res
.
Data
.
ReviewList
})
getData
()
{
proxy
.
$request
(
'/AppletWords/GetStudyWords'
,
data
.
msg
).
then
(
res
=>
{
data
.
StudyList
=
res
.
Data
.
StudyList
data
.
ReviewList
=
res
.
Data
.
ReviewList
})
},
swiperChange
(
val
){
const
total
=
data
.
StudyList
.
length
+
data
.
ReviewList
.
length
if
(
val
.
detail
.
current
+
1
==
total
&&
total
>
0
){
console
.
log
(
val
,
1111111111111111111
)
swiperChange
(
val
)
{
const
total
=
data
.
StudyList
.
length
+
data
.
ReviewList
.
length
+
1
if
(
val
.
detail
.
current
+
1
==
total
&&
total
>
1
)
{
uni
.
navigateTo
({
url
:
"/pages/word/studyComplete"
})
}
},
completeRead
()
{
proxy
.
$request
(
'/AppletWords/SetStuWordsPrep'
,
)
}
}
onMounted
(()
=>
{
...
...
@@ -67,10 +86,14 @@
uni
.
setNavigationBarTitle
({
title
:
'新的标题'
});
this
.
msg
.
ChapterId
=
options
.
ChapterId
this
.
msg
.
CourseId
=
options
.
CourseId
this
.
msg
.
PrevChapterId
=
options
.
PrevChapterId
this
.
msg
.
ChapterId
=
options
.
ChapterId
this
.
msg
.
CourseId
=
options
.
CourseId
this
.
msg
.
PrevChapterId
=
options
.
PrevChapterId
this
.
readMsg
.
CourseId
=
options
.
CourseId
this
.
readMsg
.
ChapterId
=
options
.
ChapterId
this
.
getData
()
const
userInfo
=
uni
.
getStorageSync
(
'userinfo'
);
this
.
readMsg
.
Stu_Account_Id
=
userInfo
.
AccountId
},
}
</
script
>
...
...
@@ -80,13 +103,15 @@
min-height
:
100vh
;
background-color
:
#F5F5F5
;
}
.word
.swiper
{
.word
.swiper
{
min-height
:
100vh
;
background-color
:
#F5F5F5
;
}
.word
.swiper-item
{
.word
.swiper-item
{
min-height
:
100vh
;
background-color
:
#F5F5F5
;
/* padding-left: 55rpx; */
}
</
style
>
\ No newline at end of file
</
style
>
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