WXL (wul)
昨天 21051d356bb8589ad088abb52492fd2a1909ed9e
src/views/followvisit/discharge/index.vue
@@ -60,6 +60,25 @@
            </el-card>
          </div>
        </el-col>
        <el-col :span="2.5" v-if="orgname == '省立同德翠苑院区'">
          <div class="jgleftvlue">
            <el-card shadow="hover ">
              <div style="padding: 8px">
                <span>警告</span>
                <div
                  style="
                    text-align: center;
                    font-size: 18px;
                    margin-top: 10px;
                    font-weight: 600;
                  "
                >
                  {{ jgvalue }}
                </div>
              </div>
            </el-card>
          </div>
        </el-col>
      </el-row>
    </div>
    <el-row :gutter="20">
@@ -120,7 +139,29 @@
            placeholder="请输入随访人员"
          ></el-input>
        </el-form-item>
        <el-form-item label="主治医生" prop="drname">
          <el-input
            v-model="topqueryParams.drname"
            placeholder="请输入主治医生"
          ></el-input>
        </el-form-item>
        <el-form-item label="经管医生" prop="managementDoctor">
          <el-input
            v-model="topqueryParams.managementDoctor"
            placeholder="请输入主治医生"
          ></el-input>
        </el-form-item>
        <el-form-item label="日期限制" prop="status">
          <el-select v-model="endOut" placeholder="请选择">
            <el-option
              v-for="item in endOuts"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="患者范围" prop="status">
          <el-cascader
            v-model="topqueryParams.scopetype"
@@ -169,7 +210,7 @@
      </el-form>
      <el-divider></el-divider>
      <el-row :gutter="10" class="mb8">
        <el-col :span="1.5">
        <!-- <el-col :span="1.5">
          <div class="documentf">
            <div class="document">
              <el-button
@@ -182,11 +223,10 @@
              >
            </div>
          </div>
        </el-col>
        </el-col> -->
        <el-col :span="1.5">
          <el-button
            type="primary"
            plain
            icon="el-icon-plus"
            size="medium"
            @click="handleAdd"
@@ -238,11 +278,7 @@
        <el-col :span="1.5">
          <div class="documentf">
            <div class="document">
              <el-button
                type="primary"
                plain
                size="medium"
                @click="affiliation()"
              <el-button type="primary" size="medium" @click="affiliation()"
                >本人所属服务</el-button
              >
            </div>
@@ -252,26 +288,37 @@
          <div class="documentf">
            <div class="document">
              <el-button type="success" size="medium" @click="onthatday()"
                >当日服务</el-button
                >今日服务</el-button
              >
            </div>
          </div>
        </el-col>
        <el-col :span="1.5">
        <el-col :span="1.5" v-if="orgname == '景宁畲族自治县人民医院'">
          <div class="documentf">
            <div class="document">
              <el-button
                :disabled="multiple"
                style="background: #983680; color: azure"
                @click="scoreDialogVisible = true"
                >满意度调查</el-button
              <el-tooltip
                content="请先选中服务"
                placement="top"
                :disabled="!multiple"
              >
                <div class="tooltip-wrapper">
                  <el-button
                    type="primary"
                    :disabled="multiple"
                    class="purple-button"
                    @click="scoreDialogVisible = true"
                  >
                    满意度调查
                  </el-button>
                </div>
              </el-tooltip>
            </div>
          </div>
        </el-col>
      </el-row>
      <el-table
        v-loading="loading"
        ref="userform"
        :data="userList"
        :row-class-name="tableRowClassName"
        @selection-change="handleSelectionChange"
@@ -306,6 +353,15 @@
              }}</span></el-button
            >
          </template>
        </el-table-column>
        <el-table-column
          label="诊断名称"
          align="center"
          key="leavediagname"
          prop="leavediagname"
          width="120"
          :show-overflow-tooltip="true"
        >
        </el-table-column>
        <el-table-column
          label="任务状态"
