Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
L
learn-online-pc
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
EzijingWeb
learn-online-pc
Commits
e32c2cad
提交
e32c2cad
authored
1月 17, 2020
作者:
GOD_ZYX
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
update
上级
ede512a4
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
8 个修改的文件
包含
49 行增加
和
8 行删除
+49
-8
exam.vue
client/client/components/player/exam/exam.vue
+0
-0
sideChapterList.vue
...nt/client/components/player/rightSide/sideChapterList.vue
+2
-0
base_api.js
client/client/components/services/base_api.js
+1
-1
uploadForm.vue
client/client/components/upload-form/src/uploadForm.vue
+11
-0
ChapterAction.js
client/client/project/actions/ChapterAction.js
+7
-0
CourseAction.js
client/client/project/actions/CourseAction.js
+11
-0
ExamAction.js
client/client/project/actions/ExamAction.js
+15
-7
courseDetail.vue
client/client/project/pages/myLearn/courseDetail.vue
+2
-0
没有找到文件。
client/client/components/player/exam/exam.vue
浏览文件 @
e32c2cad
差异被折叠。
点击展开。
client/client/components/player/rightSide/sideChapterList.vue
浏览文件 @
e32c2cad
...
@@ -62,6 +62,8 @@ export default {
...
@@ -62,6 +62,8 @@ export default {
}
else
if
(
_course
.
chapters
[
i2
].
id
===
'teach_evaluation'
)
{
}
else
if
(
_course
.
chapters
[
i2
].
id
===
'teach_evaluation'
)
{
// window.localStorage.setItem('headerInfo', JSON.stringify(this.headerInfo))
// window.localStorage.setItem('headerInfo', JSON.stringify(this.headerInfo))
this
.
$router
.
push
({
path
:
`/survey/
${
sid
}
/
${
cid
}
`
})
this
.
$router
.
push
({
path
:
`/survey/
${
sid
}
/
${
cid
}
`
})
}
else
if
(
_course
.
chapters
[
i2
].
type
===
'exam'
)
{
this
.
$router
.
push
({
path
:
`/player/
${
sid
}
/
${
cid
}
/exam/
${
_id
}
`
})
}
}
return
return
}
}
...
...
client/client/components/services/base_api.js
浏览文件 @
e32c2cad
...
@@ -120,7 +120,7 @@ export default class API {
...
@@ -120,7 +120,7 @@ export default class API {
message
:
'已取消,将不再记录任何数据操作,除非重新登录'
message
:
'已取消,将不再记录任何数据操作,除非重新登录'
})
})
})
})
}
else
if
(
data
.
status
!==
200
&&
data
.
message
)
{
}
else
if
(
data
.
status
!==
200
&&
data
.
message
&&
!
data
.
code
)
{
err
=
new
Error
(
data
.
message
)
err
=
new
Error
(
data
.
message
)
throw
err
throw
err
}
else
{
}
else
{
...
...
client/client/components/upload-form/src/uploadForm.vue
浏览文件 @
e32c2cad
...
@@ -100,6 +100,17 @@ export default {
...
@@ -100,6 +100,17 @@ export default {
// }
// }
// })
// })
}
}
},
watch
:
{
filesArr
:
{
immediate
:
true
,
deep
:
true
,
handler
(
value
)
{
if
(
this
.
formData
[
this
.
item
.
model
].
length
!==
value
.
length
)
{
this
.
formData
[
this
.
item
.
model
]
=
value
}
}
}
}
}
}
}
</
script
>
</
script
>
...
...
client/client/project/actions/ChapterAction.js
浏览文件 @
e32c2cad
...
@@ -116,6 +116,13 @@ export default class ChapterAction {
...
@@ -116,6 +116,13 @@ export default class ChapterAction {
id
:
'teach_evaluation'
id
:
'teach_evaluation'
}]
}]
})
})
if
(
_res
.
course_examination
)
{
json
.
course
[
json
.
course
.
length
-
1
].
chapters
.
push
({
name
:
'课程考试'
,
type
:
'exam'
,
id
:
_res
.
course_examination
})
}
let
courseWork
=
_res
.
curriculum
||
{}
let
courseWork
=
_res
.
curriculum
||
{}
courseWork
[
'end_date'
]
=
_res
.
end_date
courseWork
[
'end_date'
]
=
_res
.
end_date
courseWork
[
'essay_date'
]
=
_res
.
essay_date
courseWork
[
'essay_date'
]
=
_res
.
essay_date
...
...
client/client/project/actions/CourseAction.js
浏览文件 @
e32c2cad
...
@@ -149,6 +149,17 @@ export default class CourseAction {
...
@@ -149,6 +149,17 @@ export default class CourseAction {
sid
:
sid
,
sid
:
sid
,
cid
:
cid
cid
:
cid
})
})
if
(
cur
.
course_examination
)
{
json
.
tabs1ChapterList
.
course
.
push
({
title
:
'课程考试'
,
isUp
:
true
,
chapters
:
[],
type
:
'exam'
,
sid
:
sid
,
cid
:
cid
,
examId
:
cur
.
course_examination
})
}
/* 课程考核 考核标准文案读取 */
/* 课程考核 考核标准文案读取 */
json
.
tabs3richTest
=
cur
.
course_evaluation
json
.
tabs3richTest
=
cur
.
course_evaluation
// callback(json) // 可以不使用callback 因为使用then
// callback(json) // 可以不使用callback 因为使用then
...
...
client/client/project/actions/ExamAction.js
浏览文件 @
e32c2cad
import
{
examApi
}
from
'@services'
import
{
examApi
}
from
'@services'
import
Base64
from
'Base64'
export
default
class
ExamAction
{
export
default
class
ExamAction
{
/* 获取考卷信息 */
/* 获取考卷信息 */
...
@@ -7,6 +8,7 @@ export default class ExamAction {
...
@@ -7,6 +8,7 @@ export default class ExamAction {
let
exam
=
{}
let
exam
=
{}
exam
.
id
=
_res
.
id
exam
.
id
=
_res
.
id
exam
.
title
=
_res
.
title
exam
.
title
=
_res
.
title
exam
.
score
=
{}
exam
.
radioList
=
_res
.
examination
.
radioList
exam
.
radioList
=
_res
.
examination
.
radioList
for
(
let
i
=
0
;
i
<
exam
.
radioList
.
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
exam
.
radioList
.
length
;
i
++
)
{
exam
.
radioList
[
i
].
user_answer
=
''
exam
.
radioList
[
i
].
user_answer
=
''
...
@@ -51,26 +53,32 @@ export default class ExamAction {
...
@@ -51,26 +53,32 @@ export default class ExamAction {
/* 获取考卷结果 */
/* 获取考卷结果 */
getExamAnswer
(
cid
,
sid
,
eid
)
{
getExamAnswer
(
cid
,
sid
,
eid
)
{
return
examApi
.
getExamAnswer
(
cid
,
sid
,
eid
).
then
(
_res
=>
{
return
examApi
.
getExamAnswer
(
cid
,
sid
,
eid
).
then
(
_res
=>
{
if
(
_res
.
code
)
{
return
_res
}
let
exam
=
{}
let
exam
=
{}
let
tmp
=
null
exam
.
id
=
_res
.
id
exam
.
id
=
_res
.
id
exam
.
title
=
_res
.
title
exam
.
title
=
_res
.
title
exam
.
type
=
_res
.
type
exam
.
score
=
_res
.
score
exam
.
submitted_time
=
_res
.
submitted_time
exam
.
radioList
=
_res
.
sheet
.
radioList
exam
.
radioList
=
_res
.
sheet
.
radioList
for
(
let
i
=
0
;
i
<
exam
.
radioList
.
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
exam
.
radioList
.
length
;
i
++
)
{
let
tmp
=
exam
.
radioList
[
i
]
tmp
=
exam
.
radioList
[
i
]
if
(
!
tmp
.
user_answer
)
tmp
.
user_answer
=
''
if
(
!
tmp
.
user_answer
)
tmp
.
user_answer
=
''
if
(
!
tmp
.
right_answer
)
tmp
.
right_answer
=
''
if
(
!
tmp
.
right_answer
)
tmp
.
right_answer
=
''
if
(
!
tmp
.
get_score
)
tmp
.
get_score
=
-
1
if
(
!
tmp
.
get_score
)
tmp
.
get_score
=
-
1
}
}
exam
.
checkboxList
=
_res
.
sheet
.
checkboxList
exam
.
checkboxList
=
_res
.
sheet
.
checkboxList
for
(
let
i
=
0
;
i
<
exam
.
checkboxList
.
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
exam
.
checkboxList
.
length
;
i
++
)
{
let
tmp
=
exam
.
checkboxList
[
i
]
tmp
=
exam
.
checkboxList
[
i
]
if
(
!
tmp
.
user_answer
||
!
tmp
.
user_answer
.
length
)
tmp
.
user_answer
=
[]
if
(
!
tmp
.
user_answer
||
!
tmp
.
user_answer
.
length
)
tmp
.
user_answer
=
[]
if
(
!
tmp
.
right_answer
||
!
tmp
.
right_answer
.
length
)
tmp
.
right_answer
=
[]
if
(
!
tmp
.
right_answer
||
!
tmp
.
right_answer
.
length
)
tmp
.
right_answer
=
[]
if
(
!
tmp
.
get_score
)
tmp
.
get_score
=
-
1
if
(
!
tmp
.
get_score
)
tmp
.
get_score
=
-
1
}
}
exam
.
shortAnswerList
=
_res
.
sheet
.
shortAnswerList
exam
.
shortAnswerList
=
_res
.
sheet
.
shortAnswerList
for
(
let
i
=
0
;
i
<
exam
.
shortAnswerList
.
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
exam
.
shortAnswerList
.
length
;
i
++
)
{
let
tmp
=
exam
.
shortAnswerList
[
i
]
tmp
=
exam
.
shortAnswerList
[
i
]
tmp
.
user_answer
=
Base64
.
decode
(
tmp
.
user_answer
.
replace
(
' '
,
'+'
),
'utf-8'
)
if
(
!
tmp
.
attachments
||
!
tmp
.
attachments
.
length
)
tmp
.
attachments
=
[]
if
(
!
tmp
.
attachments
||
!
tmp
.
attachments
.
length
)
tmp
.
attachments
=
[]
tmp
.
upload
=
{
tmp
.
upload
=
{
type
:
'upload-form'
,
type
:
'upload-form'
,
...
@@ -78,14 +86,14 @@ export default class ExamAction {
...
@@ -78,14 +86,14 @@ export default class ExamAction {
model
:
'attachments'
,
model
:
'attachments'
,
action
:
webConf
.
apiBaseURL
+
'/util/upload-file'
,
action
:
webConf
.
apiBaseURL
+
'/util/upload-file'
,
data
:
{
data
:
{
special
:
'exam'
,
special
:
'exam'
},
attrs
:
{
multiple
:
true
,
headers
:
{
headers
:
{
'tenant'
:
'sofia'
'tenant'
:
'sofia'
}
}
},
},
attrs
:
{
multiple
:
true
},
html
:
`
html
:
`
<div style="color: #72818c; font-size: 14px;">
<div style="color: #72818c; font-size: 14px;">
<p style="margin: 0;">支持doc,docx,ppt,xls,txt,rar,zip,pdf,jpg,pic,png格式的文件,文件小于30M。</p>
<p style="margin: 0;">支持doc,docx,ppt,xls,txt,rar,zip,pdf,jpg,pic,png格式的文件,文件小于30M。</p>
...
...
client/client/project/pages/myLearn/courseDetail.vue
浏览文件 @
e32c2cad
...
@@ -483,6 +483,8 @@ export default {
...
@@ -483,6 +483,8 @@ export default {
// } else {
// } else {
// this.$router.push({ path: `/survey-phone/${sid}/${cid}` })
// this.$router.push({ path: `/survey-phone/${sid}/${cid}` })
// }
// }
} else if (course.type === '
exam
') {
this.$router.push({ path: `/player/${sid}/${cid}/exam/${course.examId}` })
}
}
}
}
},
},
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论