Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
X
xiaomai-cloud-class-web
Overview
Overview
Details
Activity
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
xiaomai-cloud-class
xiaomai-cloud-class-web
Commits
c1e89385
Commit
c1e89385
authored
Apr 15, 2021
by
zhujian
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
'fix'
parent
6876a4a8
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
39 additions
and
16 deletions
+39
-16
src/modules/teach-tool/examination-manager/AddExam.less
+8
-1
src/modules/teach-tool/examination-manager/AddExam.tsx
+2
-2
src/modules/teach-tool/examination-manager/ExamData.tsx
+4
-4
src/modules/teach-tool/examination-manager/Index.tsx
+22
-8
src/modules/teach-tool/examination-manager/index.less
+1
-1
src/modules/teach-tool/examination-manager/userData.less
+2
-0
No files found.
src/modules/teach-tool/examination-manager/AddExam.less
View file @
c1e89385
.examPage{
.examPage{
padding-bottom:
50
px;
padding-bottom:
62
px;
.ant-alert-info{
.ant-alert-info{
background: rgba(255, 244, 221, 1);
background: rgba(255, 244, 221, 1);
border: none;
border: none;
}
}
.ant-form-item{
&:last-child{
margin-bottom: 0px !important;
}
}
.form{
.form{
margin-top: 12px;
margin-top: 12px;
width: 1000px;
width: 1000px;
...
@@ -13,6 +19,7 @@
...
@@ -13,6 +19,7 @@
font-weight: bold;
font-weight: bold;
color: #333333;
color: #333333;
line-height: 22px;
line-height: 22px;
margin-bottom: 8px;
}
}
}
}
...
...
src/modules/teach-tool/examination-manager/AddExam.tsx
View file @
c1e89385
...
@@ -301,7 +301,7 @@ function AddExam(props: any) {
...
@@ -301,7 +301,7 @@ function AddExam(props: any) {
<
InputNumber
value=
{
passRate
}
min=
{
0
}
max=
{
100
}
onChange=
{
(
value
:
any
)
=>
{
setPassRate
(
parseInt
(
value
))
}
}
style=
{
{
width
:
100
}
}
/>
<
InputNumber
value=
{
passRate
}
min=
{
0
}
max=
{
100
}
onChange=
{
(
value
:
any
)
=>
{
setPassRate
(
parseInt
(
value
))
}
}
style=
{
{
width
:
100
}
}
/>
<
span
style=
{
{
marginLeft
:
4
}
}
>
%
<
span
style=
{
{
marginLeft
:
4
}
}
>
%
</
span
>
</
span
>
<
span
style=
{
{
marginLeft
:
20
,
color
:
"#999"
}
}
>
<
span
style=
{
{
marginLeft
:
16
,
color
:
"#999"
}
}
>
{
` 总分(${paperInfo.totalScore || 0})*及格线(${passRate || 0}%)=及格分数(${passScore})`
}
</
span
>
{
` 总分(${paperInfo.totalScore || 0})*及格线(${passRate || 0}%)=及格分数(${passScore})`
}
</
span
>
</
Form
.
Item
>
</
Form
.
Item
>
...
@@ -338,7 +338,7 @@ function AddExam(props: any) {
...
@@ -338,7 +338,7 @@ function AddExam(props: any) {
<
InputNumber
value=
{
examDuration
}
max=
{
1440
}
min=
{
1
}
onChange=
{
(
value
:
any
)
=>
{
setExamDuration
(
parseInt
(
value
)
as
any
)
}
}
style=
{
{
width
:
100
}
}
/>
<
InputNumber
value=
{
examDuration
}
max=
{
1440
}
min=
{
1
}
onChange=
{
(
value
:
any
)
=>
{
setExamDuration
(
parseInt
(
value
)
as
any
)
}
}
style=
{
{
width
:
100
}
}
/>
<
span
style=
{
{
marginLeft
:
4
}
}
>
分钟
<
span
style=
{
{
marginLeft
:
4
}
}
>
分钟
</
span
>
</
span
>
<
span
style=
{
{
marginLeft
:
20
,
color
:
"#999"
}
}
>
<
span
style=
{
{
marginLeft
:
16
,
color
:
"#999"
}
}
>
{
` 时长不能超过1440分钟(24小时)`
}
</
span
>
{
` 时长不能超过1440分钟(24小时)`
}
</
span
>
</
Form
.
Item
>
</
Form
.
Item
>
...
...
src/modules/teach-tool/examination-manager/ExamData.tsx
View file @
c1e89385
...
@@ -217,7 +217,7 @@ function ExamData(props: any) {
...
@@ -217,7 +217,7 @@ function ExamData(props: any) {
!!
examData
.
singleChoiceCnt
&&
<
div
className=
"item"
>
!!
examData
.
singleChoiceCnt
&&
<
div
className=
"item"
>
<
div
className=
"num"
>
{
(
examData
.
singleChoiceAccuracy
||
0
)
*
100
}
%
</
div
>
<
div
className=
"num"
>
{
(
examData
.
singleChoiceAccuracy
||
0
)
*
100
}
%
</
div
>
<
div
className=
"percent"
>
正确率
</
div
>
<
div
className=
"percent"
>
正确率
</
div
>
<
div
className=
"subTitle"
><
div
className=
"type"
><
span
className=
"icon iconfont"
>

</
span
>
单选题
<
span
>
(共
{
examData
.
singleChoiceCnt
}
题)
</
span
></
div
></
div
>
<
div
className=
"subTitle"
><
div
className=
"type"
><
span
className=
"icon iconfont"
>

</
span
>
单选题
<
span
>
(共
{
examData
.
singleChoiceCnt
}
题)
</
span
></
div
></
div
>
</
div
>
</
div
>
}
}
...
@@ -225,7 +225,7 @@ function ExamData(props: any) {
...
@@ -225,7 +225,7 @@ function ExamData(props: any) {
!!
examData
.
multiChoiceCnt
&&
<
div
className=
"item"
>
!!
examData
.
multiChoiceCnt
&&
<
div
className=
"item"
>
<
div
className=
"num"
>
{
(
examData
.
multiChoiceAccuracy
||
0
)
*
100
}
%
</
div
>
<
div
className=
"num"
>
{
(
examData
.
multiChoiceAccuracy
||
0
)
*
100
}
%
</
div
>
<
div
className=
"percent"
>
正确率
</
div
>
<
div
className=
"percent"
>
正确率
</
div
>
<
div
className=
"subTitle"
><
div
className=
"type"
><
span
className=
"icon iconfont"
>

</
span
>
多选题
<
span
>
(共
{
examData
.
multiChoiceCnt
}
题)
</
span
></
div
></
div
>
<
div
className=
"subTitle"
><
div
className=
"type"
><
span
className=
"icon iconfont"
>

</
span
>
多选题
<
span
>
(共
{
examData
.
multiChoiceCnt
}
题)
</
span
></
div
></
div
>
</
div
>
</
div
>
}
}
...
@@ -233,7 +233,7 @@ function ExamData(props: any) {
...
@@ -233,7 +233,7 @@ function ExamData(props: any) {
!!
examData
.
judgeCnt
&&
<
div
className=
"item"
>
!!
examData
.
judgeCnt
&&
<
div
className=
"item"
>
<
div
className=
"num"
>
{
(
examData
.
judgeAccuracy
||
0
)
*
100
}
%
</
div
>
<
div
className=
"num"
>
{
(
examData
.
judgeAccuracy
||
0
)
*
100
}
%
</
div
>
<
div
className=
"percent"
>
正确率
</
div
>
<
div
className=
"percent"
>
正确率
</
div
>
<
div
className=
"subTitle"
><
div
className=
"type"
><
span
className=
"icon iconfont"
>

</
span
>
判断题
<
span
>
(共
{
examData
.
judgeCnt
}
题)
</
span
></
div
></
div
>
<
div
className=
"subTitle"
><
div
className=
"type"
><
span
className=
"icon iconfont"
>

</
span
>
判断题
<
span
>
(共
{
examData
.
judgeCnt
}
题)
</
span
></
div
></
div
>
</
div
>
</
div
>
}
}
...
@@ -242,7 +242,7 @@ function ExamData(props: any) {
...
@@ -242,7 +242,7 @@ function ExamData(props: any) {
!!
examData
.
gapFillingCnt
&&
<
div
className=
"item"
>
!!
examData
.
gapFillingCnt
&&
<
div
className=
"item"
>
<
div
className=
"num"
>
{
(
examData
.
gapFillingAccuracy
||
0
)
*
100
}
%
</
div
>
<
div
className=
"num"
>
{
(
examData
.
gapFillingAccuracy
||
0
)
*
100
}
%
</
div
>
<
div
className=
"percent"
>
正确率
</
div
>
<
div
className=
"percent"
>
正确率
</
div
>
<
div
className=
"subTitle"
><
div
className=
"type"
><
span
className=
"icon iconfont"
>

</
span
>
填空题
<
span
>
(共
{
examData
.
gapFillingCnt
}
题)
</
span
></
div
></
div
>
<
div
className=
"subTitle"
><
div
className=
"type"
><
span
className=
"icon iconfont"
>

</
span
>
填空题
<
span
>
(共
{
examData
.
gapFillingCnt
}
题)
</
span
></
div
></
div
>
</
div
>
</
div
>
}
}
{
{
...
...
src/modules/teach-tool/examination-manager/Index.tsx
View file @
c1e89385
...
@@ -19,6 +19,16 @@ interface sortType {
...
@@ -19,6 +19,16 @@ interface sortType {
type
:
"ascend"
|
"descend"
|
null
|
undefined
type
:
"ascend"
|
"descend"
|
null
|
undefined
}
}
interface
fixType
{
left
:
boolean
|
"right"
|
"left"
|
undefined
,
right
:
"right"
|
"left"
,
}
const
fixStr
:
fixType
=
{
left
:
'left'
,
right
:
'right'
}
function
ExaminationManager
(
props
:
any
)
{
function
ExaminationManager
(
props
:
any
)
{
const
queryInit
:
any
=
{
const
queryInit
:
any
=
{
examName
:
''
,
examName
:
''
,
...
@@ -64,8 +74,8 @@ function ExaminationManager(props: any) {
...
@@ -64,8 +74,8 @@ function ExaminationManager(props: any) {
const
columns
=
[
const
columns
=
[
{
{
title
:
"考试"
,
title
:
"考试"
,
// fixed:
'left'
,
// fixed:
fixStr.left
,
// width:35
0,
width
:
32
0
,
dataIndex
:
"examName"
,
dataIndex
:
"examName"
,
render
:
(
text
:
any
,
record
:
any
)
=>
{
render
:
(
text
:
any
,
record
:
any
)
=>
{
var
_text
=
'未开始'
,
_color
=
'rgba(255, 183, 20, 1)'
;
var
_text
=
'未开始'
,
_color
=
'rgba(255, 183, 20, 1)'
;
...
@@ -77,9 +87,9 @@ function ExaminationManager(props: any) {
...
@@ -77,9 +87,9 @@ function ExaminationManager(props: any) {
_color
=
'rgba(59, 189, 170, 1)'
;
_color
=
'rgba(59, 189, 170, 1)'
;
}
}
return
<
div
style=
{
{
width
:
3
3
0
}
}
>
return
<
div
style=
{
{
width
:
3
2
0
}
}
>
<
div
className=
'oneLineText'
style=
{
{
width
:
3
30
}
}
>
{
text
}
</
div
>
<
div
className=
'oneLineText'
style=
{
{
width
:
3
20
,
color
:
'#333'
,
fontWeight
:
'bold'
}
}
>
{
text
}
</
div
>
<
div
>
{
moment
(
record
.
examStartTime
).
format
(
"YYYY-MM-DD HH:mm"
)
}
~
{
moment
(
record
.
examEndTime
).
format
(
"YYYY-MM-DD HH:mm"
)
}
<
div
className=
"status"
style=
{
{
border
:
`1px solid ${_color}`
,
color
:
_color
}
}
>
{
_text
}
</
div
></
div
>
<
div
>
<
span
>
{
moment
(
record
.
examStartTime
).
format
(
"YYYY-MM-DD HH:mm"
)
}
~
{
moment
(
record
.
examEndTime
).
format
(
"YYYY-MM-DD HH:mm"
)
}
</
span
>
<
div
className=
"status"
style=
{
{
border
:
`1px solid ${_color}`
,
color
:
_color
}
}
>
{
_text
}
</
div
></
div
>
<
div
>
创建人:
{
record
.
examCreator
}
</
div
>
<
div
>
创建人:
{
record
.
examCreator
}
</
div
>
</
div
>
</
div
>
},
},
...
@@ -96,12 +106,14 @@ function ExaminationManager(props: any) {
...
@@ -96,12 +106,14 @@ function ExaminationManager(props: any) {
},
},
{
{
title
:
"题目数量"
,
title
:
"题目数量"
,
align
:
fixStr
.
right
,
dataIndex
:
"questionCnt"
,
dataIndex
:
"questionCnt"
,
},
},
{
{
title
:
"参与人数"
,
title
:
"参与人数"
,
dataIndex
:
"userCnt"
,
dataIndex
:
"userCnt"
,
align
:
fixStr
.
right
,
sorter
:
true
,
sorter
:
true
,
sortOrder
:
field
===
"userCnt"
?
order
:
sortStatus
.
type
,
sortOrder
:
field
===
"userCnt"
?
order
:
sortStatus
.
type
,
...
@@ -109,6 +121,7 @@ function ExaminationManager(props: any) {
...
@@ -109,6 +121,7 @@ function ExaminationManager(props: any) {
{
{
title
:
"及格数"
,
title
:
"及格数"
,
dataIndex
:
"passCnt"
,
dataIndex
:
"passCnt"
,
align
:
fixStr
.
right
,
sorter
:
true
,
sorter
:
true
,
sortOrder
:
field
===
"passCnt"
?
order
:
sortStatus
.
type
,
sortOrder
:
field
===
"passCnt"
?
order
:
sortStatus
.
type
,
...
@@ -123,6 +136,7 @@ function ExaminationManager(props: any) {
...
@@ -123,6 +136,7 @@ function ExaminationManager(props: any) {
},
},
{
{
title
:
"操作"
,
title
:
"操作"
,
fixed
:
fixStr
.
right
,
dataIndex
:
"operate"
,
dataIndex
:
"operate"
,
render
:
(
text
:
any
,
record
:
any
)
=>
<
div
className=
"table_operate"
>
render
:
(
text
:
any
,
record
:
any
)
=>
<
div
className=
"table_operate"
>
{
{
...
@@ -259,7 +273,7 @@ function ExaminationManager(props: any) {
...
@@ -259,7 +273,7 @@ function ExaminationManager(props: any) {
},
[
query
])
},
[
query
])
function
onShowSizeChange
(
current
:
any
,
size
:
any
)
{
function
onShowSizeChange
(
current
:
any
,
size
:
any
)
{
setQuery
({
current
:
1
,
size
})
(
queryRef
.
current
as
any
).
size
=
size
}
}
...
@@ -360,7 +374,7 @@ function ExaminationManager(props: any) {
...
@@ -360,7 +374,7 @@ function ExaminationManager(props: any) {
props
.
history
.
push
({
props
.
history
.
push
({
pathname
:
`${match.url}/add`
pathname
:
`${match.url}/add`
})
})
}
}
style=
{
{
margin
:
'
12px 0
'
}
}
>
新建考试
</
Button
>
}
}
style=
{
{
margin
:
'
4px 0 16px
'
}
}
>
新建考试
</
Button
>
}
}
...
@@ -371,7 +385,7 @@ function ExaminationManager(props: any) {
...
@@ -371,7 +385,7 @@ function ExaminationManager(props: any) {
size=
"small"
size=
"small"
columns=
{
columns
}
columns=
{
columns
}
dataSource=
{
list
}
dataSource=
{
list
}
scroll=
{
{
x
:
11
0
0
}
}
scroll=
{
{
x
:
11
5
0
}
}
onChange=
{
onChange
}
onChange=
{
onChange
}
pagination=
{
false
}
pagination=
{
false
}
style=
{
{
margin
:
'0px 0 16px'
}
}
style=
{
{
margin
:
'0px 0 16px'
}
}
...
...
src/modules/teach-tool/examination-manager/index.less
View file @
c1e89385
.examination-manager{
.examination-manager{
.status{
.status{
display: inline-block;
display: inline-block;
margin-left:
20
px;
margin-left:
4
px;
border: 1px solid #999;
border: 1px solid #999;
padding: 2px 4px;
padding: 2px 4px;
line-height: 16px;
line-height: 16px;
...
...
src/modules/teach-tool/examination-manager/userData.less
View file @
c1e89385
...
@@ -47,6 +47,8 @@
...
@@ -47,6 +47,8 @@
color: rgba(204, 204, 204, 1);
color: rgba(204, 204, 204, 1);
font-size: 16px;
font-size: 16px;
margin-right: 4px;
margin-right: 4px;
position: relative;
top: 1px;
}
}
}
}
...
...
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