liusheng
2 天以前 bbbc478129f72b26e2ec4a2e981ed8698a96880c
src/views/sfstatistics/percentage/index.vue
@@ -58,8 +58,7 @@
        <el-form-item label="服务类型" prop="userName">
          <el-select
            v-model="queryParams.serviceType"
            multiple
            v-model="serviceTypeSingle"
            placeholder="请选择"
          >
            <el-option
@@ -319,6 +318,18 @@
      },
    };
  },
  computed: {
    // 服务类型单选:UI 绑定单值,内部仍以数组形式传给后端
    serviceTypeSingle: {
      get() {
        const st = this.queryParams.serviceType;
        return Array.isArray(st) ? st[0] : st;
      },
      set(val) {
        this.queryParams.serviceType = val == null || val === "" ? [] : [val];
      },
    },
  },
  created() {
    this.getDeptTree();
    this.loadCurrentTabData();
@@ -397,7 +408,8 @@
    handleQuery() {
      if (!this.queryParams.dateRange) this.queryParams.dateRange = [];
      if (!this.queryParams.dateRangecy) this.queryParams.dateRange = [];
      if (!this.queryParams.dateRangecy) this.queryParams.dateRangecy = [];
      this.queryParams.startTime = this.parseTime(
        this.queryParams.dateRange[0]
      );
@@ -471,6 +483,7 @@
      if (type == 1) {
        obj.drcode = row.drcode;
      }
      // 统计类型:病区统计(1)传病区code,科室统计(2)传科室code
      if (this.queryParams.statisticaltype == 1) {
        obj.leavehospitaldistrictcodes = [row.leavehospitaldistrictcode];
        obj.deptcodes = [];
@@ -478,6 +491,7 @@
        obj.deptcodes = [row.deptcode];
        obj.leavehospitaldistrictcodes = [];
      }
      // 应随访时间范围
      if (this.queryParams.endTime) {
        obj.endTime = this.queryParams.endTime;
        obj.startTime = this.queryParams.startTime;
@@ -485,6 +499,14 @@
        obj.startTime = this.parseTime(this.queryParams.dateRange[0]);
        obj.endTime = this.parseTime(this.queryParams.dateRange[1]);
      }
      // 出院时间范围
      if (this.queryParams.hospitalEndTime) {
        obj.hospitalEndTime = this.queryParams.hospitalEndTime;
        obj.hospitalStartTime = this.queryParams.hospitalStartTime;
      } else {
        obj.hospitalStartTime = this.parseTime(this.queryParams.dateRangecy[0]);
        obj.hospitalEndTime = this.parseTime(this.queryParams.dateRangecy[1]);
      }
      obj.statisticaltype = this.queryParams.statisticaltype;