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
b076f170
Commit
b076f170
authored
Sep 09, 2021
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
2b97d7aa
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
860 additions
and
760 deletions
+860
-760
Calculation.vue
src/components/subject/Calculation.vue
+5
-1
Cloze.vue
src/components/subject/Cloze.vue
+210
-189
Connect.vue
src/components/subject/Connect.vue
+168
-160
Dataquestion.vue
src/components/subject/Dataquestion.vue
+7
-1
EntryProblem.vue
src/components/subject/EntryProblem.vue
+6
-2
FillInTheBlanks.vue
src/components/subject/FillInTheBlanks.vue
+5
-1
ListenTopic.vue
src/components/subject/ListenTopic.vue
+52
-49
Other.vue
src/components/subject/Other.vue
+194
-177
SingleChoiceNumber.vue
src/components/subject/SingleChoiceNumber.vue
+4
-1
Spoken.vue
src/components/subject/Spoken.vue
+194
-177
easyQuestion.vue
src/components/subject/easyQuestion.vue
+5
-1
judge.vue
src/components/subject/judge.vue
+5
-1
readingCompre.vue
src/components/subject/readingCompre.vue
+5
-0
No files found.
src/components/subject/Calculation.vue
View file @
b076f170
...
...
@@ -68,6 +68,7 @@ export default {
sort
:
Number
,
sortTotal
:
Number
,
isLast
:
Boolean
,
startIndex
:
Number
,
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
();
...
...
@@ -82,7 +83,10 @@ export default {
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
});
if
(
props
.
startIndex
)
{
data
.
current
=
props
.
startIndex
;
data
.
ExamIndex
=
props
.
startIndex
;
}
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
...
...
src/components/subject/Cloze.vue
View file @
b076f170
<
template
>
<!-- 计算题 -->
<view>
<view
class=
"item"
style=
"padding:0 20px;"
>
<view
class=
"name"
>
<view>
{{
changeNumToHan
(
sortIndex
)
}}
、
{{
data
.
GroupName
}}
<text
style=
"color:#999999;"
>
(共
{{
data
.
DetailsList
.
length
}}
道,
{{
data
.
GScore
}}
分)
</text>
</view>
<view>
<text
class=
"Single_Before"
>
{{
ExamIndex
}}
</text>
/
<text
class=
"Exam_Total"
>
{{
data
.
DetailsList
.
length
}}
</text>
</view>
</view>
<swiper
class=
"swiper-box"
:autoplay=
"autoplay"
:current=
"current"
@
change=
"onchange"
>
<swiper-item
v-if=
"sortIndex != 1"
></swiper-item>
<swiper-item
v-for=
"(item1, index1) in data.DetailsList"
:key=
"index1"
>
<view
class=
"item1"
>
<view
class=
"flex flex_start_center"
>
<view>
{{
index1
+
1
}}
、
</view>
<view
class=
"num"
v-html=
"item1.Title"
></view>
</view>
<view
v-for=
"(item2, index2) in item1.QuestionContentObj"
:key=
"index2"
style=
"border-bottom:1px solid #d1d1d1;"
>
<view
v-for=
"(item3,index3) in item2.OptionList"
:key=
"index3"
class=
"flex item2 flex_start_center"
@
click=
"getAnswer(item2.OptionList,item3)"
>
<view
class=
"chooseNum"
:class=
"
{'myAnswer':item3.IsAnswer}">
{{
item3
.
Name
}}
</view>
<view
class=
"chooseName"
v-html=
"item3.Content"
></view>
</view>
</view>
</view>
</swiper-item>
<swiper-item
v-if=
"sortIndex != sortTotal"
></swiper-item>
</swiper>
</view>
<van-toast
id=
"van-toast"
/>
</view>
<!-- 计算题 -->
<view>
<view
class=
"item"
style=
"padding: 0 20px"
>
<view
class=
"name"
>
<view>
{{
changeNumToHan
(
sortIndex
)
}}
、
{{
data
.
GroupName
}}
<text
style=
"color: #999999"
>
(共
{{
data
.
DetailsList
.
length
}}
道,
{{
data
.
GScore
}}
分)
</text
>
</view>
<view>
<text
class=
"Single_Before"
>
{{
ExamIndex
}}
</text
>
/
<text
class=
"Exam_Total"
>
{{
data
.
DetailsList
.
length
}}
</text>
</view>
</view>
<swiper
class=
"swiper-box"
:autoplay=
"autoplay"
:current=
"current"
@
change=
"onchange"
>
<swiper-item
v-if=
"sortIndex != 1"
></swiper-item>
<swiper-item
v-for=
"(item1, index1) in data.DetailsList"
:key=
"index1"
>
<view
class=
"item1"
>
<view
class=
"flex flex_start_center"
>
<view>
{{
index1
+
1
}}
、
</view>
<view
class=
"num"
v-html=
"item1.Title"
></view>
</view>
<view
v-for=
"(item2, index2) in item1.QuestionContentObj"
:key=
"index2"
style=
"border-bottom: 1px solid #d1d1d1"
>
<view
v-for=
"(item3, index3) in item2.OptionList"
:key=
"index3"
class=
"flex item2 flex_start_center"
@
click=
"getAnswer(item2.OptionList, item3)"
>
<view
class=
"chooseNum"
:class=
"
{ myAnswer: item3.IsAnswer }"
>
{{
item3
.
Name
}}
</view>
<view
class=
"chooseName"
v-html=
"item3.Content"
></view>
</view>
</view>
</view>
</swiper-item>
<swiper-item
v-if=
"sortIndex != sortTotal"
></swiper-item>
</swiper>
</view>
<van-toast
id=
"van-toast"
/>
</view>
</
template
>
<
script
>
import
{
ref
,
reactive
,
toRefs
,
toRef
,
getCurrentInstance
,
watch
,
computed
,
onMounted
,
}
from
"vue"
;
import
{
changeNumToHan
}
from
"../../utils/index"
;
export
default
{
props
:
{
paperData
:
Object
,
sort
:
Number
,
sortTotal
:
Number
,
isLast
:
Boolean
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
();
let
data
=
reactive
({
data
:
props
.
paperData
,
autoplay
:
false
,
sortIndex
:
props
.
sort
+
1
,
sortTotal
:
props
.
sortTotal
,
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
});
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
uni
.
navigateTo
({
url
:
"/pages/exam/examPaper"
,
});
},
back
()
{
uni
.
navigateBack
();
},
onchange
(
e
)
{
data
.
ExamIndex
=
e
.
detail
.
current
;
if
(
data
.
ExamIndex
===
data
.
data
.
DetailsList
.
length
+
1
)
{
console
.
log
(
'进入'
)
this
.
$emit
(
'getAfterTopic'
);
}
if
(
e
.
detail
.
current
==
0
)
{
this
.
$emit
(
'getBeforeTopic'
);
}
},
//点击
getAnswer
(
allItem
,
item
){
allItem
.
forEach
(
x
=>
{
x
.
IsAnswer
=
false
;
})
item
.
IsAnswer
=
!
item
.
IsAnswer
;
this
.
$forceUpdate
();
}
};
onMounted
(()
=>
{
if
(
props
.
isLast
)
{
data
.
current
=
props
.
paperData
.
DetailsList
.
length
;
}
})
let
that
=
methods
;
return
{
...
toRefs
(
data
),
...
methods
,
};
},
};
import
{
ref
,
reactive
,
toRefs
,
toRef
,
getCurrentInstance
,
watch
,
computed
,
onMounted
,
}
from
"vue"
;
import
{
changeNumToHan
}
from
"../../utils/index"
;
export
default
{
props
:
{
paperData
:
Object
,
sort
:
Number
,
sortTotal
:
Number
,
isLast
:
Boolean
,
startIndex
:
Number
,
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
();
let
data
=
reactive
({
data
:
props
.
paperData
,
autoplay
:
false
,
sortIndex
:
props
.
sort
+
1
,
sortTotal
:
props
.
sortTotal
,
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
});
if
(
props
.
startIndex
)
{
data
.
current
=
props
.
startIndex
;
data
.
ExamIndex
=
props
.
startIndex
;
}
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
uni
.
navigateTo
({
url
:
"/pages/exam/examPaper"
,
});
},
back
()
{
uni
.
navigateBack
();
},
onchange
(
e
)
{
data
.
ExamIndex
=
e
.
detail
.
current
;
if
(
data
.
ExamIndex
===
data
.
data
.
DetailsList
.
length
+
1
)
{
console
.
log
(
"进入"
);
this
.
$emit
(
"getAfterTopic"
);
}
if
(
e
.
detail
.
current
==
0
)
{
this
.
$emit
(
"getBeforeTopic"
);
}
},
//点击
getAnswer
(
allItem
,
item
)
{
allItem
.
forEach
((
x
)
=>
{
x
.
IsAnswer
=
false
;
});
item
.
IsAnswer
=
!
item
.
IsAnswer
;
this
.
$forceUpdate
();
},
};
onMounted
(()
=>
{
if
(
props
.
isLast
)
{
data
.
current
=
props
.
paperData
.
DetailsList
.
length
;
}
});
let
that
=
methods
;
return
{
...
toRefs
(
data
),
...
methods
,
};
},
};
</
script
>
<
style
scoped
>
.name
{
height
:
90
rpx
;
font-size
:
28
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
800
;
color
:
#111111
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
}
.Exam_Total
{
font-size
:
25
rpx
;
color
:
gray
;
}
.myAnswer
{
background-color
:
#00acf9
!important
;
color
:
#ffffff
!important
;
}
.Single_Before
{
font-size
:
28
rpx
;
font-weight
:
bold
;
color
:
#DA
7878
;
}
.name
{
height
:
90
rpx
;
font-size
:
28
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
800
;
color
:
#111111
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
}
.Exam_Total
{
font-size
:
25
rpx
;
color
:
gray
;
}
.myAnswer
{
background-color
:
#00acf9
!important
;
color
:
#ffffff
!important
;
}
.Single_Before
{
font-size
:
28
rpx
;
font-weight
:
bold
;
color
:
#da
7878
;
}
.swiper-box
{
height
:
calc
(
100vh
-
270
rpx
);
box-sizing
:
border-box
;
}
.swiper-box
{
height
:
calc
(
100vh
-
270
rpx
);
box-sizing
:
border-box
;
}
.num
{
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.num
{
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.item
{
margin-bottom
:
40
rpx
;
}
.item
{
margin-bottom
:
40
rpx
;
}
.item1
{
align-items
:
center
;
}
.item1
{
align-items
:
center
;
}
.item2
{
/* padding-left: 25rpx; */
margin
:
30
rpx
0
;
}
.item2
{
/* padding-left: 25rpx; */
margin
:
30
rpx
0
;
}
.choose
{
background-color
:
#00acf9
!important
;
color
:
#ffffff
!important
;
}
.choose
{
background-color
:
#00acf9
!important
;
color
:
#ffffff
!important
;
}
.chooseNum
{
width
:
40
rpx
;
height
:
40
rpx
;
text-align
:
center
;
line-height
:
40
rpx
;
border-radius
:
50%
;
border
:
1px
solid
#e2e2e2
;
margin-right
:
30
rpx
;
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.chooseNum
{
width
:
40
rpx
;
height
:
40
rpx
;
text-align
:
center
;
line-height
:
40
rpx
;
border-radius
:
50%
;
border
:
1px
solid
#e2e2e2
;
margin-right
:
30
rpx
;
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.chooseName
{
font-size
:
24
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#111111
;
}
.chooseName
{
font-size
:
24
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#111111
;
}
.input
{
box-sizing
:
border-box
;
width
:
690
rpx
;
border-bottom
:
2
rpx
solid
#000
;
color
:
#000
;
font-size
:
22
rpx
;
}
.input
{
box-sizing
:
border-box
;
width
:
690
rpx
;
border-bottom
:
2
rpx
solid
#000
;
color
:
#000
;
font-size
:
22
rpx
;
}
.textarea
{
box-sizing
:
border-box
;
padding
:
20
rpx
0
;
}
.textarea
{
box-sizing
:
border-box
;
padding
:
20
rpx
0
;
}
/
deep
/
.textarea-placeholder
{
font-size
:
20
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#cccccc
;
}
/
deep
/
.textarea-placeholder
{
font-size
:
20
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#cccccc
;
}
</
style
>
src/components/subject/Connect.vue
View file @
b076f170
<
template
>
<!-- 填空题 -->
<view>
<view
class=
"item"
style=
"padding: 0 20px"
>
<view
class=
"name"
>
<view>
{{
changeNumToHan
(
sortIndex
)
}}
、
{{
data
.
GroupName
}}
</view>
<view>
<text
class=
"Single_Before"
>
{{
ExamIndex
}}
</text>
/
<text
class=
"Exam_Total"
>
{{
data
.
DetailsList
.
length
}}
</text>
</view>
</view>
<swiper
class=
"swiper-box"
:autoplay=
"autoplay"
:current=
"current"
@
change=
"onchange"
>
<swiper-item
v-if=
"sortIndex != 1"
></swiper-item>
<swiper-item
v-for=
"(item1, index1) in data.DetailsList"
:key=
"item1.id"
>
<view
class=
"item1"
>
<view
class=
"flex flex_start_center"
>
<view>
{{
index1
+
1
}}
、
</view>
<view
class=
"num"
v-html=
"item1.Title"
></view>
</view>
<!--
<view
v-for=
"(item2, index2) in item1.QuestionContentObj"
:key=
"item2.id"
<!-- 填空题 -->
<view>
<view
class=
"item"
style=
"padding: 0 20px"
>
<view
class=
"name"
>
<view>
{{
changeNumToHan
(
sortIndex
)
}}
、
{{
data
.
GroupName
}}
</view>
<view>
<text
class=
"Single_Before"
>
{{
ExamIndex
}}
</text
>
/
<text
class=
"Exam_Total"
>
{{
data
.
DetailsList
.
length
}}
</text>
</view>
</view>
<swiper
class=
"swiper-box"
:autoplay=
"autoplay"
:current=
"current"
@
change=
"onchange"
>
<swiper-item
v-if=
"sortIndex != 1"
></swiper-item>
<swiper-item
v-for=
"(item1, index1) in data.DetailsList"
:key=
"item1.id"
>
<view
class=
"item1"
>
<view
class=
"flex flex_start_center"
>
<view>
{{
index1
+
1
}}
、
</view>
<view
class=
"num"
v-html=
"item1.Title"
></view>
</view>
<!--
<view
v-for=
"(item2, index2) in item1.QuestionContentObj"
:key=
"item2.id"
class=
"flex item2 flex_start_center"
>
<view
class=
"chooseName"
@
click=
"change(index1, index2)"
>
<input
type=
"text"
v-model=
"item1.myAnswer"
class=
"input"
/>
</view>
</view>
-->
</view>
</swiper-item>
<swiper-item
v-if=
"sortIndex != sortTotal"
></swiper-item>
</swiper>
</view>
<van-toast
id=
"van-toast"
/>
</view>
</view>
</swiper-item>
<swiper-item
v-if=
"sortIndex != sortTotal"
></swiper-item>
</swiper>
</view>
<van-toast
id=
"van-toast"
/>
</view>
</
template
>
<
script
>
import
{
ref
,
reactive
,
toRefs
,
toRef
,
getCurrentInstance
,
watch
,
computed
,
onMounted
,
}
from
"vue"
;
import
{
changeNumToHan
}
from
"../../utils/index"
;
export
default
{
props
:
{
paperData
:
Object
,
isLast
:
Boolean
,
sort
:
Number
,
sortTotal
:
Number
,
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
(
);
props
.
paperData
.
DetailsList
.
forEach
((
item
,
index
)
=>
{
item
.
myAnswer
=
""
;
});
let
data
=
reactive
({
data
:
props
.
paperData
,
sortIndex
:
props
.
sort
+
1
,
sortTotal
:
props
.
sortTotal
,
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
})
;
console
.
log
(
77
,
data
.
sortTotal
,
data
.
sortIndex
);
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
uni
.
navigateTo
({
url
:
"/pages/exam/examPaper"
,
});
},
back
()
{
uni
.
navigateBack
();
},
//选题
change
(
index1
,
index2
)
{
data
.
data
.
DetailsList
[
index1
].
choose
=
data
.
data
.
DetailsList
[
index1
].
QuestionContentObj
[
index2
].
Name
;
},
onchange
(
e
)
{
data
.
ExamIndex
=
e
.
detail
.
current
;
if
(
data
.
ExamIndex
===
data
.
data
.
DetailsList
.
length
+
1
)
{
console
.
log
(
"进入"
);
this
.
$emit
(
"getAfterTopic"
);
}
if
(
e
.
detail
.
current
==
0
)
{
this
.
$emit
(
"getBeforeTopic"
);
}
},
};
return
{
...
toRefs
(
data
),
...
methods
,
};
},
};
import
{
ref
,
reactive
,
toRefs
,
toRef
,
getCurrentInstance
,
watch
,
computed
,
onMounted
,
}
from
"vue"
;
import
{
changeNumToHan
}
from
"../../utils/index"
;
export
default
{
props
:
{
paperData
:
Object
,
isLast
:
Boolean
,
sort
:
Number
,
sortTotal
:
Number
,
startIndex
:
Number
,
}
,
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
();
props
.
paperData
.
DetailsList
.
forEach
((
item
,
index
)
=>
{
item
.
myAnswer
=
""
;
}
);
let
data
=
reactive
(
{
data
:
props
.
paperData
,
sortIndex
:
props
.
sort
+
1
,
sortTotal
:
props
.
sortTotal
,
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
});
if
(
props
.
startIndex
)
{
data
.
current
=
props
.
startIndex
;
data
.
ExamIndex
=
props
.
startIndex
;
}
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
uni
.
navigateTo
({
url
:
"/pages/exam/examPaper"
,
});
},
back
()
{
uni
.
navigateBack
();
},
//选题
change
(
index1
,
index2
)
{
data
.
data
.
DetailsList
[
index1
].
choose
=
data
.
data
.
DetailsList
[
index1
].
QuestionContentObj
[
index2
].
Name
;
},
onchange
(
e
)
{
data
.
ExamIndex
=
e
.
detail
.
current
;
if
(
data
.
ExamIndex
===
data
.
data
.
DetailsList
.
length
+
1
)
{
console
.
log
(
"进入"
);
this
.
$emit
(
"getAfterTopic"
);
}
if
(
e
.
detail
.
current
==
0
)
{
this
.
$emit
(
"getBeforeTopic"
);
}
},
};
return
{
...
toRefs
(
data
),
...
methods
,
};
},
};
</
script
>
<
style
scoped
>
.name
{
height
:
90
rpx
;
font-size
:
28
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
800
;
color
:
#111111
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
}
.name
{
height
:
90
rpx
;
font-size
:
28
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
800
;
color
:
#111111
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
}
.Single_Before
{
font-size
:
28
rpx
;
font-weight
:
bold
;
color
:
#da7878
;
}
.Single_Before
{
font-size
:
28
rpx
;
font-weight
:
bold
;
color
:
#da7878
;
}
.Exam_Total
{
font-size
:
25
rpx
;
color
:
gray
;
}
.Exam_Total
{
font-size
:
25
rpx
;
color
:
gray
;
}
.swiper-box
{
height
:
calc
(
100vh
-
270
rpx
);
box-sizing
:
border-box
;
}
.swiper-box
{
height
:
calc
(
100vh
-
270
rpx
);
box-sizing
:
border-box
;
}
.num
{
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.num
{
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.item
{
margin-bottom
:
40
rpx
;
}
.item
{
margin-bottom
:
40
rpx
;
}
.item1
{
align-items
:
center
;
}
.item1
{
align-items
:
center
;
}
.item2
{
/* padding-left: 25rpx; */
margin
:
30
rpx
0
;
}
.item2
{
/* padding-left: 25rpx; */
margin
:
30
rpx
0
;
}
.choose
{
background-color
:
#00acf9
!important
;
color
:
#ffffff
!important
;
}
.choose
{
background-color
:
#00acf9
!important
;
color
:
#ffffff
!important
;
}
.chooseNum
{
width
:
40
rpx
;
height
:
40
rpx
;
text-align
:
center
;
line-height
:
40
rpx
;
border-radius
:
50%
;
border
:
1px
solid
#e2e2e2
;
margin-right
:
30
rpx
;
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.chooseNum
{
width
:
40
rpx
;
height
:
40
rpx
;
text-align
:
center
;
line-height
:
40
rpx
;
border-radius
:
50%
;
border
:
1px
solid
#e2e2e2
;
margin-right
:
30
rpx
;
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.chooseName
{
font-size
:
24
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#111111
;
}
.chooseName
{
font-size
:
24
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#111111
;
}
.input
{
box-sizing
:
border-box
;
width
:
690
rpx
;
border-bottom
:
2
rpx
solid
#000
;
}
.input
{
box-sizing
:
border-box
;
width
:
690
rpx
;
border-bottom
:
2
rpx
solid
#000
;
}
</
style
>
src/components/subject/Dataquestion.vue
View file @
b076f170
...
...
@@ -37,7 +37,12 @@
class=
"flex item2 flex_start_center"
>
<view
class=
"chooseName"
>
<input
type=
"text"
v-model=
"item2.Content"
:placeholder=
"'请填写第 '+(index2+1)+' 空答案'"
class=
"input"
/>
<input
type=
"text"
v-model=
"item2.Content"
:placeholder=
"'请填写第 ' + (index2 + 1) + ' 空答案'"
class=
"input"
/>
</view>
</view>
</view>
...
...
@@ -67,6 +72,7 @@ export default {
sort
:
Number
,
sortTotal
:
Number
,
isLast
:
Boolean
,
startIndex
:
Number
,
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
();
...
...
src/components/subject/EntryProblem.vue
View file @
b076f170
...
...
@@ -38,7 +38,7 @@
type=
"text"
v-model=
"item2.Content"
class=
"input"
:placeholder=
"'请填写第 '+(index2+1)+
' 空答案'"
:placeholder=
"'请填写第 ' + (index2 + 1) +
' 空答案'"
@
input=
"input($event, item2)"
/>
</view>
...
...
@@ -70,6 +70,7 @@ export default {
sort
:
Number
,
sortTotal
:
Number
,
isLast
:
Boolean
,
startIndex
:
Number
,
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
();
...
...
@@ -84,7 +85,10 @@ export default {
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
});
if
(
props
.
startIndex
)
{
data
.
current
=
props
.
startIndex
;
data
.
ExamIndex
=
props
.
startIndex
;
}
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
...
...
src/components/subject/FillInTheBlanks.vue
View file @
b076f170
...
...
@@ -58,6 +58,7 @@ export default {
isLast
:
Boolean
,
sort
:
Number
,
sortTotal
:
Number
,
startIndex
:
Number
,
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
();
...
...
@@ -71,7 +72,10 @@ export default {
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
});
console
.
log
(
77
,
data
.
sortTotal
,
data
.
sortIndex
);
if
(
props
.
startIndex
)
{
data
.
current
=
props
.
startIndex
;
data
.
ExamIndex
=
props
.
startIndex
;
}
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
...
...
src/components/subject/ListenTopic.vue
View file @
b076f170
...
...
@@ -34,14 +34,14 @@
style=
"width: 26rpx; height: 22rpx"
src=
"https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/educationStu/horn.png"
/>
<van-count-down
:time=
"audioTime"
:auto-start=
"false"
class=
"flex flex_center_center"
style=
"color:#00acf9;
"
ref=
"listenCountdown"
format=
"mm:ss"
/>
<van-count-down
:time=
"audioTime"
:auto-start=
"false"
class=
"flex flex_center_center"
style=
"color: #00acf9
"
ref=
"listenCountdown"
format=
"mm:ss"
/>
</view>
</view>
<view
class=
"questionView"
>
...
...
@@ -149,17 +149,18 @@ import {
}
from
"vue"
;
import
{
changeNumToHan
}
from
"../../utils/index"
;
const
innerAudioContext
=
uni
.
createInnerAudioContext
();
innerAudioContext
.
autoplay
=
true
innerAudioContext
.
autoplay
=
true
;
export
default
{
props
:
{
paperData
:
Object
,
sort
:
Number
,
sortTotal
:
Number
,
isLast
:
Boolean
,
startIndex
:
Number
,
},
setup
(
props
,
context
)
{
let
{
refs
}
=
getCurrentInstance
();
let
{
refs
}
=
getCurrentInstance
();
let
data
=
reactive
({
autoplay
:
false
,
sortIndex
:
props
.
sort
+
1
,
//大题序号
...
...
@@ -167,8 +168,8 @@ export default {
data
:
props
.
paperData
,
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
audioTime
:
60
*
60
*
1000
,
isPlay
:
true
,
audioTime
:
60
*
60
*
1000
,
isPlay
:
true
,
});
data
.
data
.
DetailsList
.
map
((
item
)
=>
{
let
arr
=
item
.
Title
.
split
(
" "
);
//按空格分段
...
...
@@ -185,7 +186,10 @@ export default {
}
});
});
if
(
props
.
startIndex
)
{
data
.
current
=
props
.
startIndex
;
data
.
ExamIndex
=
props
.
startIndex
;
}
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
...
...
@@ -199,31 +203,30 @@ export default {
audioManage
(
url
)
{
innerAudioContext
.
src
=
url
;
console
.
log
(
188
,
innerAudioContext
);
innerAudioContext
.
onCanplay
(()
=>
{
// 必须。可以当做是初始化时长
innerAudioContext
.
duration
;
// 必须。不然也获取不到时长
setTimeout
(()
=>
{
let
t
=
innerAudioContext
.
duration
// let m=parseInt(t/60)
<
10
?
'0'
+
parseInt
(
t
/
60
):
parseInt
(
t
/
60
)
// let s=parseInt(t%60)
<
10
?
'0'
+
parseInt
(
t
%
60
):
parseInt
(
t
%
60
)
data
.
audioTime
=
t
*
1000
console
.
log
(
207
,
t
,
data
.
audioTime
);
// 401.475918
},
100
)
})
if
(
data
.
isPlay
)
{
innerAudioContext
.
play
();
// refs.listenCountdown.start();
console
.
log
(
"开始播放"
);
data
.
isPlay
=
false
}
else
{
innerAudioContext
.
stop
();
console
.
log
(
"停了"
);
data
.
isPlay
=
true
}
// console.log(189, innerAudioContext.duration);
innerAudioContext
.
onCanplay
(()
=>
{
// 必须。可以当做是初始化时长
innerAudioContext
.
duration
;
// 必须。不然也获取不到时长
setTimeout
(()
=>
{
let
t
=
innerAudioContext
.
duration
;
// let m=parseInt(t/60)
<
10
?
'0'
+
parseInt
(
t
/
60
):
parseInt
(
t
/
60
)
// let s=parseInt(t%60)
<
10
?
'0'
+
parseInt
(
t
%
60
):
parseInt
(
t
%
60
)
data
.
audioTime
=
t
*
1000
;
console
.
log
(
207
,
t
,
data
.
audioTime
);
// 401.475918
},
100
);
});
if
(
data
.
isPlay
)
{
innerAudioContext
.
play
();
// refs.listenCountdown.start();
console
.
log
(
"开始播放"
);
data
.
isPlay
=
false
;
}
else
{
innerAudioContext
.
stop
();
console
.
log
(
"停了"
);
data
.
isPlay
=
true
;
}
// console.log(189, innerAudioContext.duration);
innerAudioContext
.
onError
((
res
)
=>
{
console
.
log
(
res
.
errMsg
);
console
.
log
(
res
.
errCode
);
...
...
@@ -255,8 +258,8 @@ export default {
}
},
onchange
(
e
)
{
data
.
audioTime
=
"00:00"
innerAudioContext
.
stop
();
data
.
audioTime
=
"00:00"
;
innerAudioContext
.
stop
();
data
.
ExamIndex
=
e
.
detail
.
current
;
if
(
data
.
ExamIndex
===
data
.
data
.
DetailsList
.
length
+
1
)
{
console
.
log
(
"听力"
,
e
.
detail
);
...
...
@@ -268,15 +271,15 @@ export default {
},
};
onMounted
(()
=>
{
console
.
log
(
'refs'
,
refs
)
console
.
log
(
"refs"
,
refs
);
if
(
props
.
isLast
)
{
data
.
current
=
props
.
paperData
.
DetailsList
.
length
;
}
});
onUnmounted
(()
=>
{
innerAudioContext
.
stop
();
data
.
isPlay
=
true
});
onUnmounted
(()
=>
{
innerAudioContext
.
stop
();
data
.
isPlay
=
true
;
});
let
that
=
methods
;
return
{
...
toRefs
(
data
),
...
...
@@ -386,8 +389,8 @@ export default {
font-weight
:
bold
;
color
:
#111111
;
}
.listen
.van-count-down
{
font-size
:
22
rpx
!important
;
color
:
#00acf9
!important
;
.listen
.van-count-down
{
font-size
:
22
rpx
!important
;
color
:
#00acf9
!important
;
}
</
style
>
src/components/subject/Other.vue
View file @
b076f170
<
template
>
<!-- 计算题 -->
<view>
<view
class=
"item"
style=
"padding:0 20px;"
>
<view
class=
"name"
>
<view>
{{
changeNumToHan
(
sortIndex
)
}}
、
{{
data
.
GroupName
}}
<text
style=
"color:#999999;"
>
(共
{{
data
.
DetailsList
.
length
}}
道,
{{
data
.
GScore
}}
分)
</text>
</view>
<view>
<text
class=
"Single_Before"
>
{{
ExamIndex
}}
</text>
/
<text
class=
"Exam_Total"
>
{{
data
.
DetailsList
.
length
}}
</text>
</view>
</view>
<swiper
class=
"swiper-box"
:autoplay=
"autoplay"
:current=
"current"
@
change=
"onchange"
>
<swiper-item
v-if=
"sortIndex != 1"
></swiper-item>
<swiper-item
v-for=
"(item1, index1) in data.DetailsList"
:key=
"item1.id"
>
<view
class=
"item1"
>
<view
class=
"flex flex_start_center"
>
<view>
{{
index1
+
1
}}
、
</view>
<view
class=
"num"
v-html=
"item1.Title"
></view>
</view>
<view
class=
"chooseName"
>
<textarea
type=
"text"
v-model=
"item1.myAnswer"
class=
"input textarea"
placeholder=
"请填写答案"
placeholder-style=
"textarea-placeholder"
:maxlength=
"-1"
/>
</view>
</view>
</swiper-item>
<swiper-item
v-if=
"sortIndex != sortTotal"
></swiper-item>
</swiper>
</view>
<van-toast
id=
"van-toast"
/>
</view>
<!-- 计算题 -->
<view>
<view
class=
"item"
style=
"padding: 0 20px"
>
<view
class=
"name"
>
<view>
{{
changeNumToHan
(
sortIndex
)
}}
、
{{
data
.
GroupName
}}
<text
style=
"color: #999999"
>
(共
{{
data
.
DetailsList
.
length
}}
道,
{{
data
.
GScore
}}
分)
</text
>
</view>
<view>
<text
class=
"Single_Before"
>
{{
ExamIndex
}}
</text
>
/
<text
class=
"Exam_Total"
>
{{
data
.
DetailsList
.
length
}}
</text>
</view>
</view>
<swiper
class=
"swiper-box"
:autoplay=
"autoplay"
:current=
"current"
@
change=
"onchange"
>
<swiper-item
v-if=
"sortIndex != 1"
></swiper-item>
<swiper-item
v-for=
"(item1, index1) in data.DetailsList"
:key=
"item1.id"
>
<view
class=
"item1"
>
<view
class=
"flex flex_start_center"
>
<view>
{{
index1
+
1
}}
、
</view>
<view
class=
"num"
v-html=
"item1.Title"
></view>
</view>
<view
class=
"chooseName"
>
<textarea
type=
"text"
v-model=
"item1.myAnswer"
class=
"input textarea"
placeholder=
"请填写答案"
placeholder-style=
"textarea-placeholder"
:maxlength=
"-1"
/>
</view>
</view>
</swiper-item>
<swiper-item
v-if=
"sortIndex != sortTotal"
></swiper-item>
</swiper>
</view>
<van-toast
id=
"van-toast"
/>
</view>
</
template
>
<
script
>
import
{
ref
,
reactive
,
toRefs
,
toRef
,
getCurrentInstance
,
watch
,
computed
,
onMounted
,
}
from
"vue"
;
import
{
changeNumToHan
}
from
"../../utils/index"
;
export
default
{
props
:
{
paperData
:
Object
,
sort
:
Number
,
sortTotal
:
Number
,
isLast
:
Boolean
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
(
);
props
.
paperData
.
DetailsList
.
forEach
((
item
,
index
)
=>
{
item
.
myAnswer
=
""
;
});
let
data
=
reactive
({
data
:
props
.
paperData
,
autoplay
:
false
,
sortIndex
:
props
.
sort
+
1
,
sortTotal
:
props
.
sortTotal
,
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
})
;
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
uni
.
navigateTo
({
url
:
"/pages/exam/examPaper"
,
});
},
back
()
{
uni
.
navigateBack
();
},
onchange
(
e
)
{
data
.
ExamIndex
=
e
.
detail
.
current
;
if
(
data
.
ExamIndex
===
data
.
data
.
DetailsList
.
length
+
1
)
{
console
.
log
(
'进入'
)
this
.
$emit
(
'getAfterTopic'
);
}
if
(
e
.
detail
.
current
==
0
)
{
this
.
$emit
(
'getBeforeTopic'
);
}
}
};
onMounted
(()
=>
{
if
(
props
.
isLast
)
{
data
.
current
=
props
.
paperData
.
DetailsList
.
length
;
}
})
let
that
=
methods
;
return
{
...
toRefs
(
data
),
...
methods
,
};
},
};
import
{
ref
,
reactive
,
toRefs
,
toRef
,
getCurrentInstance
,
watch
,
computed
,
onMounted
,
}
from
"vue"
;
import
{
changeNumToHan
}
from
"../../utils/index"
;
export
default
{
props
:
{
paperData
:
Object
,
sort
:
Number
,
sortTotal
:
Number
,
isLast
:
Boolean
,
startIndex
:
Number
,
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
();
props
.
paperData
.
DetailsList
.
forEach
((
item
,
index
)
=>
{
item
.
myAnswer
=
""
;
}
);
let
data
=
reactive
(
{
data
:
props
.
paperData
,
autoplay
:
false
,
sortIndex
:
props
.
sort
+
1
,
sortTotal
:
props
.
sortTotal
,
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
});
if
(
props
.
startIndex
)
{
data
.
current
=
props
.
startIndex
;
data
.
ExamIndex
=
props
.
startIndex
;
}
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
uni
.
navigateTo
({
url
:
"/pages/exam/examPaper"
,
});
},
back
()
{
uni
.
navigateBack
();
},
onchange
(
e
)
{
data
.
ExamIndex
=
e
.
detail
.
current
;
if
(
data
.
ExamIndex
===
data
.
data
.
DetailsList
.
length
+
1
)
{
console
.
log
(
"进入"
);
this
.
$emit
(
"getAfterTopic"
);
}
if
(
e
.
detail
.
current
==
0
)
{
this
.
$emit
(
"getBeforeTopic"
);
}
},
};
onMounted
(()
=>
{
if
(
props
.
isLast
)
{
data
.
current
=
props
.
paperData
.
DetailsList
.
length
;
}
});
let
that
=
methods
;
return
{
...
toRefs
(
data
),
...
methods
,
};
},
};
</
script
>
<
style
scoped
>
.name
{
height
:
90
rpx
;
font-size
:
28
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
800
;
color
:
#111111
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
}
.name
{
height
:
90
rpx
;
font-size
:
28
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
800
;
color
:
#111111
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
}
.Single_Before
{
font-size
:
28
rpx
;
font-weight
:
bold
;
color
:
#DA
7878
;
}
.swiper-box
{
height
:
calc
(
100vh
-
270
rpx
);
box-sizing
:
border-box
;
}
.num
{
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.Single_Before
{
font-size
:
28
rpx
;
font-weight
:
bold
;
color
:
#da
7878
;
}
.swiper-box
{
height
:
calc
(
100vh
-
270
rpx
);
box-sizing
:
border-box
;
}
.num
{
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.item
{
margin-bottom
:
40
rpx
;
}
.item
{
margin-bottom
:
40
rpx
;
}
.item1
{
margin
:
25
rpx
0
;
align-items
:
center
;
}
.item1
{
margin
:
25
rpx
0
;
align-items
:
center
;
}
.item2
{
/* padding-left: 25rpx; */
margin
:
30
rpx
0
;
}
.item2
{
/* padding-left: 25rpx; */
margin
:
30
rpx
0
;
}
.choose
{
background-color
:
#00acf9
!important
;
color
:
#ffffff
!important
;
}
.choose
{
background-color
:
#00acf9
!important
;
color
:
#ffffff
!important
;
}
.chooseNum
{
width
:
40
rpx
;
height
:
40
rpx
;
text-align
:
center
;
line-height
:
40
rpx
;
border-radius
:
50%
;
border
:
1px
solid
#e2e2e2
;
margin-right
:
30
rpx
;
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.chooseNum
{
width
:
40
rpx
;
height
:
40
rpx
;
text-align
:
center
;
line-height
:
40
rpx
;
border-radius
:
50%
;
border
:
1px
solid
#e2e2e2
;
margin-right
:
30
rpx
;
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.chooseName
{
font-size
:
24
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#111111
;
}
.chooseName
{
font-size
:
24
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#111111
;
}
.input
{
box-sizing
:
border-box
;
width
:
690
rpx
;
border-bottom
:
2
rpx
solid
#000
;
color
:
#000
;
font-size
:
22
rpx
;
}
.input
{
box-sizing
:
border-box
;
width
:
690
rpx
;
border-bottom
:
2
rpx
solid
#000
;
color
:
#000
;
font-size
:
22
rpx
;
}
.textarea
{
box-sizing
:
border-box
;
padding
:
20
rpx
0
;
}
.textarea
{
box-sizing
:
border-box
;
padding
:
20
rpx
0
;
}
/
deep
/
.textarea-placeholder
{
font-size
:
20
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#cccccc
;
}
/
deep
/
.textarea-placeholder
{
font-size
:
20
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#cccccc
;
}
</
style
>
src/components/subject/SingleChoiceNumber.vue
View file @
b076f170
...
...
@@ -88,7 +88,10 @@ export default {
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
});
console
.
log
(
77
,
data
.
sortIndex
!=
1
,
data
.
sortIndex
!=
data
.
sortTotal
);
if
(
props
.
startIndex
)
{
data
.
current
=
props
.
startIndex
;
data
.
ExamIndex
=
props
.
startIndex
;
}
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
...
...
src/components/subject/Spoken.vue
View file @
b076f170
<
template
>
<!-- 计算题 -->
<view>
<view
class=
"item"
style=
"padding:0 20px;"
>
<view
class=
"name"
>
<view>
{{
changeNumToHan
(
sortIndex
)
}}
、
{{
data
.
GroupName
}}
<text
style=
"color:#999999;"
>
(共
{{
data
.
DetailsList
.
length
}}
道,
{{
data
.
GScore
}}
分)
</text>
</view>
<view>
<text
class=
"Single_Before"
>
{{
ExamIndex
}}
</text>
/
<text
class=
"Exam_Total"
>
{{
data
.
DetailsList
.
length
}}
</text>
</view>
</view>
<swiper
class=
"swiper-box"
:autoplay=
"autoplay"
:current=
"current"
@
change=
"onchange"
>
<swiper-item
v-if=
"sortIndex != 1"
></swiper-item>
<swiper-item
v-for=
"(item1, index1) in data.DetailsList"
:key=
"item1.id"
>
<view
class=
"item1"
>
<view
class=
"flex flex_start_center"
>
<view>
{{
index1
+
1
}}
、
</view>
<view
class=
"num"
v-html=
"item1.Title"
></view>
</view>
<view
class=
"chooseName"
>
<textarea
type=
"text"
v-model=
"item1.myAnswer"
class=
"input textarea"
placeholder=
"请填写答案"
placeholder-style=
"textarea-placeholder"
:maxlength=
"-1"
/>
</view>
</view>
</swiper-item>
<swiper-item
v-if=
"sortIndex != sortTotal"
></swiper-item>
</swiper>
</view>
<van-toast
id=
"van-toast"
/>
</view>
<!-- 计算题 -->
<view>
<view
class=
"item"
style=
"padding: 0 20px"
>
<view
class=
"name"
>
<view>
{{
changeNumToHan
(
sortIndex
)
}}
、
{{
data
.
GroupName
}}
<text
style=
"color: #999999"
>
(共
{{
data
.
DetailsList
.
length
}}
道,
{{
data
.
GScore
}}
分)
</text
>
</view>
<view>
<text
class=
"Single_Before"
>
{{
ExamIndex
}}
</text
>
/
<text
class=
"Exam_Total"
>
{{
data
.
DetailsList
.
length
}}
</text>
</view>
</view>
<swiper
class=
"swiper-box"
:autoplay=
"autoplay"
:current=
"current"
@
change=
"onchange"
>
<swiper-item
v-if=
"sortIndex != 1"
></swiper-item>
<swiper-item
v-for=
"(item1, index1) in data.DetailsList"
:key=
"item1.id"
>
<view
class=
"item1"
>
<view
class=
"flex flex_start_center"
>
<view>
{{
index1
+
1
}}
、
</view>
<view
class=
"num"
v-html=
"item1.Title"
></view>
</view>
<view
class=
"chooseName"
>
<textarea
type=
"text"
v-model=
"item1.myAnswer"
class=
"input textarea"
placeholder=
"请填写答案"
placeholder-style=
"textarea-placeholder"
:maxlength=
"-1"
/>
</view>
</view>
</swiper-item>
<swiper-item
v-if=
"sortIndex != sortTotal"
></swiper-item>
</swiper>
</view>
<van-toast
id=
"van-toast"
/>
</view>
</
template
>
<
script
>
import
{
ref
,
reactive
,
toRefs
,
toRef
,
getCurrentInstance
,
watch
,
computed
,
onMounted
,
}
from
"vue"
;
import
{
changeNumToHan
}
from
"../../utils/index"
;
export
default
{
props
:
{
paperData
:
Object
,
sort
:
Number
,
sortTotal
:
Number
,
isLast
:
Boolean
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
(
);
props
.
paperData
.
DetailsList
.
forEach
((
item
,
index
)
=>
{
item
.
myAnswer
=
""
;
});
let
data
=
reactive
({
data
:
props
.
paperData
,
autoplay
:
false
,
sortIndex
:
props
.
sort
+
1
,
sortTotal
:
props
.
sortTotal
,
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
})
;
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
uni
.
navigateTo
({
url
:
"/pages/exam/examPaper"
,
});
},
back
()
{
uni
.
navigateBack
();
},
onchange
(
e
)
{
data
.
ExamIndex
=
e
.
detail
.
current
;
if
(
data
.
ExamIndex
===
data
.
data
.
DetailsList
.
length
+
1
)
{
console
.
log
(
'进入'
)
this
.
$emit
(
'getAfterTopic'
);
}
if
(
e
.
detail
.
current
==
0
)
{
this
.
$emit
(
'getBeforeTopic'
);
}
}
};
onMounted
(()
=>
{
if
(
props
.
isLast
)
{
data
.
current
=
props
.
paperData
.
DetailsList
.
length
;
}
})
let
that
=
methods
;
return
{
...
toRefs
(
data
),
...
methods
,
};
},
};
import
{
ref
,
reactive
,
toRefs
,
toRef
,
getCurrentInstance
,
watch
,
computed
,
onMounted
,
}
from
"vue"
;
import
{
changeNumToHan
}
from
"../../utils/index"
;
export
default
{
props
:
{
paperData
:
Object
,
sort
:
Number
,
sortTotal
:
Number
,
isLast
:
Boolean
,
startIndex
:
Number
,
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
();
props
.
paperData
.
DetailsList
.
forEach
((
item
,
index
)
=>
{
item
.
myAnswer
=
""
;
}
);
let
data
=
reactive
(
{
data
:
props
.
paperData
,
autoplay
:
false
,
sortIndex
:
props
.
sort
+
1
,
sortTotal
:
props
.
sortTotal
,
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
});
if
(
props
.
startIndex
)
{
data
.
current
=
props
.
startIndex
;
data
.
ExamIndex
=
props
.
startIndex
;
}
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
uni
.
navigateTo
({
url
:
"/pages/exam/examPaper"
,
});
},
back
()
{
uni
.
navigateBack
();
},
onchange
(
e
)
{
data
.
ExamIndex
=
e
.
detail
.
current
;
if
(
data
.
ExamIndex
===
data
.
data
.
DetailsList
.
length
+
1
)
{
console
.
log
(
"进入"
);
this
.
$emit
(
"getAfterTopic"
);
}
if
(
e
.
detail
.
current
==
0
)
{
this
.
$emit
(
"getBeforeTopic"
);
}
},
};
onMounted
(()
=>
{
if
(
props
.
isLast
)
{
data
.
current
=
props
.
paperData
.
DetailsList
.
length
;
}
});
let
that
=
methods
;
return
{
...
toRefs
(
data
),
...
methods
,
};
},
};
</
script
>
<
style
scoped
>
.name
{
height
:
90
rpx
;
font-size
:
28
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
800
;
color
:
#111111
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
}
.name
{
height
:
90
rpx
;
font-size
:
28
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
800
;
color
:
#111111
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
}
.Single_Before
{
font-size
:
28
rpx
;
font-weight
:
bold
;
color
:
#DA
7878
;
}
.swiper-box
{
height
:
calc
(
100vh
-
270
rpx
);
box-sizing
:
border-box
;
}
.num
{
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.Single_Before
{
font-size
:
28
rpx
;
font-weight
:
bold
;
color
:
#da
7878
;
}
.swiper-box
{
height
:
calc
(
100vh
-
270
rpx
);
box-sizing
:
border-box
;
}
.num
{
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.item
{
margin-bottom
:
40
rpx
;
}
.item
{
margin-bottom
:
40
rpx
;
}
.item1
{
margin
:
25
rpx
0
;
align-items
:
center
;
}
.item1
{
margin
:
25
rpx
0
;
align-items
:
center
;
}
.item2
{
/* padding-left: 25rpx; */
margin
:
30
rpx
0
;
}
.item2
{
/* padding-left: 25rpx; */
margin
:
30
rpx
0
;
}
.choose
{
background-color
:
#00acf9
!important
;
color
:
#ffffff
!important
;
}
.choose
{
background-color
:
#00acf9
!important
;
color
:
#ffffff
!important
;
}
.chooseNum
{
width
:
40
rpx
;
height
:
40
rpx
;
text-align
:
center
;
line-height
:
40
rpx
;
border-radius
:
50%
;
border
:
1px
solid
#e2e2e2
;
margin-right
:
30
rpx
;
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.chooseNum
{
width
:
40
rpx
;
height
:
40
rpx
;
text-align
:
center
;
line-height
:
40
rpx
;
border-radius
:
50%
;
border
:
1px
solid
#e2e2e2
;
margin-right
:
30
rpx
;
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.chooseName
{
font-size
:
24
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#111111
;
}
.chooseName
{
font-size
:
24
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#111111
;
}
.input
{
box-sizing
:
border-box
;
width
:
690
rpx
;
border-bottom
:
2
rpx
solid
#000
;
color
:
#000
;
font-size
:
22
rpx
;
}
.input
{
box-sizing
:
border-box
;
width
:
690
rpx
;
border-bottom
:
2
rpx
solid
#000
;
color
:
#000
;
font-size
:
22
rpx
;
}
.textarea
{
box-sizing
:
border-box
;
padding
:
20
rpx
0
;
}
.textarea
{
box-sizing
:
border-box
;
padding
:
20
rpx
0
;
}
/
deep
/
.textarea-placeholder
{
font-size
:
20
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#cccccc
;
}
/
deep
/
.textarea-placeholder
{
font-size
:
20
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
500
;
color
:
#cccccc
;
}
</
style
>
src/components/subject/easyQuestion.vue
View file @
b076f170
...
...
@@ -68,6 +68,7 @@ export default {
sort
:
Number
,
sortTotal
:
Number
,
isLast
:
Boolean
,
startIndex
:
Number
,
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
();
...
...
@@ -82,7 +83,10 @@ export default {
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
});
if
(
props
.
startIndex
)
{
data
.
current
=
props
.
startIndex
;
data
.
ExamIndex
=
props
.
startIndex
;
}
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
...
...
src/components/subject/judge.vue
View file @
b076f170
...
...
@@ -71,6 +71,7 @@ export default {
sort
:
Number
,
sortTotal
:
Number
,
isLast
:
Boolean
,
startIndex
:
Number
,
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
();
...
...
@@ -82,7 +83,10 @@ export default {
current
:
1
,
//默认从第几个开始-用于从快捷菜单点入
ExamIndex
:
1
,
//第几题
});
if
(
props
.
startIndex
)
{
data
.
current
=
props
.
startIndex
;
data
.
ExamIndex
=
props
.
startIndex
;
}
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
...
...
src/components/subject/readingCompre.vue
View file @
b076f170
...
...
@@ -149,6 +149,7 @@ export default {
sort
:
Number
,
sortTotal
:
Number
,
isLast
:
Boolean
,
startIndex
:
Number
,
},
setup
(
props
,
context
)
{
let
{
ctx
}
=
getCurrentInstance
();
...
...
@@ -164,6 +165,10 @@ export default {
timer
:
null
,
timeOutEvent
:
false
,
});
if
(
props
.
startIndex
)
{
data
.
current
=
props
.
startIndex
;
data
.
ExamIndex
=
props
.
startIndex
;
}
let
methods
=
{
changeNumToHan
,
jumpPage
()
{
...
...
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