@@ -416,10 +472,19 @@
          prop="drname"
        />
        <el-table-column
          v-if="orgname != '丽水市中医院'"
          label="随访人员"
          align="center"
          key="updateBy"
          prop="updateBy"
          width="120"
        />
        <el-table-column
          v-if="orgname != '丽水市中医院'"
          label="经管医生"
          align="center"
          key="managementDoctor"
          prop="managementDoctor"
          width="120"
        />
        <el-table-column
@@ -481,16 +546,6 @@
          key="leavehospitaldistrictname"
          prop="leavehospitaldistrictname"
          width="120"
        >
        </el-table-column>
        <el-table-column
          label="诊断名称"
          align="center"
          key="leavediagname"
          prop="leavediagname"
          width="120"
          :show-overflow-tooltip="true"
        >
        </el-table-column>
@@ -617,7 +672,7 @@
    </el-row>
    <!-- 满意度弹框 -->
    <el-dialog
      title="随访评分"
      title="随访满意度评分"
      :visible.sync="scoreDialogVisible"
      width="80%"
      :close-on-click-modal="false"
@@ -631,7 +686,7 @@
        />
        <el-table-column
          label="任务名称"
          width="150"
          width="180"
          align="center"
          prop="taskName"
        />
@@ -641,8 +696,7 @@
          align="center"
          key="authenticity"
          prop="authenticity"
          sortable
          width="120"
          width="150"
        >
          <template slot-scope="scope">
            <el-input-number
@@ -659,8 +713,7 @@
          align="center"
          key="weekFinish"
          prop="weekFinish"
          sortable
          width="120"
          width="150"
        >
          <template slot-scope="scope">
            <el-input-number
@@ -677,7 +730,7 @@
          align="center"
          key="standard"
          prop="standard"
          sortable
          width="150"
        >
          <template slot-scope="scope">
            <el-input-number
@@ -694,8 +747,7 @@
          align="center"
          key="timeliness"
          prop="timeliness"
          sortable
          width="120"
          width="150"
        >
          <template slot-scope="scope">
            <el-input-number
@@ -712,8 +764,7 @@
          align="center"
          key="library"
          prop="library"
          sortable
          width="120"
          width="150"
        >
          <template slot-scope="scope">
            <el-input-number
@@ -730,8 +781,7 @@
          align="center"
          key="environment"
          prop="environment"
          sortable
          width="120"
          width="150"
        >
          <template slot-scope="scope">
            <el-input-number
@@ -748,8 +798,7 @@
          align="center"
          key="doctorSatisfaction"
          prop="doctorSatisfaction"
          width="120"
          sortable
          width="150"
        >
          <template slot-scope="scope">
            <el-input-number
@@ -766,8 +815,7 @@
          align="center"
          key="nurseSatisfaction"
          prop="nurseSatisfaction"
          width="120"
          sortable
          width="150"
        >
          <template slot-scope="scope">
            <el-input-number
@@ -784,7 +832,7 @@
          align="center"
          key="total"
          prop="total"
          sortable
          fixed="right"
        >
          <template slot-scope="scope">
            <span>{{ calculateTotal(scope.row) }}</span>
@@ -836,7 +884,17 @@
            </el-form-item>
          </el-col>
        </el-row>
        <el-row>
          <el-col :span="8">
            <el-form-item label="过滤医生" width="100" prop="filterDrname">
              <el-input
                v-model="form.filterDrname"
                placeholder="请输入医生姓名"
                maxlength="30"
              />
            </el-form-item>
          </el-col>
        </el-row>
        <el-row>
          <el-col :span="24">
            <el-form-item label="过滤原因">
@@ -1017,6 +1075,7 @@
  buidegetTasklist,
  addserviceSubtask,
  query360PatInfo,
  addsatisfaction,
} from "@/api/AiCentre/index";
import { alterpatient, particularpatient } from "@/api/patient/homepage";
import Treeselect from "@riophae/vue-treeselect";
@@ -1067,6 +1126,7 @@
      inputVisible: false,
      Labelchange: false,
      ycvalue: "",
      jgvalue: "",
      yfsvalue: "",
      inputValue: "",
      preachform: "",
