Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
confucius
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
罗超
confucius
Commits
490ce2f2
Commit
490ce2f2
authored
Aug 11, 2021
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
页面修改
parent
6c03ffa1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
76 additions
and
80 deletions
+76
-80
paperfolder-form.vue
src/components/exam/paperfolder-form.vue
+5
-6
examManagement.vue
src/pages/exam/examManagement.vue
+71
-74
No files found.
src/components/exam/paperfolder-form.vue
View file @
490ce2f2
<
template
>
<q-dialog
v-model=
"persistent"
content-class=
"bg-grey-1"
persistent
transition-show=
"scale"
transition-hide=
"scale"
>
<q-card
style=
"width:
800px;max-width:9
00px;"
>
<q-card
style=
"width:
500px;max-width:5
00px;"
>
<q-card-section>
<div
class=
"text-h6"
>
{{
objOption
.
PaperId
==
0
?
'新增文件夹'
:
'修改文件夹名称'
}}
</div>
</q-card-section>
<q-card-section
class=
"q-pt-none scroll"
style=
"max-height: 70vh"
>
<div
class=
"text-caption q-mb-md q-px-xs text-grey-6"
>
基本资料
</div>
<div
class=
"row wrap"
>
<q-input
filled
stack-label
maxlength=
"50"
:dense=
"false"
v-model=
"objOption.PaperName"
ref=
"PaperName"
class=
"col-
6
q-pr-lg q-pb-lg"
label=
"文件夹名称"
:rules=
"[val => !!val || '请填写文件夹名称']"
/>
class=
"col-
12
q-pr-lg q-pb-lg"
label=
"文件夹名称"
:rules=
"[val => !!val || '请填写文件夹名称']"
/>
</div>
</q-card-section>
<q-separator
/>
...
...
@@ -53,13 +52,13 @@
methods
:
{
initObj
()
{
if
(
this
.
saveObj
)
{
this
.
optionTitle
=
"修改
助教信息
"
this
.
optionTitle
=
"修改
文件夹名称
"
this
.
objOption
.
PaperId
=
this
.
saveObj
.
PaperId
;
this
.
objOption
.
PaperName
=
this
.
saveObj
.
PaperName
;
this
.
objOption
.
PaperType
=
this
.
saveObj
.
PaperType
;
this
.
objOption
.
ParentId
=
this
.
saveObj
.
ParentId
;
}
else
{
this
.
optionTitle
=
"新增
助教
"
this
.
optionTitle
=
"新增
文件夹
"
}
},
closeSaveForm
()
{
...
...
src/pages/exam/examManagement.vue
View file @
490ce2f2
...
...
@@ -35,35 +35,63 @@
label=
"输入试卷名称、组卷人查找"
/>
</div>
</div>
<div
class=
"page-option"
>
<q-btn
color=
"accent"
size=
"sm"
class=
"q-mr-md"
label=
"新增文件夹"
@
click=
"showExamFolder(null)"
/>
<q-btn
color=
"accent"
size=
"sm"
class=
"q-mr-md"
label=
"新增试卷"
@
click=
"CreatePaper()"
/>
</div>
</div>
<div
class=
"page-content"
>
<q-table
:pagination=
"msg"
:loading=
"loading"
no-data-label=
"暂无相关数据"
flat
class=
"sticky-column-table sticky-right-column-table"
separator=
"none"
:data=
"dataList"
:columns=
"columns"
row-key=
"name"
>
<template
v-slot:top=
"props"
>
<div
class=
"col-2 q-table__title"
>
试卷管理
</div>
<q-space
/>
<q-btn
color=
"accent"
size=
"sm"
class=
"q-mr-md"
label=
"新增文件夹"
@
click=
"CreatePaper()"
/>
<q-btn
color=
"accent"
size=
"sm"
class=
"q-mr-md"
label=
"新增试卷"
@
click=
"CreatePaper()"
/>
<el-table
:data=
"dataList"
v-loading=
"loading"
:expand-row-keys=
"expandKeys"
:default-expand-all=
"true"
class=
"tree-tab-chapter"
style=
"width: 100%;margin-bottom: 20px;"
row-key=
"PaperId"
ref=
"examPaperTab"
@
row-click=
"rowsClick"
:tree-props=
"
{ children: 'ChildList', hasChildren: 'hasChildren' }">
<el-table-column
prop=
"PaperName"
label=
"文件夹/试卷"
width=
"450"
>
<template
slot-scope=
"scope"
>
{{
scope
.
row
.
PaperName
}}
</
template
>
<
template
v-slot:bottom
>
<q-pagination
class=
"full-width justify-end"
v-model=
"msg.pageIndex"
color=
"primary"
:max=
"pageCount"
:input=
"true"
@
input=
"changePage"
/>
</el-table-column>
<el-table-column
prop=
"QuestionCount"
label=
"题量"
width=
"100"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
QuestionCount
}}
</
template
>
</el-table-column>
<el-table-column
prop=
"DifficultyTypeName"
label=
"难度"
width=
"200"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
DifficultyTypeName
}}
</
template
>
<
template
v-slot:body-cell-PaperId=
"props"
>
<q-td
:props=
"props"
style=
"width:100px;"
>
<q-btn
flat
size=
"xs"
color=
"primary"
style=
"font-weight:400"
label=
"封存"
/>
<q-btn
flat
size=
"xs"
color=
"primary"
style=
"font-weight:400"
label=
"预览"
/>
<q-btn
flat
size=
"xs"
color=
"primary"
style=
"font-weight:400"
@
click=
"goExameEdit(props.row)"
label=
"编辑"
/>
<q-btn
flat
size=
"xs"
color=
"primary"
style=
"font-weight:400"
label=
"复制"
/>
<q-btn
flat
size=
"xs"
color=
"primary"
style=
"font-weight:400"
label=
"发布考试"
/>
<q-btn
flat
size=
"xs"
color=
"primary"
style=
"font-weight:400"
label=
"分配管理"
/>
<q-btn
flat
size=
"xs"
color=
"primary"
style=
"font-weight:400"
label=
"删除"
/>
<q-btn
flat
size=
"xs"
color=
"primary"
style=
"font-weight:400"
label=
"详情"
/>
</q-td>
</el-table-column>
<el-table-column
prop=
"PublishCount"
label=
"发放次数"
width=
"200"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
PublishCount
}}
</
template
>
</el-table-column>
<el-table-column
prop=
"CreateByName"
label=
"创建人"
width=
"200"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
CreateByName
}}
</
template
>
</el-table-column>
<el-table-column
prop=
"CreateTimeStr"
label=
"创建时间"
width=
"200"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
CreateTimeStr
}}
</
template
>
</el-table-column>
<el-table-column
label=
"操作"
>
<
template
slot-scope=
"scope"
>
<template
v-if=
"scope.row.PaperType==1"
>
<q-btn
flat
size=
"xs"
color=
"primary"
style=
"font-weight:400"
@
click=
"showExamFolder(scope.row)"
label=
"重命名"
/>
</
template
>
<
template
v-if=
"scope.row.PaperType==2"
>
<q-btn
flat
size=
"xs"
color=
"primary"
style=
"font-weight:400"
@
click=
"goExameEdit(scope.row)"
label=
"编辑"
/>
</
template
>
</template>
</q-table>
</el-table-column>
</el-table>
<q-pagination
class=
"full-width justify-end"
v-model=
"msg.pageIndex"
color=
"primary"
:max=
"pageCount"
:input=
"true"
@
input=
"changePage"
/>
</div>
<paperfolderForm
v-if=
"isShowExamFolder"
:saveObj=
"examObj"
@
close=
"closeExamForm"
@
success=
"refreshPage"
></paperfolderForm>
</div>
</template>
<
script
>
...
...
@@ -84,59 +112,16 @@
data
:
[],
msg
:
{
pageIndex
:
1
,
pageSize
:
1
2
,
rowsPerPage
:
1
2
,
pageSize
:
1
0
,
rowsPerPage
:
1
0
,
PaperName
:
''
//题库名
},
pageCount
:
0
,
loading
:
false
,
tikuList
:
[{
Id
:
0
,
Name
:
'全部'
},
{
Id
:
1
,
Name
:
'测试题库'
},
{
Id
:
2
,
Name
:
'质量管理与可靠性'
}],
dataList
:
[],
columns
:
[{
name
:
'PaperName'
,
label
:
'试卷名称'
,
field
:
'PaperName'
,
align
:
'left'
},
{
name
:
'QuestionCount'
,
label
:
'题量'
,
field
:
'QuestionCount'
,
align
:
'left'
},
{
name
:
'DifficultyTypeName'
,
label
:
'难度'
,
field
:
'DifficultyTypeName'
,
align
:
'left'
},
{
name
:
'PublishCount'
,
label
:
'发放次数'
,
field
:
'PublishCount'
,
align
:
'left'
},
{
name
:
'CreateByName'
,
label
:
'创建人'
,
field
:
'CreateByName'
,
align
:
'left'
},
{
name
:
'PaperId'
,
label
:
'操作'
,
field
:
'PaperId'
}
],
expandKeys
:
[],
isShowExamFolder
:
false
,
//是否显示新增文件夹
examObj
:
{},
//弹窗对象
}
},
created
()
{},
...
...
@@ -144,6 +129,9 @@
this
.
getList
();
},
methods
:
{
rowsClick
(
row
,
column
,
event
)
{
this
.
$refs
.
examPaperTab
.
toggleRowExpansion
(
row
);
},
//创建试卷
CreatePaper
()
{
this
.
OpenNewUrl
(
'/exam/examCreate'
,
{})
...
...
@@ -174,6 +162,15 @@
this
.
OpenNewUrl
(
'/exam/examEdit'
,
{
Id
:
item
.
PaperId
})
},
//新增修改文件夹
showExamFolder
(
obj
)
{
this
.
examObj
=
obj
;
this
.
isShowExamFolder
=
true
;
},
//关闭弹窗
closeExamForm
()
{
this
.
isShowExamFolder
=
false
;
}
}
}
...
...
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