Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
tea-resources-web
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
张伯涛
tea-resources-web
Commits
260af2eb
Commit
260af2eb
authored
May 15, 2024
by
刘怀志
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
题库管理暂存
parent
e360ca85
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
128 additions
and
20 deletions
+128
-20
teaExamQuestionsCompany.js
src/api/examination/teaExamQuestionsCompany.js
+104
-0
index.js
src/api/jobQuestionBank/index.js
+6
-0
examinationPaper.vue
...courseInformation/examinationCompany/examinationPaper.vue
+13
-15
index.vue
src/views/courseInformation/jobQuestionBank/index.vue
+5
-5
No files found.
src/api/examination/teaExamQuestionsCompany.js
0 → 100644
View file @
260af2eb
import
request
from
'@/utils/request'
import
Qs
from
'qs'
/**
* 1. 列表查询
* 2. 查询详细信息
* 3. 新增
* 4. 修改
* 5. 逻辑删除
* 6. 导出
*
*/
// 1. 查询试题表列表
export
function
listTeaExamQuestions
(
query
)
{
return
request
({
url
:
'/post/questions/questionList/'
+
query
.
id
,
method
:
'get'
,
params
:
query
})
}
// 2. 查询试题表详细信息
export
function
getTeaExamQuestions
(
businessId
)
{
return
request
({
url
:
'/post/questions/detail/'
+
businessId
,
method
:
'get'
})
}
// 3. 新增试题表
export
function
addTeaExamQuestions
(
data
)
{
return
request
({
url
:
'/post/blesson/addtopic'
,
method
:
'post'
,
data
:
data
,
headers
:
{
'Content-Type'
:
'application/json;charset=UTF-8'
// 接口修改传参类型
}
})
}
// 4. 修改试题表
export
function
updateTeaExamQuestions
(
data
)
{
return
request
({
url
:
'/post/questions/update'
,
method
:
'put'
,
data
,
headers
:
{
'Content-Type'
:
'application/json;charset=UTF-8'
// 接口修改传参类型
}
})
}
// 5. 逻辑删除试题表
export
function
delTeaExamQuestions
(
businessId
)
{
return
request
({
url
:
'/teaexamquestions/deleteLogical/'
+
businessId
,
method
:
'delete'
})
}
// 6. 导出试题表
export
function
exportTeaExamQuestions
(
query
)
{
return
request
({
url
:
'/teaexamquestions/export'
,
method
:
'get'
,
params
:
query
,
responseType
:
'blob'
})
}
// 7.修改试题状态
export
function
updateStatus
(
data
)
{
return
request
({
url
:
`/post/questions/updateStatus/
${
data
.
flag
}
/
${
data
.
businessId
}
`
,
method
:
'put'
})
}
// 8.下载开课导入模板
export
function
importTemplateTrialCourse
(
params
)
{
return
request
({
url
:
'/teaexamquestions/importTemplate'
,
method
:
'get'
,
responseType
:
'blob'
,
params
})
}
// 9.导入开课信息
export
function
importExcel
(
data
,
courseId
)
{
return
request
({
url
:
'/teaexamquestions/importDictData'
,
method
:
'post'
,
headers
:
{
'Content-Type'
:
'multipart/form-data'
},
transformRequest
:
[(
data
)
=>
{
return
data
}],
data
,
params
:
{
courseId
}
})
}
src/api/jobQuestionBank/index.js
View file @
260af2eb
...
...
@@ -91,6 +91,12 @@ export function blessonRemove(data) {
url
:
'/post/blesson/deleteLogical/'
+
data
,
method
:
'DELETE'
})
}
// 课程管理删除
export
function
deleteEnterprise
(
data
)
{
return
request
({
url
:
`/post/blesson/deleteEnterprise/
${
data
.
id
}
/
${
data
.
busId
}
`
,
method
:
'DELETE'
})
}
// 课程管理导入
export
function
excelImport
(
data
)
{
...
...
src/views/courseInformation/examinationCompany/examinationPaper.vue
View file @
260af2eb
...
...
@@ -12,7 +12,6 @@
<el-option
label=
"单选题"
value=
"1"
/>
<el-option
label=
"多选题"
value=
"2"
/>
<el-option
label=
"判断题"
value=
"3"
/>
<el-option
label=
"简答题"
value=
"4"
/>
</el-select>
</el-form-item>
<el-form-item
label=
"题目难度"
prop=
"unit"
>
...
...
@@ -93,8 +92,8 @@
<el-switch
v-model=
"scope.row.flag"
class=
"switchDisabledStyle"
inactive-value=
"0"
active-value=
"1"
:
inactive-value=
"0"
:
active-value=
"1"
@
click
.
native=
"handleStatusChange(scope.row,scope.$index)"
/>
</
template
>
...
...
@@ -283,8 +282,8 @@
<el-col
:span=
"12"
>
<el-form-item
label=
"状态"
prop=
"flag"
>
<el-radio-group
v-model=
"form.flag"
>
<el-radio
label=
"1"
>
启用
</el-radio>
<el-radio
label=
"0"
>
停用
</el-radio>
<el-radio
:
label=
"1"
>
启用
</el-radio>
<el-radio
:
label=
"0"
>
停用
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
...
...
@@ -340,7 +339,7 @@ import {
addTeaExamQuestions
,
delTeaExamQuestions
,
getTeaExamQuestions
,
listTeaExamQuestions
,
updateStatus
,
updateTeaExamQuestions
,
importExcel
,
importTemplateTrialCourse
}
from
'@/api/examination/teaExamQuestions'
}
from
'@/api/examination/teaExamQuestions
Company
'
import
{
getToken
}
from
'@/utils/auth'
export
default
{
...
...
@@ -394,7 +393,7 @@ export default {
optionC
:
''
,
optionD
:
''
,
mark
:
''
,
flag
:
'1'
,
flag
:
1
,
remarks
:
''
,
weight
:
''
,
optionsList
:
[]
...
...
@@ -403,8 +402,7 @@ export default {
questionTypeList
:
[
{
label
:
'单选题'
,
value
:
1
},
{
label
:
'多选题'
,
value
:
2
},
{
label
:
'判断题'
,
value
:
3
},
{
label
:
'简答题'
,
value
:
4
}
{
label
:
'判断题'
,
value
:
3
}
],
// 难度List
difficultyList
:
[
...
...
@@ -518,7 +516,7 @@ export default {
this
.
form
.
mark
=
''
this
.
form
.
number
=
''
this
.
form
.
weight
=
'0'
this
.
form
.
flag
=
'1'
this
.
form
.
flag
=
1
break
case
4
:
this
.
form
.
optionA
=
''
...
...
@@ -530,7 +528,7 @@ export default {
this
.
form
.
mark
=
''
this
.
form
.
number
=
''
this
.
form
.
weight
=
'0'
this
.
form
.
flag
=
'1'
this
.
form
.
flag
=
1
break
}
console
.
log
(
'form'
,
this
.
form
)
...
...
@@ -693,7 +691,7 @@ export default {
this
.
tableData
=
[]
_this
.
fullscreenLoading
=
true
const
params
=
{
courseI
d
:
_this
.
form
.
courseId
,
i
d
:
_this
.
form
.
courseId
,
page
:
_this
.
queryParams
.
page
,
rows
:
_this
.
queryParams
.
rows
,
number
:
_this
.
queryParams
.
number
,
...
...
@@ -717,8 +715,8 @@ export default {
},
// 修改状态
handleStatusChange
(
row
,
index
)
{
const
flag
=
row
.
flag
===
'1'
?
'0'
:
'1'
const
text
=
row
.
flag
===
'1'
?
'启用'
:
'停用'
const
flag
=
row
.
flag
===
1
?
0
:
1
const
text
=
row
.
flag
===
1
?
'启用'
:
'停用'
const
params
=
{
businessId
:
row
.
businessId
,
flag
:
row
.
flag
...
...
@@ -857,7 +855,7 @@ export default {
optionC
:
''
,
optionD
:
''
,
mark
:
''
,
flag
:
'1'
,
flag
:
1
,
remarks
:
''
,
weight
:
''
,
optionsList
:
[],
...
...
src/views/courseInformation/jobQuestionBank/index.vue
View file @
260af2eb
...
...
@@ -466,7 +466,7 @@ import {
downloadZip
,
queryPcLessonEvaluationByPagination
,
findAllUnitInfo
,
getEnterpriseListById
,
addEnterprise
,
blessonUpdate
getEnterpriseListById
,
addEnterprise
,
blessonUpdate
,
deleteEnterprise
}
from
'@/api/jobQuestionBank/index'
import
commonField
from
'@/utils/commonField'
import
{
getDict
}
from
'@/api/system/dict/data'
...
...
@@ -1650,18 +1650,18 @@ export default {
}).
then
(()
=>
{
const
_this
=
this
const
params
=
{
lessonId
:
_this
.
less
onId
,
ossId
:
data
.
business
Id
id
:
_this
.
currentLessi
onId
,
busId
:
data
.
enterprise
Id
}
console
.
log
(
'params'
,
params
)
del
Zip
(
params
).
then
(
res
=>
{
del
eteEnterprise
(
params
).
then
(
res
=>
{
if
(
res
.
code
===
200
)
{
// _this.success(res)
this
.
$message
({
message
:
'删除成功'
,
type
:
'success'
})
_this
.
get
ZipList
(
)
_this
.
get
EnterpriseList
(
_this
.
currentLessionId
)
}
else
{
_this
.
warning
(
res
)
}
...
...
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