WXL (wul)
2 天以前 c899dff1fce7f8054008cd9887a9729cdffd88cb
测试完成
已修改3个文件
已添加3个文件
178 ■■■■■ 文件已修改
src/views/followvisit/mzsatisfaction/index.vue 43 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/followvisit/zysatisfaction/index.vue 46 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/sfstatistics/percentage/components/FirstFollowUp.vue 89 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
随访通用11.18 (2).zip 补丁 | 查看 | 原始文档 | blame | 历史
随访通用11.18.zip 补丁 | 查看 | 原始文档 | blame | 历史
随访通用11.19.zip 补丁 | 查看 | 原始文档 | blame | 历史
src/views/followvisit/mzsatisfaction/index.vue
@@ -64,6 +64,7 @@
            clearable
            placeholder="请选择点位"
            style="width: 240px"
            @change="handlePointLocationChange"
          >
            <el-option
              v-for="item in pointOptions"
@@ -1253,6 +1254,8 @@
      checkboxlist: [],
      // ç‚¹ä½åˆ—表(同德院区,deptType=3)
      pointOptions: [],
      // ç‚¹ä½é€‰æ‹©åŽ†å²å€¼ï¼ˆç”¨äºŽâ€œå…¨éƒ¨/具体点位”互斥判断)
      pointPrevLocations: [],
      // è¡¨å•校验
      rules: {},
    };
@@ -1405,8 +1408,30 @@
          });
        };
        walk(response && response.data);
        this.pointOptions = flat;
        this.pointOptions = [{ label: "全部", value: "all" }, ...flat];
        // è¿›å…¥é¡µé¢é»˜è®¤æŸ¥è¯¢å…¨éƒ¨ç‚¹ä½
        this.topqueryParams.pointLocations = ["all"];
        this.pointPrevLocations = ["all"];
        if (!this.errtype) {
          this.getList(1);
        }
      });
    },
    // ç‚¹ä½é€‰æ‹©ï¼šå…¨éƒ¨ä¸Žå…·ä½“点位互斥
    handlePointLocationChange(val) {
      const all = "all";
      const hasAll = val.includes(all);
      if (hasAll && val.length > 1) {
        const prev = this.pointPrevLocations || [];
        if (prev.includes(all)) {
          // ä¹‹å‰å·²é€‰â€œå…¨éƒ¨â€ï¼Œæœ¬æ¬¡æ–°å¢žå…·ä½“点位 â†’ åŽ»æŽ‰â€œå…¨éƒ¨â€
          this.topqueryParams.pointLocations = val.filter((v) => v !== all);
        } else {
          // æœ¬æ¬¡æ–°å¢žâ€œå…¨éƒ¨â€ â†’ åªä¿ç•™â€œå…¨éƒ¨â€
          this.topqueryParams.pointLocations = [all];
        }
      }
      this.pointPrevLocations = [...this.topqueryParams.pointLocations];
    },
    // ç‚¹ä½åç§°ï¼šå°† pointLocation ç¼–码映射为点位名称
@@ -1586,10 +1611,15 @@
    // æž„造查询/导出参数:选择点位时科室/病区传 null,否则保持原值
    buildQueryParams() {
      const params = { ...this.topqueryParams };
      if (
        this.topqueryParams.pointLocations &&
        this.topqueryParams.pointLocations.length > 0
      ) {
      let locations = this.topqueryParams.pointLocations || [];
      // â€œå…¨éƒ¨â€ç‚¹ä½ï¼šå±•开为所有实际点位编码
      if (locations.includes("all")) {
        locations = this.pointOptions
          .filter((p) => p.value !== "all")
          .map((p) => p.value);
      }
      params.pointLocations = locations;
      if (locations.length > 0) {
        params.leaveldeptcodes = null;
        params.leavehospitaldistrictcodes = null;
      }
@@ -1631,8 +1661,9 @@
        scopetype: [],
        leaveldeptcodes: [],
        leavehospitaldistrictcodes: [],
        pointLocations: [],
        pointLocations: ["all"],
      };
      this.pointPrevLocations = ["all"];
      this.handleQuery(1);
    },
    handleSelectionChange(rows) {
src/views/followvisit/zysatisfaction/index.vue
@@ -87,6 +87,7 @@
            clearable
            placeholder="请选择点位"
            style="width: 240px"
            @change="handlePointLocationChange"
          >
            <el-option
              v-for="item in pointOptions"
@@ -1249,6 +1250,8 @@
      checkboxlist: [],
      // ç‚¹ä½åˆ—表(同德院区,deptType=3)
      pointOptions: [],
      // ç‚¹ä½é€‰æ‹©åŽ†å²å€¼ï¼ˆç”¨äºŽâ€œå…¨éƒ¨/具体点位”互斥判断)
      pointPrevLocations: [],
      // è¡¨å•校验
      rules: {},
    };
