Newer
Older
KaiFengPC / src / views / sponeScreen / evaluationKH / ziJinJiXiao.vue
@zhangdeliang zhangdeliang on 12 Oct 3 KB update
<template>
  <!-- 资金绩效评价 -->
  <div class="jiXiaoPingJia">
    <div class="partTitleHM">资金绩效评价</div>
    <div class="ListBoxBody">
      <div class="content">
        <div class="table_content">
          <el-table ref="table" :data="tableData" height="200">
            <el-table-column label="机制建设考核" prop="partitionName" show-overflow-tooltip />
            <el-table-column label="目标要求" prop="quotaTarget" show-overflow-tooltip />
            <el-table-column label="现状情况" prop="reformAchievement" />
            <el-table-column width="80px">
              <template #default="{ row }">
                <div class="monitor" @click.stop="monitorIconClick(row)">查看</div>
              </template>
            </el-table-column>
          </el-table>
        </div>
      </div>
    </div>
  </div>

  <el-dialog
    v-model="opens"
    title="资金绩效评价详情"
    id="dialogContent"
    :modal-append-to-body="false"
    :close-on-click-modal="false"
    width="700px"
  >
    <el-row :gutter="10" class="mb8">
      <el-col :span="1.5">
        <!-- <el-button type="primary" plain icon="Plus" @click="addFile">新增文件</el-button> -->
      </el-col>
    </el-row>
    <el-table :data="tableData2" style="width: 100%" :max-height="400">
      <el-table-column type="index" label="序号" width="50"> </el-table-column>
      <el-table-column prop="name" label="文件"> </el-table-column>
      <el-table-column label="操作" class-name="small-padding fixed-width" width="100">
        <template #default="scope">
          <div @click="handleFileDetail(scope.row)">详情</div>
        </template>
      </el-table-column>
    </el-table>
  </el-dialog>
</template>

<script setup>
// import { hmyztQuotaDataList, querySysFileByType } from '@/api/sponeScreen/jxkh.js';
const { proxy } = getCurrentInstance();
const tableData = ref([]);
const tableData2 = ref([]);

const opens = ref(false);
const getData = async () => {
  const res = await hmyztQuotaDataList({ quotaType: 'zjjxpj' });
  if (res?.code !== 200) return;
  tableData.value = res?.data || [];
};

const monitorIconClick = async val => {
  opens.value = true;

  const res = await querySysFileByType({ quotaType: val.remark, dataYear: 2023 });
  if (res?.code !== 200) return;
  tableData2.value = res?.data || [];
  console.log(tableData2.value, '8888888888');
};

//查看文件
const handleFileDetail = row => {
  window.open(row.url);
};
onMounted(() => {
  // getData();
});
</script>

<style lang="scss" scoped>
.jiXiaoPingJia {
  width: 460px;

  .ListBoxBody {
    background: rgba(8, 75, 125, 1);
    padding: 10px;
    margin-top: -3px;
    .content {
      height: 100%;

      .img_box {
        width: 100%;
        height: 100%;
      }

      .tabs {
        height: 36px;
        color: #fff;
        margin-bottom: 10px;
      }

      .table_content {
        height: 98%;
      }

      .monitor {
        width: 50px;
        height: 20px;
        background: linear-gradient(0deg, #0566d7 0%, #007eff 100%);
        border-radius: 11px;
        color: #d2efff;
      }
    }
  }
}
.consts {
  width: 100%;
  height: 400px;
}

.el-message-box {
  background: #004565 !important;
}
</style>