Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
study
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
Damon
study
Commits
ede5d1ba
Commit
ede5d1ba
authored
Jul 26, 2021
by
Damon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 学习模式弹出提示
parent
507a9388
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
5 deletions
+13
-5
answer.vue
src/pages/learn/answer.vue
+13
-5
No files found.
src/pages/learn/answer.vue
View file @
ede5d1ba
...
@@ -378,11 +378,20 @@ export default {
...
@@ -378,11 +378,20 @@ export default {
changeModel
(
i
)
{
changeModel
(
i
)
{
this
.
model
=
i
this
.
model
=
i
if
(
this
.
model
===
2
)
{
this
.
showTip
()
}
},
},
timeEnd
()
{
timeEnd
()
{
this
.
complete
.
timeout
=
true
this
.
complete
.
timeout
=
true
this
.
handPapers
()
this
.
handPapers
()
},
},
showTip
()
{
if
(
!
this
.
tipStatus
)
{
this
.
$u
.
vuex
(
'tipStatus'
,
true
)
this
.
show
=
true
}
},
// 作答完毕
// 作答完毕
answerChange
(
status
,
lists
,
userAnswer
)
{
answerChange
(
status
,
lists
,
userAnswer
)
{
// 保存答题状态
// 保存答题状态
...
@@ -396,15 +405,14 @@ export default {
...
@@ -396,15 +405,14 @@ export default {
if
(
this
.
model
===
1
)
this
.
saveAnswer
(
item
)
if
(
this
.
model
===
1
)
this
.
saveAnswer
(
item
)
// 滑动提示
// 滑动提示
if
(
!
this
.
tipStatus
&&
status
===
'fail'
)
{
if
(
status
===
'fail'
)
{
this
.
$u
.
vuex
(
'tipStatus'
,
true
)
this
.
showTip
()
this
.
show
=
true
}
}
// 顺序练习,更新答题卡
// 顺序练习,更新答题卡
if
(
this
.
source
===
1
){
if
(
this
.
source
===
1
){
this
.
questionList
[
this
.
questionWarehouseId
][
this
.
currentIndex
]
=
item
this
.
questionList
[
this
.
questionWarehouseId
][
this
.
currentIndex
]
=
item
this
.
$u
.
vuex
(
`questionList.
${
this
.
questionWarehouseId
}
`
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
questionList
[
this
.
questionWarehouseId
]))
)
this
.
$u
.
vuex
(
`questionList.
${
this
.
questionWarehouseId
}
`
,
this
.
questionList
[
this
.
questionWarehouseId
]
)
this
.
$u
.
vuex
(
`lastIndex.
${
this
.
questionWarehouseId
}
`
,
this
.
currentIndex
)
this
.
$u
.
vuex
(
`lastIndex.
${
this
.
questionWarehouseId
}
`
,
this
.
currentIndex
)
// 统计是否达满所有试题
// 统计是否达满所有试题
...
@@ -516,7 +524,7 @@ export default {
...
@@ -516,7 +524,7 @@ export default {
info
.
collectionFlag
=
!
status
info
.
collectionFlag
=
!
status
if
(
this
.
source
===
1
)
{
//更新缓存数据
if
(
this
.
source
===
1
)
{
//更新缓存数据
this
.
questionList
[
this
.
questionWarehouseId
][
this
.
currentIndex
]
=
info
this
.
questionList
[
this
.
questionWarehouseId
][
this
.
currentIndex
]
=
info
this
.
$u
.
vuex
(
`questionList.
${
this
.
questionWarehouseId
}
`
,
JSON
.
parse
(
JSON
.
stringify
(
this
.
questionList
[
this
.
questionWarehouseId
]))
)
this
.
$u
.
vuex
(
`questionList.
${
this
.
questionWarehouseId
}
`
,
this
.
questionList
[
this
.
questionWarehouseId
]
)
}
}
}
}
})
})
...
...
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