@@ -1426,8 +1429,30 @@
          });
        };
        walk(response && response.data);
        this.pointOptions = flat;
        this.pointOptions = [{ label: "全部", value: "all" }, ...flat];
        // è¿›å…¥é¡µé¢é»˜è®¤æŸ¥è¯¢å…¨éƒ¨ç‚¹ä½
        this.topqueryParams.pointLocations = ["all"];
        this.pointPrevLocations = ["all"];
        if (!this.errtype) {
          this.getList(1);
        }
      });
    },
    // ç‚¹ä½é€‰æ‹©ï¼šå…¨éƒ¨ä¸Žå…·ä½“点位互斥
    handlePointLocationChange(val) {
      const all = "all";
      const hasAll = val.includes(all);
      if (hasAll && val.length > 1) {
        const prev = this.pointPrevLocations || [];
        if (prev.includes(all)) {
          // ä¹‹å‰å·²é€‰â€œå…¨éƒ¨â€ï¼Œæœ¬æ¬¡æ–°å¢žå…·ä½“点位 â†’ åŽ»æŽ‰â€œå…¨éƒ¨â€
          this.topqueryParams.pointLocations = val.filter((v) => v !== all);
        } else {
          // æœ¬æ¬¡æ–°å¢žâ€œå…¨éƒ¨â€ â†’ åªä¿ç•™â€œå…¨éƒ¨â€
          this.topqueryParams.pointLocations = [all];
        }
      }
      this.pointPrevLocations = [...this.topqueryParams.pointLocations];
    },
    // ç‚¹ä½åç§°ï¼šå°† pointLocation ç¼–码映射为点位名称
@@ -1627,10 +1652,15 @@
    // æž„造查询/导出参数:选择点位时科室/病区传 null,否则保持原值
    buildQueryParams() {
      const params = { ...this.topqueryParams };
      if (
        this.topqueryParams.pointLocations &&
        this.topqueryParams.pointLocations.length > 0
      ) {
      let locations = this.topqueryParams.pointLocations || [];
      // â€œå…¨éƒ¨â€ç‚¹ä½ï¼šå±•开为所有实际点位编码
      if (locations.includes("all")) {
        locations = this.pointOptions
          .filter((p) => p.value !== "all")
          .map((p) => p.value);
      }
      params.pointLocations = locations;
      if (locations.length > 0) {
        params.leaveldeptcodes = null;
        params.leavehospitaldistrictcodes = null;
      }
@@ -1671,8 +1701,9 @@
        scopetype: [],
        leaveldeptcodes: [],
        leavehospitaldistrictcodes: [],
        pointLocations: [],
        pointLocations: ["all"],
      };
      this.pointPrevLocations = ["all"];
      this.handleQuery(1);
    },
    /** é‡ç½®æŒ‰é’®æ“ä½œ */
