feat: 流程类型筛选改从后端字典接口加载(保留静态兜底)
This commit is contained in:
@@ -31,8 +31,11 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="row in section.rows || []" :key="row.trainingInstitutionName">
|
||||
<td>{{ row.trainingInstitutionName || "-" }}</td>
|
||||
<tr
|
||||
v-for="row in section.rows || []"
|
||||
:key="row.trainingInstitutionName"
|
||||
>
|
||||
<td>{{ row.trainingInstitutionName || '-' }}</td>
|
||||
<td>{{ formatCount(row.openCount) }}</td>
|
||||
<td>{{ formatAmount(row.openAmount) }}</td>
|
||||
<td>{{ formatCount(row.verifyCount) }}</td>
|
||||
@@ -60,72 +63,72 @@
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { ThinkTrainingBusinessSection } from "@/api/think/thinkOrder/model";
|
||||
import type { ThinkTrainingBusinessSection } from '@/api/think/thinkOrder/model';
|
||||
|
||||
defineProps<{
|
||||
sections: ThinkTrainingBusinessSection[];
|
||||
}>();
|
||||
defineProps<{
|
||||
sections: ThinkTrainingBusinessSection[];
|
||||
}>();
|
||||
|
||||
const formatCount = (value?: number | string) => {
|
||||
if (value === undefined || value === null || value === "") {
|
||||
return "0";
|
||||
}
|
||||
return String(value);
|
||||
};
|
||||
const formatCount = (value?: number | string) => {
|
||||
if (value === undefined || value === null || value === '') {
|
||||
return '0';
|
||||
}
|
||||
return String(value);
|
||||
};
|
||||
|
||||
const formatAmount = (value?: number | string) => {
|
||||
if (value === undefined || value === null || value === "") {
|
||||
return "0";
|
||||
}
|
||||
return String(value);
|
||||
};
|
||||
const formatAmount = (value?: number | string) => {
|
||||
if (value === undefined || value === null || value === '') {
|
||||
return '0';
|
||||
}
|
||||
return String(value);
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.training-report {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 28px;
|
||||
}
|
||||
.training-report {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 28px;
|
||||
}
|
||||
|
||||
.report-section {
|
||||
overflow-x: auto;
|
||||
}
|
||||
.report-section {
|
||||
overflow-x: auto;
|
||||
}
|
||||
|
||||
.report-table {
|
||||
width: 100%;
|
||||
min-width: 1200px;
|
||||
border-collapse: collapse;
|
||||
table-layout: fixed;
|
||||
background: #fff;
|
||||
}
|
||||
.report-table {
|
||||
width: 100%;
|
||||
min-width: 1200px;
|
||||
border-collapse: collapse;
|
||||
table-layout: fixed;
|
||||
background: #fff;
|
||||
}
|
||||
|
||||
.report-table th,
|
||||
.report-table td {
|
||||
padding: 12px 10px;
|
||||
border: 1px solid #1f1f1f;
|
||||
font-size: 14px;
|
||||
line-height: 1.45;
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
word-break: break-all;
|
||||
}
|
||||
.report-table th,
|
||||
.report-table td {
|
||||
padding: 12px 10px;
|
||||
border: 1px solid #1f1f1f;
|
||||
font-size: 14px;
|
||||
line-height: 1.45;
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
.report-table th {
|
||||
font-weight: 600;
|
||||
}
|
||||
.report-table th {
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.section-title {
|
||||
font-size: 22px;
|
||||
line-height: 1.4;
|
||||
padding: 16px 12px !important;
|
||||
}
|
||||
.section-title {
|
||||
font-size: 22px;
|
||||
line-height: 1.4;
|
||||
padding: 16px 12px !important;
|
||||
}
|
||||
|
||||
.institution-col {
|
||||
width: 240px;
|
||||
}
|
||||
.institution-col {
|
||||
width: 240px;
|
||||
}
|
||||
|
||||
.total-row td {
|
||||
font-weight: 600;
|
||||
}
|
||||
.total-row td {
|
||||
font-weight: 600;
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user