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
08cb82fb
Commit
08cb82fb
authored
Apr 12, 2022
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
页面修改
parent
818610e6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
83 additions
and
86 deletions
+83
-86
appraisalList.vue
src/pages/teacher/appraisalList.vue
+0
-1
assessmentType.vue
src/pages/teacher/assessmentType.vue
+83
-85
No files found.
src/pages/teacher/appraisalList.vue
View file @
08cb82fb
...
...
@@ -97,7 +97,6 @@
this
.
loading
=
true
;
queryAssessmentTypeList
(
this
.
msg
).
then
(
res
=>
{
this
.
loading
=
false
;
console
.
log
(
"res"
,
res
);
if
(
res
.
Code
==
1
)
{
this
.
dataList
=
res
.
Data
;
}
...
...
src/pages/teacher/assessmentType.vue
View file @
08cb82fb
<
style
scoped
>
.jobTable
{
width
:
100%
;
text-align
:
center
;
}
.jobTable
tr
td
{
height
:
40px
;
color
:
#000
;
border
:
1px
solid
#d1d1d1
;
}
.jobTable
tr
th
{
height
:
40px
;
background-color
:
rgb
(
238
,
238
,
239
);
}
</
style
>
<
template
>
...
...
@@ -22,9 +7,8 @@
</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"
>
<q-table
:pagination=
"msg"
:loading=
"loading"
no-data-label=
"暂无相关数据"
flat
separator=
"Cell"
:data=
"dataList"
:columns=
"columns"
row-key=
"name"
>
<template
v-slot:top
>
<div
class=
"col-2 q-table__title"
>
类型配置
</div>
<q-space
/>
...
...
@@ -32,56 +16,62 @@
<q-btn
color=
"accent"
size=
"sm"
class=
"q-mr-md"
icon=
"add"
label=
"新增"
@
click=
"AddMsg(null)"
/>
</div>
</
template
>
<
template
v-slot:
body
=
"props"
>
<
template
v-slot:
header
=
"props"
>
<q-tr
:props=
"props"
>
<template
v-for=
"(col,cIndex) in props.cols"
>
<q-td
v-if=
"col.name == 'TypeName'"
:key=
"cIndex"
>
{{
col
.
value
}}
</q-td>
<q-td
v-else-if=
"col.name == 'SubtypeList'"
:key=
"cIndex"
>
<div
v-for=
"(item,sIndex) in col.value"
:key=
"sIndex"
>
<div
class=
"border-bottom"
>
{{
item
.
SubTypeName
}}
</div>
</div>
</q-td>
<q-td
style=
"width:100px;"
v-else-if=
"col.name == 'Id'"
:key=
"cIndex"
>
<q-btn
flat
size=
"xs"
icon=
"edit"
color=
"accent"
style=
"font-weight:400"
label=
"编辑"
@
click=
"AddMsg(props.row)"
/>
<q-btn
flat
size=
"xs"
icon=
"delete"
color=
"negative"
class=
"q-mr-xs"
label=
"删除"
@
click=
"delConsult(props.row.Id)"
/>
</q-td>
<template
v-for=
"col in props.cols"
:props=
"props"
>
<q-th
:key=
"col.name"
>
{{
col
.
label
}}
</q-th>
</
template
>
</q-tr>
</template>
<
template
v-slot:body=
"props"
>
<template
:props=
"props"
v-for=
"(col,cIndex) in props.row.SubtypeList"
>
<template
v-if=
"cIndex==0"
>
<q-tr
:key=
"cIndex"
style=
"border-top:1px solid red"
>
<q-td
key=
"TypeName"
:props=
"props"
:rowspan=
"props.row.SubtypeList.length"
style=
"border-top:1px solid rgba(0,0,0,0.12)"
>
{{
props
.
row
.
TypeName
}}
</q-td>
<q-td
style=
"border-top:1px solid rgba(0,0,0,0.12)"
>
{{
props
.
row
.
SubtypeList
[
cIndex
].
SubTypeName
}}
</q-td>
<template
v-for=
"(subItem,subIndex) in props.row.SubtypeList[cIndex].OptionList"
>
<q-td
:key=
"subIndex"
style=
"border-top:1px solid rgba(0,0,0,0.12)"
>
<div
style=
"width:180px;white-space:normal; "
>
{{
subItem
.
LevelDesc
}}
<q-badge
color=
"green"
>
{{
subItem
.
LevelScore
}}
分
</q-badge>
</div>
</q-td>
</
template
>
<q-td
key=
"Id"
:props=
"props"
:rowspan=
"props.row.SubtypeList.length"
style=
"border-top:1px solid rgba(0,0,0,0.12)"
>
<q-btn
flat
size=
"xs"
icon=
"edit"
color=
"accent"
style=
"font-weight:400"
label=
"编辑"
@
click=
"AddMsg(props.row)"
/>
<q-btn
flat
size=
"xs"
icon=
"delete"
color=
"negative"
class=
"q-mr-xs"
label=
"删除"
@
click=
"delConsult(props.row.Id)"
/>
</q-td>
</q-tr>
</template>
<
template
v-else
>
<q-tr
:key=
"cIndex"
>
<q-td>
{{
props
.
row
.
SubtypeList
[
cIndex
].
SubTypeName
}}
</q-td>
<template
v-for=
"(subItem,subIndex) in props.row.SubtypeList[cIndex].OptionList"
>
<q-td
:key=
"subIndex"
>
<div
style=
"width:180px;white-space:normal; "
>
{{
subItem
.
LevelDesc
}}
<q-badge
color=
"green"
>
{{
subItem
.
LevelScore
}}
分
</q-badge>
</div>
</q-td>
</
template
>
</q-tr>
</template>
</template>
</template>
<
template
v-slot:bottom
></
template
>
</q-table>
-->
<table
class=
"jobTable"
style=
"border-collapse:collapse;"
>
<tbody
v-for=
"(item,index) in dataList"
:key=
"index"
>
<tr>
<th
width=
"150"
>
类别
</th>
<th
width=
"150"
>
内容
</th>
<th
v-for=
"(T,tindex) in item.SubtypeList[0].OptionList"
>
<div>
{{T.LevelTitle}}
</div>
<div>
{{T.LevelScore}}
</div>
</th>
<th
width=
"200"
>
操作
</th>
</tr>
<tr>
<td
:rowspan=
"item.SubtypeList.length+1"
>
{{item.TypeName}}
</td>
</tr>
<tr
v-for=
"(sItem,sIndex) in item.SubtypeList"
>
<td>
{{sItem.SubTypeName}}
</td>
<td
v-for=
"(cItem,cIndex) in sItem.OptionList"
style=
"text-align:left;padding:10px;"
>
{{cItem.LevelDesc}}
</td>
<td
v-if=
"sIndex==0"
:rowspan=
"item.SubtypeList.length"
>
<q-btn
flat
size=
"xs"
icon=
"edit"
color=
"accent"
style=
"font-weight:400"
label=
"编辑"
@
click=
"AddMsg(item)"
/>
<q-btn
flat
size=
"xs"
icon=
"delete"
color=
"negative"
class=
"q-mr-xs"
label=
"删除"
@
click=
"delConsult(item.Id)"
/>
</td>
</tr>
</tbody>
</table>
</q-table>
</div>
<assess-form
v-if=
"isShowAssess"
:save-obj=
"objOption"
@
close=
"getClose()"
@
success=
"getRefresh"
></assess-form>
</div>
...
...
@@ -105,24 +95,7 @@
msg
:
{
rowsPerPage
:
1000
,
},
columns
:
[{
name
:
"TypeName"
,
label
:
"类别"
,
field
:
"TypeName"
,
align
:
"left"
},
{
name
:
"SubtypeList"
,
label
:
"内容"
,
field
:
"SubtypeList"
,
align
:
"left"
},
{
name
:
'Id'
,
label
:
'操作'
,
field
:
row
=>
row
.
Id
}
],
columns
:
[],
dataList
:
[],
objOption
:
null
,
isShowAssess
:
false
...
...
@@ -139,9 +112,36 @@
this
.
loading
=
true
;
queryAssessmentTypeList
(
this
.
msg
).
then
(
res
=>
{
this
.
loading
=
false
;
console
.
log
(
"res"
,
res
);
if
(
res
.
Code
==
1
)
{
this
.
dataList
=
res
.
Data
;
this
.
columns
.
push
({
name
:
"TypeName"
,
label
:
"类别"
,
field
:
"TypeName"
,
align
:
"left"
});
this
.
columns
.
push
({
name
:
"SubtypeList"
,
label
:
"内容"
,
field
:
"SubtypeList"
,
align
:
"left"
});
if
(
this
.
dataList
&&
this
.
dataList
.
length
>
0
)
{
this
.
dataList
[
0
].
SubtypeList
[
0
].
OptionList
.
forEach
(
item
=>
{
this
.
columns
.
push
({
name
:
item
.
LevelTitle
,
label
:
item
.
LevelTitle
,
field
:
item
.
LevelTitle
,
align
:
"left"
})
})
}
this
.
columns
.
push
({
name
:
'Id'
,
label
:
'操作'
,
field
:
row
=>
row
.
Id
})
}
})
},
...
...
@@ -195,9 +195,7 @@
}
}
}
</
script
>
<
style
lang=
"sass"
>
@import
url('~assets/css/table.sass')
</
style
>
</
style
>
\ No newline at end of file
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