riku
2025-09-18 c1d2051abc8ca88cd07f0d7c56c0dbf8165d5c33
src/views/fysp/data-product/base-data-product/PordProblemRecurrence.vue
@@ -1,5 +1,6 @@
<template>
  <FYTable
    id="fyTable"
    @search="onSearch"
    :data="showData"
    :pagination="false"
@@ -34,7 +35,14 @@
        <el-radio :value="2">按问题类型统计</el-radio>
      </el-radio-group>
    </template>
    <template #buttons> </template>
    <template #buttons>
      <FYDownloadTableButton
        label="下载清单"
        table-id="fyTable"
        :file-name="fileName"
        :disabled="downloadDisabled"
      ></FYDownloadTableButton>
    </template>
    <template #table-column="{ size }">
      <!-- <el-table-column fixed="left" label="序号" width="53">
        <template #default="{ row }">
@@ -58,14 +66,9 @@
      </el-table-column>
      <el-table-column prop="townName" label="街镇" width="110">
      </el-table-column>
      <el-table-column prop="problemType" label="问题类型" width="110">
      <el-table-column prop="problemType" label="问题类型" width="170">
      </el-table-column>
      <el-table-column
        v-if="radio == 1"
        prop="problemName"
        label="问题名称"
        width="200"
      >
      <el-table-column v-if="radio == 1" prop="problemName" label="问题名称">
      </el-table-column>
      <el-table-column prop="proNum" label="问题数" width="70">
      </el-table-column>
@@ -134,6 +137,19 @@
  return res;
});
const fileName = computed(() => {
  const { locations, scenetype, timeArr } = formSearch.value;
  return `${locations.dName}${dayjs(timeArr[0]).format(
    'YYYY年MM月DD日'
  )}至${dayjs(timeArr[1]).format('YYYY年MM月DD日')}${
    scenetype.label
  }问题复发清单`;
});
const downloadDisabled = computed(() => {
  return tableData.value.length == 0;
});
function onSearch(page, callback) {
  fetchProbRecurrence().finally(() => callback());
}