WXL (wul)
昨天 21051d356bb8589ad088abb52492fd2a1909ed9e
src/views/sfstatistics/percentage/index.vue
@@ -1168,6 +1168,20 @@
                  </template>
                </el-table-column>
                <el-table-column
                  label="任务执行方式"
                  align="center"
                  key="preachform"
                  prop="preachform"
                  width="160"
                  :show-overflow-tooltip="true"
                >
                  <template slot-scope="scope">
                    <span v-for="item in scope.row.preachform"
                      >{{ item }}、
                    </span>
                  </template>
                </el-table-column>
                <el-table-column
                  prop="visitTime"
                  align="center"
                  label="应随访时间"
@@ -1420,6 +1434,7 @@
      allDeptCodes: [],
      // 存储所有病区代码
      allWardCodes: [],
      checkboxlist: [],
      // 表单参数
      form: {},
      forms: {
@@ -1469,6 +1484,7 @@
  created() {
    this.getDeptTree();
    this.getList();
    this.checkboxlist = store.getters.checkboxlist;
    this.orgname = localStorage.getItem("orgname");
  },
@@ -1487,12 +1503,14 @@
          ? this.allDeptCodes
          : this.queryParams.deptcodes,
      };
      this.loading = true;
      // 移除可能存在的"all"值
      delete params.leavehospitaldistrictcodes.all;
      delete params.deptcodes.all;
      getSfStatistics(params).then((response) => {
        console.log(response);
        this.loading = false;
        // this.total = response.total;
        this.userList = this.customSort(response.data);
      });
@@ -1851,7 +1869,25 @@
      this.infotitleVisible = true;
      this.infotitle = title;
      this.infotitlelist = row; // 假设row就是需要展示的详细数组
      console.log(this.infotitlelist, "this.infotitlelist");
      this.infotitlelist.forEach((item) => {
        let idArray = null;
        if (item.preachform) {
          if (item.endtime) {
            item.preachformson = item.preachform;
            idArray = item.preachform.split(",");
          }
          item.preachform = idArray.map((value) => {
            // 查找id对应的对象
            const item = this.checkboxlist.find((item) => item.value == value);
            // 如果找到对应的id,返回label值,否则返回null
            return item ? item.label : null;
          });
        }
      });
      // 初始化加载
      this.loadIndex = 0;
      this.currentDisplayList = [];
@@ -1865,6 +1901,8 @@
      // 模拟异步加载,实际可能是直接切片本地数据
      setTimeout(() => {
        console.log(this.infotitlelist, "this.infotitlelist");
        const nextChunk = this.infotitlelist.slice(
          this.loadIndex,
          this.loadIndex + this.pageSize