Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mr-julyedu
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
baiguangyao
mr-julyedu
Commits
4ed8fb07
Commit
4ed8fb07
authored
Aug 10, 2019
by
wangshuo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
课后练习题
parent
9633c104
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
11 deletions
+12
-11
src/components/video/camp/camp.scss
+1
-0
src/components/video/camp/campResolve.js
+2
-3
src/components/video/camp/campTest.js
+8
-7
src/components/video/camp/common/common.js
+1
-1
No files found.
src/components/video/camp/camp.scss
View file @
4ed8fb07
...
...
@@ -376,6 +376,7 @@
flex-wrap
:
wrap
;
justify-content
:
flex-start
;
padding
:
0
16px
;
width
:
100%
;
li
{
width
:
40px
;
height
:
40px
;
...
...
src/components/video/camp/campResolve.js
View file @
4ed8fb07
...
...
@@ -25,8 +25,6 @@ class CampResolve extends Component {
});
this
.
body
=
document
.
getElementsByTagName
(
'body'
)[
0
];
this
.
body
.
style
.
position
=
'fixed'
;
};
close
=
()
=>
{
let
isShow
=
this
.
state
.
showCard
;
...
...
@@ -37,7 +35,7 @@ class CampResolve extends Component {
this
.
body
=
document
.
getElementsByTagName
(
'body'
)[
0
];
this
.
body
.
style
.
position
=
'static'
;
}
else
{
this
.
props
.
history
.
push
(
`/detail?id=
${
this
.
course_id
}
`
)
}
};
componentDidMount
()
{
...
...
@@ -59,6 +57,7 @@ class CampResolve extends Component {
return
;
}
let
data
=
res
.
data
.
data
;
this
.
course_id
=
data
.
course_id
;
_this
.
answerList
=
[];
this
.
rightNumber
=
0
;
data
.
list
.
map
(
item
=>
{
...
...
src/components/video/camp/campTest.js
View file @
4ed8fb07
...
...
@@ -38,6 +38,7 @@ class CampTest extends Component {
}
let
data
=
res
.
data
.
data
;
this
.
qid
=
data
.
id
;
this
.
course_id
=
data
.
course_id
;
this
.
setState
({
examList
:
data
.
list
,
qtitle
:
data
.
qtitle
,
...
...
@@ -67,9 +68,10 @@ class CampTest extends Component {
this
.
setState
({
showCard
:
false
});
this
.
body
=
document
.
getElementsByTagName
(
'body'
)[
0
];
this
.
body
.
style
.
position
=
'static'
;
}
else
{
this
.
props
.
history
.
push
(
`/detail?id=
${
this
.
course_id
}
`
)
}
};
// 选择答案
...
...
@@ -132,11 +134,11 @@ class CampTest extends Component {
data
.
uid
=
this
.
props
.
user
.
data
.
uid
;
data
.
answer_record
=
this
.
answerList
;
http
.
post
(
`
${
api
.
home
}
/m/aist/submit`
,
data
).
then
((
res
)
=>
{
console
.
log
(
res
);
// if() {
//
// }
// http://m.julyedu.com/campResolve?video_id=2109&qid=21
if
(
res
.
data
.
code
===
200
)
{
this
.
props
.
history
.
push
(
`/campResolve?keshi_id=
${
this
.
keshi_id
}
&qid=
${
this
.
qid
}
`
)
}
else
{
Toast
.
info
(
res
.
data
.
msg
,
2
);
}
});
};
// 显示答题卡
...
...
@@ -144,7 +146,6 @@ class CampTest extends Component {
this
.
setState
({
showCard
:
true
});
this
.
body
=
document
.
getElementsByTagName
(
'body'
)[
0
];
this
.
body
.
style
.
position
=
'fixed'
;
};
...
...
src/components/video/camp/common/common.js
View file @
4ed8fb07
...
...
@@ -47,7 +47,7 @@ function TestItem(props) {
onClick
=
{()
=>
props
.
checkOption
(
item
)}
className
=
{
`
${
currentQuestionOption
===
item
.
opt_id
?
'option_checked'
:
''
}
${((
currentExam
.
user_answer
===
0
||
currentExam
.
user_answer
)
&&
currentExam
.
answer_id
===
item
.
opt_id
)
?
'user_check'
:
''
}
${((
currentExam
.
user_answer
===
0
||
currentExam
.
user_answer
)
&&
currentExam
.
user_answer
===
item
.
opt_id
)
?
'user_check'
:
''
}
${((
currentExam
.
user_answer
===
0
||
currentExam
.
user_answer
)
&&
currentExam
.
answer_id
===
item
.
opt_id
)
?
'right_check'
:
''
}
`
}
>
...
...
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