@@ -1693,8 +1724,9 @@
        scopetype: [],
        leaveldeptcodes: [],
        leavehospitaldistrictcodes: [],
        pointLocations: [],
        pointLocations: ["all"],
      };
      this.pointPrevLocations = ["all"];
    },
    handleSelectionChange(rows) {
      this.selectedRows = rows.map((row) => {
src/views/sfstatistics/percentage/components/FirstFollowUp.vue
@@ -1256,6 +1256,14 @@
        this.orgname == "第一人民医院吴山院区"
      );
    },
    // ç¬¬ä¸€äººæ°‘医院三个院区:及时率按 åŠæ—¶å®Œæˆ/需随访 è®¡ç®—
    isDiyiRenmin() {
      return (
        this.orgname == "第一人民医院湖滨院区" ||
        this.orgname == "第一人民医院吴山院区" ||
        this.orgname == "第一人民医院城东院区"
      );
    },
  },
  methods: {
    loadData() {
@@ -1380,8 +1388,24 @@
      const rate = ((need - timeout) / need) * 100;
      return (rate < 0 ? 0 : rate).toFixed(2) + "%";
    },
    // åŠæ—¶çŽ‡å±•ç¤ºæ–‡æ¡ˆï¼šç›®æ ‡åŒ»é™¢å‰ç«¯è®¡ç®—ï¼Œå…¶ä»–ç”¨åŽç«¯ rate å­—段
    // è®¡ç®—及时率(第一人民医院三院区):及时完成 / éœ€éšè®¿
    calculateTimelyRateByCompletion(timelyFollowUp, needFollowUp) {
      const timely = Number(timelyFollowUp) || 0;
      const need = Number(needFollowUp) || 0;
      if (need <= 0) {
        return "0.00%";
      }
      const rate = (timely / need) * 100;
      return (rate < 0 ? 0 : rate).toFixed(2) + "%";
    },
    // åŠæ—¶çŽ‡å±•ç¤ºæ–‡æ¡ˆï¼šç¬¬ä¸€äººæ°‘åŒ»é™¢ä¸‰é™¢åŒºå‰ç«¯æŒ‰åŠæ—¶å®Œæˆ/需随访,目标医院按(需随访-超时)/需随访,其他用后端 rate å­—段
    getTimelyRateText(row) {
      if (this.isDiyiRenmin) {
        return this.calculateTimelyRateByCompletion(
          row.timelyFollowUp,
          row.needFollowUp
        );
      }
      if (this.isTargetHospital) {
        return this.calculateTimelyRate(
          row.needFollowUp,
@@ -1429,7 +1453,20 @@
            sums[index] = "0.00%";
          }
        } else if (column.property === "rate") {
          if (this.isTargetHospital) {
          if (this.isDiyiRenmin) {
            const totalTimely = data.reduce(
              (sum, item) => sum + (Number(item.timelyFollowUp) || 0),
              0
            );
            const totalNeed = data.reduce(
              (sum, item) => sum + (Number(item.needFollowUp) || 0),
              0
            );
            sums[index] = this.calculateTimelyRateByCompletion(
              totalTimely,
              totalNeed
            );
          } else if (this.isTargetHospital) {
            const totalNeed = data.reduce(
              (sum, item) => sum + (Number(item.needFollowUp) || 0),
              0
@@ -1524,7 +1561,9 @@
        "el-tooltip",
        {
          props: {
            content: this.isTargetHospital
            content: this.isDiyiRenmin
              ? "及时率=及时完成/需随访"
              : this.isTargetHospital
              ? "及时率=(需随访-人工规定时间内没打过电话)/需随访"
              : "(出院时间+任务周期)小于完成时间即为超时;(需随访-超时)/需随访",
            placement: "top",
@@ -1612,7 +1651,20 @@
            sums[index] = "0.00%";
          }
        } else if (column.property === "rate") {
          if (this.isTargetHospital) {
          if (this.isDiyiRenmin) {
            const totalTimely = data.reduce(
              (sum, item) => sum + (Number(item.timelyFollowUp) || 0),
              0
            );
            const totalNeed = data.reduce(
              (sum, item) => sum + (Number(item.needFollowUp) || 0),
              0
            );
            sums[index] = this.calculateTimelyRateByCompletion(
              totalTimely,
              totalNeed
            );
          } else if (this.isTargetHospital) {
            const totalNeed = data.reduce(
              (sum, item) => sum + (Number(item.needFollowUp) || 0),
              0
@@ -2142,9 +2194,21 @@
          : "0.00%"
      );
      // åŠæ—¶çŽ‡ï¼ˆç›®æ ‡åŒ»é™¢è®¡ç®—ï¼Œå…¶ä»–å– rate å¹³å‡ï¼‰
      // åŠæ—¶çŽ‡ï¼ˆç¬¬ä¸€äººæ°‘åŒ»é™¢ä¸‰é™¢åŒºæŒ‰åŠæ—¶å®Œæˆ/需随访,目标医院计算,其他取 rate å¹³å‡ï¼‰
      if (showTimelyRate) {
        if (graded) {
        if (this.isDiyiRenmin) {
          const totalTimely = data.reduce(
            (s, r) => s + (Number(r.timelyFollowUp) || 0),
            0
          );
          const totalNeed = data.reduce(
            (s, r) => s + (Number(r.needFollowUp) || 0),
            0
          );
          sums.push(
            this.calculateTimelyRateByCompletion(totalTimely, totalNeed)
          );
        } else if (graded) {
          const totalNeed = data.reduce(
            (s, r) => s + (Number(r.needFollowUp) || 0),
            0
@@ -2661,8 +2725,17 @@
        summaries[followUpRateIdx] = (avgFollowUpRate * 100).toFixed(2) + "%";
      }
      // åŠæ—¶çŽ‡è®¡ç®—ï¼šç›®æ ‡åŒ»é™¢ (需随访-人工超时)/需随访,其他取后端 rate å¹³å‡
      if (graded) {
      // åŠæ—¶çŽ‡è®¡ç®—ï¼šç¬¬ä¸€äººæ°‘åŒ»é™¢ä¸‰é™¢åŒºæŒ‰åŠæ—¶å®Œæˆ/需随访,目标医院 (需随访-人工超时)/需随访,其他取后端 rate å¹³å‡
      if (this.isDiyiRenmin) {
        const totalTimely = this.tableData.reduce(
          (sum, item) => sum + (Number(item.timelyFollowUp) || 0),
          0
        );
        summaries[timelyRateIdx] = this.calculateTimelyRateByCompletion(
          totalTimely,
          totalNeed
        );
      } else if (graded) {
        const totalTimeout = this.tableData.reduce(
          (sum, item) => sum + (Number(item.manualCallTimeout) || 0),
          0
Ëæ·ÃͨÓÃ11.18 (2).zip
Binary files differ
Ëæ·ÃͨÓÃ11.18.zip
Binary files differ
Ëæ·ÃͨÓÃ11.19.zip
Binary files differ