解决所有bug 优化table内容
This commit is contained in:
@@ -100,7 +100,6 @@
|
||||
<el-button
|
||||
icon="Plus"
|
||||
type="primary"
|
||||
class="ml10"
|
||||
@click="handleAdd">
|
||||
新增
|
||||
</el-button>
|
||||
@@ -129,46 +128,134 @@
|
||||
border
|
||||
:cell-style="tableStyle.cellStyle"
|
||||
:header-cell-style="tableStyle.headerCellStyle">
|
||||
<el-table-column type="index" label="序号" width="60" align="center" />
|
||||
<el-table-column prop="deptName" label="学院" show-overflow-tooltip align="center" min-width="150" />
|
||||
<el-table-column prop="majorName" label="专业" show-overflow-tooltip align="center" min-width="150" />
|
||||
<el-table-column prop="teacherName" label="班主任" show-overflow-tooltip align="center" width="100" />
|
||||
<el-table-column prop="grade" label="入学年份" show-overflow-tooltip align="center" width="100" />
|
||||
<el-table-column prop="gradeCurr" label="年级" show-overflow-tooltip align="center" width="80">
|
||||
<template #default="scope">
|
||||
<span>{{ scope.row.gradeCurr !== undefined && scope.row.gradeCurr !== null ? scope.row.gradeCurr : '-' }}</span>
|
||||
<el-table-column type="index" label="序号" width="60" align="center">
|
||||
<template #header>
|
||||
<el-icon><List /></el-icon>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="classNo" label="班级" show-overflow-tooltip align="center" width="120" />
|
||||
<el-table-column prop="stuNo" label="学号" show-overflow-tooltip align="center" width="120" />
|
||||
<el-table-column prop="realName" label="姓名" show-overflow-tooltip align="center" width="100" />
|
||||
<el-table-column prop="gender" label="性别" show-overflow-tooltip align="center" width="80">
|
||||
<el-table-column prop="deptName" label="学院" show-overflow-tooltip align="center" min-width="150">
|
||||
<template #header>
|
||||
<el-icon><OfficeBuilding /></el-icon>
|
||||
<span style="margin-left: 4px">学院</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="majorName" label="专业" show-overflow-tooltip align="center" min-width="150">
|
||||
<template #header>
|
||||
<el-icon><Reading /></el-icon>
|
||||
<span style="margin-left: 4px">专业</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="teacherName" label="班主任" show-overflow-tooltip align="center" width="100">
|
||||
<template #header>
|
||||
<el-icon><UserFilled /></el-icon>
|
||||
<span style="margin-left: 4px">班主任</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="grade" label="入学年份" show-overflow-tooltip align="center" width="100">
|
||||
<template #header>
|
||||
<el-icon><Calendar /></el-icon>
|
||||
<span style="margin-left: 4px">入学年份</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="gradeCurr" label="年级" show-overflow-tooltip align="center" width="80">
|
||||
<template #header>
|
||||
<el-icon><Sort /></el-icon>
|
||||
<span style="margin-left: 4px">年级</span>
|
||||
</template>
|
||||
<template #default="scope">
|
||||
<span>{{ formatGender(scope.row.gender) }}</span>
|
||||
<el-tag v-if="scope.row.gradeCurr !== undefined && scope.row.gradeCurr !== null" size="small" type="primary" effect="plain">
|
||||
{{ scope.row.gradeCurr }}
|
||||
</el-tag>
|
||||
<span v-else>-</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="classNo" label="班级" show-overflow-tooltip align="center" width="120">
|
||||
<template #header>
|
||||
<el-icon><Grid /></el-icon>
|
||||
<span style="margin-left: 4px">班级</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="stuNo" label="学号" show-overflow-tooltip align="center" width="120">
|
||||
<template #header>
|
||||
<el-icon><CreditCard /></el-icon>
|
||||
<span style="margin-left: 4px">学号</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="realName" label="姓名" show-overflow-tooltip align="center" width="100">
|
||||
<template #header>
|
||||
<el-icon><Avatar /></el-icon>
|
||||
<span style="margin-left: 4px">姓名</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="gender" label="性别" show-overflow-tooltip align="center" width="80">
|
||||
<template #header>
|
||||
<el-icon><User /></el-icon>
|
||||
<span style="margin-left: 4px">性别</span>
|
||||
</template>
|
||||
<template #default="scope">
|
||||
<GenderTag :sex="scope.row.gender" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="education" label="生源" show-overflow-tooltip align="center" width="100">
|
||||
<template #header>
|
||||
<el-icon><School /></el-icon>
|
||||
<span style="margin-left: 4px">生源</span>
|
||||
</template>
|
||||
<template #default="scope">
|
||||
<span>{{ formatEducation(scope.row.education) }}</span>
|
||||
<el-tag v-if="scope.row.education" size="small" type="info" effect="plain">
|
||||
{{ formatEducation(scope.row.education) }}
|
||||
</el-tag>
|
||||
<span v-else>-</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="majorLevel" label="层次" show-overflow-tooltip align="center" width="100">
|
||||
<template #header>
|
||||
<el-icon><Trophy /></el-icon>
|
||||
<span style="margin-left: 4px">层次</span>
|
||||
</template>
|
||||
<template #default="scope">
|
||||
<span>{{ formatMajorLevel(scope.row.majorLevel) }}</span>
|
||||
<el-tag v-if="scope.row.majorLevel" size="small" type="warning" effect="plain">
|
||||
{{ formatMajorLevel(scope.row.majorLevel) }}
|
||||
</el-tag>
|
||||
<span v-else>-</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="phone" label="联系电话" show-overflow-tooltip align="center" width="120">
|
||||
<template #header>
|
||||
<el-icon><Phone /></el-icon>
|
||||
<span style="margin-left: 4px">联系电话</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="phone" label="联系电话" show-overflow-tooltip align="center" width="120" />
|
||||
<el-table-column prop="money" label="金额" show-overflow-tooltip align="center" width="100">
|
||||
<template #header>
|
||||
<el-icon><Money /></el-icon>
|
||||
<span style="margin-left: 4px">金额</span>
|
||||
</template>
|
||||
<template #default="scope">
|
||||
<span>{{ scope.row.money !== undefined && scope.row.money !== null ? scope.row.money : '-' }}</span>
|
||||
<el-tag v-if="scope.row.money !== undefined && scope.row.money !== null" size="small" type="success" effect="plain">
|
||||
¥{{ scope.row.money }}
|
||||
</el-tag>
|
||||
<span v-else>-</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="checkStatus" label="审核状态" show-overflow-tooltip align="center" width="100">
|
||||
<template #header>
|
||||
<el-icon><CircleCheck /></el-icon>
|
||||
<span style="margin-left: 4px">审核状态</span>
|
||||
</template>
|
||||
<template #default="scope">
|
||||
<span>{{ formatCheckStatus(scope.row.checkStatus) }}</span>
|
||||
<StatusTag
|
||||
:value="scope.row.checkStatus"
|
||||
:options="checkStatusList"
|
||||
:type-map="{ '0': { type: 'warning', effect: 'light' }, '1': { type: 'success', effect: 'light' } }"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" width="150" align="center" fixed="right">
|
||||
<template #header>
|
||||
<el-icon><Setting /></el-icon>
|
||||
<span style="margin-left: 4px">操作</span>
|
||||
</template>
|
||||
<template #default="scope">
|
||||
<el-button
|
||||
icon="Edit"
|
||||
@@ -201,7 +288,7 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="ts" name="TuitionFreeStu">
|
||||
import { reactive, ref, onMounted } from 'vue'
|
||||
import { reactive, ref, onMounted, defineAsyncComponent } from 'vue'
|
||||
import { BasicTableProps, useTable } from "/@/hooks/table";
|
||||
import { fetchList, exportExcel, delObj, getDetail } from "/@/api/stuwork/tuitionfreestu";
|
||||
import { getDeptList } from "/@/api/basic/basicclass";
|
||||
@@ -211,6 +298,15 @@ import { queryAllSchoolYear } from "/@/api/basic/basicyear";
|
||||
import { useMessage, useMessageBox } from "/@/hooks/message";
|
||||
import request from '/@/utils/request'
|
||||
import axios from 'axios'
|
||||
import {
|
||||
User, School, Trophy, Phone, Money, CircleCheck, List,
|
||||
OfficeBuilding, Reading, UserFilled, Calendar, Sort, Grid,
|
||||
CreditCard, Avatar, Setting
|
||||
} from '@element-plus/icons-vue'
|
||||
|
||||
// 引入组件
|
||||
const GenderTag = defineAsyncComponent(() => import('/@/components/GenderTag/index.vue'))
|
||||
const StatusTag = defineAsyncComponent(() => import('/@/components/StatusTag/index.vue'))
|
||||
|
||||
// 定义变量内容
|
||||
const searchFormRef = ref()
|
||||
|
||||
Reference in New Issue
Block a user