fuliqi
2024-04-28 3c5de84ea842c28d738e2b53529f1b524af7ecfb
考核结果二级页面
2个文件已修改
62 ■■■■■ 已修改文件
src/api/platform/check-score.js 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/system/result/detail/index1.vue 52 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/api/platform/check-score.js
@@ -1,6 +1,6 @@
import request from '@/utils/request'
// 查询考核积分明细列表
// 查询考核积分卡片列表
export function listScore(query) {
  return request({
    url: '/check/score/list',
@@ -8,6 +8,14 @@
    params: query
  })
}
// 查询考核积分明细列表
export function detailScore(query) {
  return request({
    url: '/check/score/detail',
    method: 'get',
    params: query
  })
}
// 查询考核积分明细详细
export function getScoreIndex(id) {
src/views/system/result/detail/index1.vue
@@ -1,5 +1,5 @@
<template>
  <div style="padding: 0px 10px">
  <div style="padding: 0px 10px" >
    <div>
      <el-menu :default-active="activeIndex" class="el-menu-demo" mode="horizontal" @select="handleSelect"
        style="margin-bottom: 10px">
@@ -26,8 +26,8 @@
      </el-card>
    </div>
    <div style="margin-top: 35px">
      <el-table :data="tableData" style="width: 100%" v-loading="loading">
    <div style="margin-top: 35px;margin-bottom: 35px">
      <el-table :data="tableData" style="width: 100%" v-loading="tableLoading">
        <el-table-column label="考核时间" prop="createTime" align="center">
        </el-table-column>
        <el-table-column label="考核对象" prop="deptId" align="center">
@@ -64,22 +64,23 @@
          </template>
        </el-table-column>
      </el-table>
    </div>
    <div style="text-align: right; margin-top: 10px">
      <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange"
        :current-page="queryParams.pageNum" :page-sizes="[10, 20, 50]" :page-size="queryParams.pageSize"
        layout="total, sizes, prev, pager, next, jumper" :total="tableData.length">
      </el-pagination>
    <pagination
      v-show="total>0"
      :total="total"
      :page.sync="queryParams.pageNum"
      :limit.sync="queryParams.pageSize"
      @pagination="getList"
    />
    </div>
  </div>
</template>
<script>
import { listScore, getScore, delScore, addScore, updateScore, publishScore } from "@/api/platform/check-score";
import { listScore, getScore, delScore, addScore, updateScore, publishScore,detailScore } from "@/api/platform/check-score";
import { areaSelect } from '@/api/system/dept';
import { mapState } from 'vuex';
import * as echarts from 'echarts';
let lineChart = null;
let observer = null;
@@ -92,11 +93,13 @@
      areaList: [],
      date: '',
      dateRange: '',
      // 总条数
      total: 0,
      queryParams: {
        pageNum: 1,
        pageSize: 10,
        deptId: null,
        examinTag:0
        examineTag:0
      },
      tableData: [],
      loading: false,
@@ -117,6 +120,8 @@
    this.date = year + '-' + month;
    this.queryParams.date = this.date;
    this.areaSelect();
    this.getChart(this.$route.query.index)
    this.getList(this.$route.query.index);
  },
  computed: {
@@ -135,17 +140,26 @@
    /** 导航切换 */
    handleSelect(key) {
      this.activeIndex = key;
      this.queryParams.examinTag = key;
      this.queryParams.examineTag = key;
      this.getChart(this.queryParams.deptId);
      this.getList(this.queryParams.deptId);
    },
    /** 查询考核模板列表 */
    getList(deptId) {
    getChart(deptId) {
      this.loading = true;
      lineChart.showLoading();
      listScore(this.queryParams).then(response => {
        this.tableData = response.data[deptId];
        this.loading = false;
        this.initChart(response.data[deptId]);
        this.loading = false;
      });
    },
    /** 查询考核模板列表 */
    getList() {
      this.tableLoading = true;
      detailScore(this.queryParams).then(response => {
        this.tableData = response.rows;
        this.total = response.total;
        this.tableLoading = false;
      });
    },
    handleSizeChange(val) {
@@ -187,7 +201,7 @@
          data: dataList.map((item) => item[0]),
        },
        yAxis: {
          min: 90,
        },
        series: [
          {
@@ -279,13 +293,13 @@
    dateChange() {
      this.queryParams.date = this.date;
      console.log(this.queryParams);
      this.getList(this.queryParams.deptId);
      this.getChart(this.queryParams.deptId);
    }
  },
  mounted() {
    lineChart = echarts.init(this.$refs.chartContent);
    this.getList(this.$route.query.index);
    this.getChart(this.$route.query.index);
    this.observe();
  },
  beforeDestroy() {