@@ -1109,7 +1169,7 @@
        //   value: 0,
        // },
        {
          name: "应随访",
          name: "需随访",
          value: 0,
        },
        {
@@ -1120,10 +1180,10 @@
          name: "待随访",
          value: 0,
        },
        {
          name: "已发送",
          value: 0,
        },
        // {
        //   name: "已发送",
        //   value: 0,
        // },
        // {
        //   name: "表单已发送",
@@ -1147,6 +1207,18 @@
        qystatus: "",
        btstatus: "",
      },
      // endOut: 1,
      endOut: localStorage.getItem("orgname") == "丽水市中医院" ? 0 : 1, //0 出院时间(正序)    1 出院时间(倒序)   2 发送时间(正序)    3 发送时间(倒序)  7应随访日期(倒序) 应随访日期(正序)
      endOuts: [
        {
          value: 0,
          label: "截止至当日服务",
        },
        {
          value: 1,
          label: "全部服务",
        },
      ],
      topicoptionssort: [
        {
          value: 0,
@@ -1164,13 +1236,21 @@
          value: 3,
          label: "发送时间(倒序)",
        },
        {
          value: 7,
          label: "应随访日期(正序)",
        },
        {
          value: 8,
          label: "应随访日期(倒序)",
        },
      ],
      // 查询参数
      topqueryParams: {
        pageNum: 1,
        pageSize: 10,
        sendstate: 2,
        sort: 2, //0 出院时间(正序)    1 出院时间(倒序)   2 发送时间(正序)    3 发送时间(倒序)
        sort: localStorage.getItem("orgname") == "丽水市中医院" ? 8 : 2, //0 出院时间(正序)    1 出院时间(倒序)   2 发送时间(正序)    3 发送时间(倒序)  7应随访日期(倒序) 应随访日期(正序)
        serviceType: 2,
        searchscope: 3,
        visitCount: 1,
@@ -1178,6 +1258,7 @@
        leaveldeptcodes: [],
        leavehospitaldistrictcodes: [],
      },
      orgname: "",
      propss: { multiple: true },
      options: [],
@@ -1227,6 +1308,10 @@
          label: "异常",
        },
        {
          value: 2,
          label: "警告",
        },
        {
          value: 0,
          label: "正常",
        },
@@ -1257,8 +1342,8 @@
          YongHuXX: {
            XiTongID: "SUIFANGXT",
            XiTongMC: "随访系统",
            YongHuID: "1400466972205912064",
            YongHuXM: "JNRMYY",
            YongHuID: localStorage.getItem("YongHuID"),
            YongHuXM: localStorage.getItem("YongHuXM"),
            ZuZhiJGID: localStorage.getItem("orgid"),
            ZuZhiJGMC: localStorage.getItem("orgname"),
            idp: "lyra",
@@ -1279,6 +1364,7 @@
    this.serviceState = store.getters.serviceState;
    this.checkboxlist = store.getters.checkboxlist;
    this.errtype = this.$route.query.errtype;
    this.orgname = localStorage.getItem("orgname");
    this.leavehospitaldistrictcode =
      this.$route.query.leavehospitaldistrictcode;
    this.sourcetype[0].children = store.getters.belongDepts.map((dept) => {
@@ -1309,13 +1395,19 @@
    /** 查询随访服务列表 */
    getList(refresh) {
      // 默认全部
      if (this.topqueryParams.searchscope == 3) {
        this.topqueryParams.leaveldeptcodes = store.getters.belongDepts.map(
          (obj) => obj.deptCode
        );
        this.topqueryParams.leavehospitaldistrictcodes =
          store.getters.belongWards.map((obj) => obj.districtCode);
      }
      if (this.endOut == 0) {
        this.topqueryParams.endSendDateTime = this.formatDateToYYYYMMDDHHMMSS(
          this.getEndOfDay()
        );
      } else {
        // this.topqueryParams.endSendDateTime = null;
      }
      // 接受异常跳转
      if (this.errtype) {
@@ -1342,9 +1434,10 @@
          // this.cardlist[1].value = response.rows[0].wzx;
          this.cardlist[1].value = response.rows[0].ysf;
          this.ycvalue = response.rows[0].yc;
          this.jgvalue = response.rows[0].jg;
          this.cardlist[2].value = response.rows[0].fssb;
          this.cardlist[3].value = response.rows[0].dsf;
          this.cardlist[4].value = response.rows[0].yfs2;
          // this.cardlist[4].value = response.rows[0].yfs2;
          this.yfsvalue = response.rows[0].yfs;
        }
        this.loading = false;
@@ -1373,9 +1466,24 @@
        this.total = response.total;
      });
    },
    // 时间
    getEndOfDay() {
      const date = new Date(); // 创建一个表示当前时间的Date对象
      date.setHours(23, 59, 59, 0); // 将时间设置为23:59:59.000
      return date;
    },
    formatDateToYYYYMMDDHHMMSS(date) {
      const year = date.getFullYear();
      const month = String(date.getMonth() + 1).padStart(2, "0"); // 月份补零
      const day = String(date.getDate()).padStart(2, "0"); // 日期补零
      const hours = String(date.getHours()).padStart(2, "0");
      const minutes = String(date.getMinutes()).padStart(2, "0");
      const seconds = String(date.getSeconds()).padStart(2, "0");
      return `${year}-${month}-${day}`;
    },
    affiliation() {
      this.topqueryParams.drcode = store.getters.hisUserId;
      this.topqueryParams.nurseId = store.getters.hisUserId;
      this.topqueryParams.managementDoctorCode = store.getters.hisUserId;
      this.getList(1);
    },
    onthatday() {
@@ -1412,17 +1520,16 @@
      buidegetTasklist(obj).then((response) => {
        this.userList = response.rows[0].serviceSubtaskList;
        this.total = response.total;
        if (refresh) {
          this.cardlist[0].value =
            Number(response.rows[0].wzx) + Number(response.rows[0].ysf);
          this.cardlist[1].value = response.rows[0].wzx;
          this.cardlist[2].value = response.rows[0].ysf;
          this.ycvalue = response.rows[0].yc;
          this.cardlist[3].value = response.rows[0].fssb;
          this.cardlist[4].value = response.rows[0].dsf;
          this.cardlist[5].value = response.rows[0].yfs2;
          this.yfsvalue = response.rows[0].yfs;
        }
        this.cardlist[0].value =
          Number(response.rows[0].wzx) + Number(response.rows[0].ysf);
        this.cardlist[1].value = response.rows[0].wzx;
        this.cardlist[2].value = response.rows[0].ysf;
        this.ycvalue = response.rows[0].yc;
        this.jgvalue = response.rows[0].jg;
        this.cardlist[3].value = response.rows[0].fssb;
        this.cardlist[4].value = response.rows[0].dsf;
        // this.cardlist[5].value = response.rows[0].yfs2;
        this.yfsvalue = response.rows[0].yfs;
        this.loading = false;
        this.userList.forEach((item) => {
          let idArray = null;
@@ -1570,6 +1677,8 @@
      });
      if (this.selectedRows.length > 0) {
        this.multiple = false;
      } else {
        this.multiple = true;
      }
    },
@@ -1590,15 +1699,25 @@
    // 保存评分
    saveScores() {
      // 这里可以添加保存逻辑,如调用API保存评分
      this.$message.success("评分保存成功");
      this.scoreDialogVisible = false;
      // 更新主表格数据
      this.userList = this.userList.map((user) => {
        const updatedUser = this.selectedRows.find((row) => row.id === user.id);
        return updatedUser ? updatedUser : user;
      this.selectedRows.forEach((item) => {
        item.createBy = null;
        item.patName = item.sendname;
        item.hospitaldistrictname = item.leavehospitaldistrictname;
      });
      addsatisfaction(this.selectedRows).then((res) => {
        if (res.code == 200) {
          this.$message.success("评分保存成功");
          this.scoreDialogVisible = false;
          this.selectedRows = [];
          this.$refs.userform.clearSelection();
        } else {
          this.$modal.msgWarning("评分保存失败");
          this.scoreDialogVisible = false;
          this.selectedRows = [];
          this.$refs.userform.clearSelection();
        }
      });
      // 这里可以添加保存逻辑,如调用API保存评分
    },
    //删除选项
    handleClose(tag) {
@@ -1632,11 +1751,10 @@
    },
    //患者360跳转
    gettoken360(sfzh, drcode, drname) {
      // this.$modal.msgWarning("360功能暂未开通");
      this.postData.YeWuXX.BingRenXX.ZhengJianHM = sfzh;
      if (this.postData.XiaoXiTou.ZuHuMC == "丽水市中医院") {
        this.postData.YeWuXX.YongHuXX.YongHuID = "1400398571877961728";
        this.postData.YeWuXX.YongHuXX.YongHuXM = "LSZYY";
      }
      query360PatInfo(this.postData).then((res) => {
        if (res.data.url) {
          window.open(res.data.url, "_blank");
@@ -1749,10 +1867,8 @@
    Seedetails(row) {
      let type = "";
      console.log(row, "rwo");
      if (row.preachformson) {
        if (row.preachformson.includes("3")) {
          type = 1;
        }
      if (row.type == 1) {
        type = 1;
      }
      this.$router.push({
        path: "/followvisit/record/detailpage/",
@@ -1806,6 +1922,7 @@
    handleUpdate(row) {
      particularpatient(row.patid).then((response) => {
        this.form = response.data;
        this.form.filterDrname = store.getters.nickName;
      });
      this.amendtag = true;
      this.Labelchange = true;
@@ -1818,7 +1935,7 @@
      } else if (too == 2) {
        this.topqueryParams.excep = 1;
      }
      this.handleQuery();
      this.handleQuery(1);
    },
    /** 导出按钮操作 */
    handleExport() {
@@ -1836,6 +1953,8 @@
    tableRowClassName({ row, rowIndex }) {
      if (row.excep == 1) {
        return "warning-row";
      } else if (row.excep == 2) {
        return "remind-row";
      }
      return "";
    },
@@ -1898,6 +2017,9 @@
}
::v-deep.el-table .warning-row {
  background: #eec4c4;
}
::v-deep.el-table .remind-row {
  background: #fcf5aa;
}
.documentf {
@@ -1978,10 +2100,12 @@
  }
}
::v-deep.leftvlue .el-card__body {
  background: #d0e9fd;
  background: #f2f8ff;
  color: #324a9b;
}
::v-deep.leftvlue .el-card__body:hover {
  background: #8dc8f8;
  background: #3664d9;
  color: #fff;
  cursor: pointer; /* 鼠标悬浮时变为手形 */
}
::v-deep.errleftvlue .el-card__body {
@@ -1991,12 +2115,16 @@
  background: #f88d96;
  cursor: pointer; /* 鼠标悬浮时变为手形 */
}
::v-deep.jgleftvlue .el-card__body:hover {
  background: #f7f075;
  cursor: pointer; /* 鼠标悬浮时变为手形 */
}
::v-deep.ysfleftvlue .el-card__body {
  background: #d0fdd8;
}
::v-deep.ysfleftvlue .el-card__body:hover {
  background: #8df8a4;
  background: #0abc54;
  cursor: pointer; /* 鼠标悬浮时变为手形 */
}
.button-bb {
@@ -2021,7 +2149,7 @@
  color: #ffffff;
}
.button-zx {
  background: #4fabe9;
  background: #324a9b;
  padding: 5px;
  border-radius: 1px;
  color: #ffffff;
@@ -2032,7 +2160,30 @@
    font-size: 24px;
  }
}
.purple-button {
  background-color: #7e22ce;
  border-color: #7e22ce;
  color: #fff;
}
.purple-button:hover,
.purple-button:focus {
  background-color: #9333ea;
  border-color: #9333ea;
}
.purple-button:active {
  background-color: #6b21a8;
  border-color: #6b21a8;
}
.button-textxga {
  color: #de7897;
}
.purple-button.is-disabled {
  background-color: #d8b4fe;
  border-color: #d8b4fe;
  opacity: 1; /* 保持禁用状态透明度 */
}
// 选项字体放大
// ::v-deep.el-checkbox-group {
//   span {