Commit 4d8618e4 authored by 黄奎's avatar 黄奎

页面修改

parent d6aca972
...@@ -30,8 +30,7 @@ ...@@ -30,8 +30,7 @@
<template :props="props" v-for="(col,cIndex) in props.row.SubtypeList"> <template :props="props" v-for="(col,cIndex) in props.row.SubtypeList">
<template v-if="cIndex==0"> <template v-if="cIndex==0">
<q-tr :key="cIndex+(props.rowIndex*10000)"> <q-tr :key="cIndex+(props.rowIndex*10000)">
<q-td key="TypeName" :props="props" :rowspan="props.row.SubtypeList.length" <q-td key="TypeName" :props="props" :rowspan="props.row.SubtypeList.length" class="assessmentType_td">
class="assessmentType_td">
{{ props.row.TypeName }} {{ props.row.TypeName }}
</q-td> </q-td>
<q-td class="assessmentType_td"> <q-td class="assessmentType_td">
...@@ -39,14 +38,14 @@ ...@@ -39,14 +38,14 @@
</q-td> </q-td>
<template v-for="(subItem,subIndex) in props.row.SubtypeList[cIndex].OptionList"> <template v-for="(subItem,subIndex) in props.row.SubtypeList[cIndex].OptionList">
<q-td :key="subIndex+200000" class="assessmentType_td"> <q-td :key="subIndex+200000" class="assessmentType_td">
<div style="width:150px;white-space:normal; "> {{subItem.LevelDesc}} <q-badge color="green"> <div style="width:150px;white-space:normal; "> {{subItem.LevelDesc}} <q-badge color="green" v-if="subItem.LevelScore>0">
{{subItem.LevelScore}} {{subItem.LevelScore}}
</q-badge> </q-badge>
</div> </div>
</q-td> </q-td>
</template> </template>
<q-td key="Id" :props="props" :rowspan="props.row.SubtypeList.length" <q-td key="Id" :props="props" :rowspan="props.row.SubtypeList.length" class="assessmentType_td"
class="assessmentType_td" style="border-right: 1px solid rgba(0, 0, 0, 0.12);"> style="border-right: 1px solid rgba(0, 0, 0, 0.12);">
<q-btn flat size="xs" icon="edit" color="accent" style="font-weight:400" label="编辑" <q-btn flat size="xs" icon="edit" color="accent" style="font-weight:400" label="编辑"
@click="AddMsg(props.row)" /> @click="AddMsg(props.row)" />
<q-btn flat size="xs" icon="delete" color="negative" class="q-mr-xs" label="删除" <q-btn flat size="xs" icon="delete" color="negative" class="q-mr-xs" label="删除"
...@@ -61,7 +60,7 @@ ...@@ -61,7 +60,7 @@
</q-td> </q-td>
<template v-for="(subItem,subIndex) in props.row.SubtypeList[cIndex].OptionList"> <template v-for="(subItem,subIndex) in props.row.SubtypeList[cIndex].OptionList">
<q-td :key="subIndex+400000" class="assessmentType_td"> <q-td :key="subIndex+400000" class="assessmentType_td">
<div style="width:150px;white-space:normal; "> {{subItem.LevelDesc}} <q-badge color="green"> <div style="width:150px;white-space:normal; "> {{subItem.LevelDesc}} <q-badge color="green" v-if="subItem.LevelScore>0">
{{subItem.LevelScore}} {{subItem.LevelScore}}
</q-badge> </q-badge>
</div> </div>
...@@ -111,39 +110,13 @@ ...@@ -111,39 +110,13 @@
methods: { methods: {
getAssessmentTypeList() { getAssessmentTypeList() {
this.loading = true; this.loading = true;
this.columns=[]; this.columns = [];
queryAssessmentTypeList(this.msg).then(res => { queryAssessmentTypeList(this.msg).then(res => {
this.loading = false; this.loading = false;
console.log("res", res);
if (res.Code == 1) { if (res.Code == 1) {
this.dataList = res.Data; this.dataList = res.Data.result;
this.columns.push({ this.columns = res.Data.header;
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
})
} }
}) })
}, },
......
...@@ -69,10 +69,12 @@ ...@@ -69,10 +69,12 @@
<tr v-for="(sItem,sIndex) in item.SubtypeList" :key="sIndex"> <tr v-for="(sItem,sIndex) in item.SubtypeList" :key="sIndex">
<td>{{sItem.SubTypeName}}</td> <td>{{sItem.SubTypeName}}</td>
<td v-for="(cItem,cIndex) in sItem.OptionList" style="position:relative;" :key="cIndex"> <td v-for="(cItem,cIndex) in sItem.OptionList" style="position:relative;" :key="cIndex">
<template v-if="cItem.LevelDesc!=''&&cItem.LevelScore>0">
<el-tooltip class="item" effect="dark" :content="cItem.LevelDesc" placement="top-start"> <el-tooltip class="item" effect="dark" :content="cItem.LevelDesc" placement="top-start">
<i style="position:absolute;left:3px;top:3px;" class="iconfont icon-bangzhu"></i> <i style="position:absolute;left:3px;top:3px;" class="iconfont icon-bangzhu"></i>
</el-tooltip> </el-tooltip>
<q-checkbox v-model="cItem.IsCheck" @input="changeStatus(sItem,cItem)" val="teal" color="green" /> <q-checkbox v-model="cItem.IsCheck" @input="changeStatus(sItem,cItem)" val="teal" color="green" />
</template>
</td> </td>
<td>{{sItem.CheckScore}}</td> <td>{{sItem.CheckScore}}</td>
</tr> </tr>
......
...@@ -31,10 +31,12 @@ ...@@ -31,10 +31,12 @@
<tr v-for="(sItem,sIndex) in item.SubtypeList" :key="sIndex"> <tr v-for="(sItem,sIndex) in item.SubtypeList" :key="sIndex">
<td>{{sItem.SubTypeName}}</td> <td>{{sItem.SubTypeName}}</td>
<td v-for="(cItem,cIndex) in sItem.OptionList" style="position:relative;" :key="cIndex"> <td v-for="(cItem,cIndex) in sItem.OptionList" style="position:relative;" :key="cIndex">
<template v-if="cItem.LevelDesc!=''&&cItem.LevelScore>0">
<el-tooltip class="item" effect="dark" :content="cItem.LevelDesc" placement="top-start"> <el-tooltip class="item" effect="dark" :content="cItem.LevelDesc" placement="top-start">
<i style="position:absolute;left:3px;top:3px;" class="iconfont icon-bangzhu"></i> <i style="position:absolute;left:3px;top:3px;" class="iconfont icon-bangzhu"></i>
</el-tooltip> </el-tooltip>
<q-checkbox v-model="cItem.IsCheck" disable val="teal" color="green" /> <q-checkbox v-model="cItem.IsCheck" disable val="teal" color="green" />
</template>
</td> </td>
<td>{{sItem.S_TeacherScore}}</td> <td>{{sItem.S_TeacherScore}}</td>
<td>{{sItem.S_JiaoWuScore}}</td> <td>{{sItem.S_JiaoWuScore}}</td>
...@@ -229,7 +231,7 @@ ...@@ -229,7 +231,7 @@
if (res.Code == 1) { if (res.Code == 1) {
var tempData = res.Data; var tempData = res.Data;
this.saveObj = tempData; this.saveObj = tempData;
this.teacherDate=this.saveObj.YearStr+"-"+this.saveObj.MonthStr; this.teacherDate = this.saveObj.YearStr + "-" + this.saveObj.MonthStr;
} }
}) })
}, },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment