qx
qx
2025-06-05 c56b67b1564e7d5d88860767de0f4f5b70c487ee
src/views/doctor/examination/index.vue
@@ -1,205 +1,87 @@
<template>
  <div class="app-container">
    <el-form
      :model="queryParams"
      ref="queryForm"
      size="small"
      :inline="true"
      label-width="68px"
    >
    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" label-width="68px">
      <el-form-item label="姓名" prop="name">
        <el-input
          v-model="queryParams.name"
          placeholder="请输入姓名"
          clearable
          @keyup.enter.native="handleQuery"
          style="width: 110px"
        />
        <el-input v-model="queryParams.name" placeholder="请输入姓名" clearable @keyup.enter.native="handleQuery"
          style="width: 110px" />
      </el-form-item>
      <el-form-item label="体检号" prop="tjNumber">
        <el-input
          ref="inputName"
          v-model="queryParams.tjNumber"
          placeholder="请输入体检号"
          clearable
          @keyup.enter.native="handleQuery"
          @blur="hb"
          style="width: 170px"
        />
        <el-input ref="inputName" v-model="queryParams.tjNumber" placeholder="请输入体检号" clearable
          @keyup.enter.native="handleQuery" @blur="hb" style="width: 170px" />
      </el-form-item>
      <el-form-item
        label="单位名称"
        prop="tjCompName"
        style="margin-left: 20px"
      >
        <el-select
          :remote-method="getRemoteData"
          v-model="queryParams.tjCompName"
          value-key="drugManufacturerId"
          style="width: 180px"
          remote
          filterable
          placeholder="请选择单位名称"
          clearable
          @change="searchSelect"
        >
          <el-option
            v-for="dict in CompanyList"
            :key="dict.drugManufacturerId"
            :label="dict.cnName"
            :value="dict"
          />
      <el-form-item label="单位名称" prop="tjCompName" style="margin-left: 20px">
        <el-select :remote-method="getRemoteData" v-model="queryParams.tjCompName" value-key="drugManufacturerId"
          style="width: 180px" remote filterable placeholder="请选择单位名称" clearable @change="searchSelect">
          <el-option v-for="dict in CompanyList" :key="dict.drugManufacturerId" :label="dict.cnName" :value="dict" />
        </el-select>
      </el-form-item>
      <el-form-item label="登记时间" prop="createTimeList">
        <el-date-picker
          v-model="createTimeList"
          type="datetimerange"
          align="right"
          :picker-options="pickerOptions"
          style="width: 310px"
          start-placeholder="开始日期"
          end-placeholder="结束日期"
          :default-time="['00:00:00', '23:00:00']"
          format="yyyy-MM-dd HH:mm"
          value-format="yyyy-MM-dd HH:mm"
          @change="dateChangebirthday1"
        >
        <el-date-picker v-model="createTimeList" type="datetimerange" align="right" :picker-options="pickerOptions"
          style="width: 310px" start-placeholder="开始日期" end-placeholder="结束日期" :default-time="['00:00:00', '23:00:00']"
          format="yyyy-MM-dd HH:mm" value-format="yyyy-MM-dd HH:mm" @change="dateChangebirthday1">
        </el-date-picker>
      </el-form-item>
      <el-form-item>
        <el-button
          type="primary"
          icon="el-icon-search"
          size="mini"
          @click="handleQuery"
          style="margin-right: 15px"
          >查询</el-button
        >
        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
          >重置</el-button
        >
        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"
          style="margin-right: 15px">查询</el-button>
        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
      </el-form-item>
    </el-form>
    <el-radio-group
      v-model="checkStatus"
      @input="radioChange"
      style="margin: 10px 15px"
    >
    <el-radio-group v-model="checkStatus" @input="radioChange" style="margin: 10px 15px">
      <el-radio-button label="0">未审核</el-radio-button>
      <el-radio-button label="1">已审核</el-radio-button>
    </el-radio-group>
    <div style="width: 100%; margin-left: 10px; display: flex">
      <div style="width: 45%">
        <el-table
          id="ta"
          v-loading="loading"
          ref="tb"
          :data="exaList"
          border
          height="520"
          :row-class-name="tableRowClassName"
          highlight-current-row
          @current-change="handleCurrentChange"
        >
        <el-table id="ta" v-loading="loading" ref="tb" :data="exaList" border height="520"
          :row-class-name="tableRowClassName" highlight-current-row @current-change="handleCurrentChange">
          <!-- <el-table-column type="selection" width="40" align="center" /> -->
          <el-table-column
            label="体检号"
            align="center"
            prop="tjNumber"
            min-width="160"
          />
          <el-table-column
            label="姓名"
            align="center"
            prop="cusName"
            min-width="80"
          />
          <el-table-column
            label="性别"
            align="center"
            prop="cusSex"
            min-width="50"
          >
          <el-table-column label="体检号" align="center" prop="tjNumber" min-width="160" />
          <el-table-column label="姓名" align="center" prop="cusName" min-width="80" />
          <el-table-column label="性别" align="center" prop="cusSex" min-width="50">
            <template slot-scope="scope">
              <span v-if="scope.row.cusSex == '0'">男</span>
              <span v-if="scope.row.cusSex == '1'">女</span>
              <span v-if="scope.row.cusSex == '2'">未知</span>
              <span v-if="scope.row.cusSex == '9'">未说明性别</span>
            </template>
            <!-- <template slot-scope="scope"> -->
            <!-- {{scope.row.customer.cusSex}} -->
            <!-- {{ scope.row.cusSex === 0 ? "男" : "女" }} -->
            <!-- <dict-tag :options="dict.type.sys_user_sex" :value="scope.row.cusSex " /> -->
            <!-- </template> -->
          </el-table-column>
          <el-table-column
            label="手机号"
           <el-table-column
            label="年龄"
            align="center"
            prop="cusPhone"
            prop="age"
            min-width="100"
          />
          <el-table-column
            label="登记时间"
            align="center"
            prop="tjTime"
            min-width="120"
          />
          <el-table-column
            v-if="checkStatus == '1'"
            label="审核状态"
            align="center"
            prop="confirmStatus"
            min-width="80"
          >
          <el-table-column label="手机号" align="center" prop="cusPhone" min-width="100" />
          <el-table-column label="登记时间" align="center" prop="tjTime" min-width="120" />
          <el-table-column v-if="checkStatus == '1'" label="审核状态" align="center" prop="confirmStatus" min-width="80">
            <template slot-scope="scope">
              <span
                :style="{
                  color:
                    scope.row.confirmStatus == '301' ? '#0CB618' : '#EA1B29',
                }"
                v-if="scope.row.confirmStatus == '301'"
                >已通过</span
              >
              <span
                :style="{
                  color:
                    scope.row.confirmStatus == '301' ? '#0CB618' : '#EA1B29',
                }"
                v-if="scope.row.confirmStatus == '299'"
                >已驳回</span
              >
              <span :style="{
                color:
                  scope.row.confirmStatus == '301' ? '#0CB618' : '#EA1B29',
              }" v-if="scope.row.confirmStatus == '301'">已通过</span>
              <span :style="{
                color:
                  scope.row.confirmStatus == '301' ? '#0CB618' : '#EA1B29',
              }" v-if="scope.row.confirmStatus == '299'">已驳回</span>
            </template>
          </el-table-column>
          <!--   v-hasPermi="['reservation:reservation:edit']" -->
          <el-table-column label="操作" align="center" min-width="120px">
            <template slot-scope="scope">
              <el-button
                size="mini"
                type="text"
                @click="tongbu(scope.row)"
                disabled
                >同步</el-button
              >
              <el-button size="mini" type="text" @click="tongbu(scope.row)" disabled>同步</el-button>
              <!-- :disabled="dis" -->
              <el-button
                disabled
                size="mini"
                type="text"
                @click="tongguo(scope.row)"
                >通过</el-button
              >
              <el-button disabled size="mini" type="text" @click="tongguo(scope.row)">通过</el-button>
              <el-button
                size="mini"
                type="text"
                disabled
                @click="bohui(scope.row)"
                >驳回</el-button
              >
              <el-button size="mini" type="text" disabled @click="bohui(scope.row)">驳回</el-button>
            </template>
            <!--    v-show="
                  (xianshi == 'Y' || xianshi == 'y') &&
@@ -210,45 +92,15 @@
        </el-table>
      </div>
      <div style="width: 45%; margin-left: 5%">
        <el-table
          v-loading="loading"
          border
          :row-class-name="tableRowClassName"
          height="520"
          ref="tab1"
          :data="xiangmuList"
          highlight-current-row
          @row-click="handleRowClick"
        >
        <el-table v-loading="loading" border :row-class-name="tableRowClassName" height="520" ref="tab1"
          :data="xiangmuList" highlight-current-row @row-click="handleRowClick">
          <!-- <el-table-column type="selection" width="40" align="center" /> -->
          <el-table-column
            label="科室"
            align="center"
            prop="deptName"
            min-width="100"
            :show-overflow-tooltip="true"
          />
          <el-table-column
            label="项目"
            align="center"
            prop="proName"
            min-width="150"
            :show-overflow-tooltip="true"
          />
          <el-table-column
            label="状态"
            align="center"
            prop="type"
            :show-overflow-tooltip="true"
            min-width="100"
          >
          <el-table-column label="科室" align="center" prop="deptName" min-width="100" :show-overflow-tooltip="true" />
          <el-table-column label="项目" align="center" prop="proName" min-width="150" :show-overflow-tooltip="true" />
          <el-table-column label="状态" align="center" prop="type" :show-overflow-tooltip="true" min-width="100">
            <template slot-scope="scope">
              <span
                v-if="scope.row.type == '0'"
                :style="type == 0 ? { color: 'red' } : { color: '#409EFF' }"
              >
                {{ type == 0 ? "未  检" : "在  检" }}
              <span v-if="scope.row.type == '0'" :style="type == 0 ? { color: 'red' } : { color: '#409EFF' }">
                {{ type == 0 ? "未 检" : "在 检" }}
              </span>
              <span v-if="scope.row.type == '1'">已完成</span>
              <span v-if="scope.row.type == '2'">弃检</span>
@@ -281,12 +133,7 @@
            prop="doctorName"
            width="100"
          /> -->
          <el-table-column
            label="检查时间"
            align="center"
            prop="bcupdateTime"
            min-width="160"
          />
          <el-table-column label="检查时间" align="center" prop="bcupdateTime" min-width="160" />
          <!-- <el-table-column
            label="保存医生"
            align="center"
@@ -301,27 +148,11 @@
          /> -->
          <el-table-column label="操作" align="center" min-width="120px">
            <template slot-scope="scope">
              <el-button
                size="mini"
                type="text"
                :disabled="scope.row.type === 1"
                :loading="scope.row.isLoading"
                @click="qijian(scope.row)"
                >{{ scope.row.type === 0 ? "弃检" : "恢复" }}</el-button
              >
              <el-button
                size="mini"
                type="text"
                @click="yijian(scope.row)"
                >已检</el-button
              >
              <el-button
                size="mini"
                type="text"
                :disabled="scope.row.type === 0 || scope.row.type === 2"
                @click="queryResultone(scope.row)"
                >结果</el-button
              >
              <el-button size="mini" type="text" :disabled="scope.row.type === 1" :loading="scope.row.isLoading"
                @click="qijian(scope.row)">{{ scope.row.type === 0 ? "弃检" : "恢复" }}</el-button>
              <el-button size="mini" type="text" @click="yijian(scope.row)" v-if="yijiantype == 'N'">已检</el-button>
              <el-button size="mini" type="text" :disabled="scope.row.type === 0 || scope.row.type === 2"
                @click="queryResultone(scope.row)">结果</el-button>
              <!--  @click="chaxun(scope.row) " -->
            </template>
          </el-table-column>
@@ -335,18 +166,18 @@
      </div>
      <div class="a">
        <div v-if="jyjc == 0">
          <el-table
            :data="jieguoList"
            border
            :row-style="changRed"
            style="width: 100%"
            :header-cell-style="{ background: '#AAD8DF' }"
          >
          <el-table :data="jieguoList" border :row-style="changRed" style="width: 100%"
            :header-cell-style="{ background: '#AAD8DF' }">
            <el-table-column label="检测项目" prop="pro_name">
            </el-table-column>
            <el-table-column label="检测结果" prop="pro_result">
            </el-table-column>
            <el-table-column label="参考范围" prop="ckfw"> </el-table-column>
            <el-table-column label="异常标志" prop="ycbz">
               <template slot-scope="scope">
                {{ scope.row.ycbz == 0 ? "正常" : "异常" }}
               </template>
            </el-table-column>
          </el-table>
        </div>
@@ -355,20 +186,14 @@
          <div class="check-result-container">
            <div class="check-item">
              <div class="check-title">检查所见:</div>
              <div
                class="check-description"
                :style="{ color: isRed ? 'red' : '' }"
              >
              <div class="check-description" :style="{ color: isRed ? 'red' : '' }">
                {{ jieguoList[0].pro_result }}
              </div>
            </div>
            <div class="check-item">
              <div class="check-title">检查结论:</div>
              <div
                class="check-description"
                :style="{ color: isRed ? 'red' : '' }"
              >
              <div class="check-description" :style="{ color: isRed ? 'red' : '' }">
                {{ jieguoList[0].yxzd || "暂无结论" }}
              </div>
            </div>
@@ -382,16 +207,29 @@
        <!-- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :pager-count="5" :current-page.sync="currentPage1" :current-page="page"
                :page-sizes="pageSize" :page-size="size" layout="total, sizes, prev, pager, next, jumper" :total="total">
            </el-pagination> -->
        <pagination
          v-show="total > 0"
          :total="total"
          :pager-count="5"
          :page.sync="queryParams.page"
          :limit.sync="queryParams.pageSize"
          @pagination="submitForm"
        />
        <pagination v-show="total > 0" :total="total" :pager-count="5" :page.sync="queryParams.page"
          :limit.sync="queryParams.pageSize" @pagination="submitForm" />
      </div>
    </div>
    <el-dialog :visible.sync="open" width="980px" append-to-body>
      <el-form ref="form" :model="form" label-width="98px" @submit.native.prevent>
        <el-form-item label="弃检原因" prop="isZybUnit">
          <el-radio-group v-model="form.isZybUnit">
            <el-radio :label="0">自动放弃</el-radio>
            <el-radio :label="1">妊娠</el-radio>
            <el-radio :label="1">怀孕</el-radio>
            <el-radio :label="1">其他</el-radio>
          </el-radio-group>
        </el-form-item>
        <br />
      </el-form>
      <div slot="footer" class="dialog-footer">
        <el-button type="primary" @click="submitFormqijian">确 定</el-button>
        <el-button @click="cancel">取 消</el-button>
      </div>
    </el-dialog>
  </div>
</template>
@@ -419,7 +257,8 @@
      jieguoList: [],
      jyjc: null,
      dis: false,
      isLoading:false,
      isLoading: false,
      open: false,
      createTimeList: "",
      currentRow: null,
      total: 0,
@@ -427,6 +266,7 @@
      selectedTjNumber: "",
      drawer: false,
      type: null,
      yijiantype: null,
      CompanyList: [],
      CheckBox: {},
      // 查询参数
@@ -502,7 +342,7 @@
  },
  methods: {
    changRed({ row }) {
      if (row.ycbz != "" && row.ycbz != null && row.ycbz === "1") {
      if (row.ycbz != "" && row.ycbz != null && row.ycbz === 1) {
        // 变颜色的条件
        return {
          color: "red", // 这个return的就是样式 可以是color 也可以是backgroundColor
@@ -749,6 +589,10 @@
        this.type = res.data;
      });
      getConfigKey("sfyccsyjan").then((res) => {
        this.yijiantype = res.msg;
      });
      cSWebGetPro(tjNumber).then((res) => {
        this.xiangmuList = res.data;
        this.xiangmuList.forEach((item) => {
@@ -783,6 +627,23 @@
        });
      });
    },
    cancel() {
      this.open = false
    },
    submitFormqijian() {
      this.open = false
      qijian(tjNUm, proId).then((res) => {
        if (res.code == 200) {
          cSWebGetPro(tjNUm).then((res) => {
            if (res.code === 200) {
              // 更新右边表格的数据
              this.xiangmuList = res.data;
              this.isLoading = false
            }
          });
        }
      });
    },
    // 弃检按钮
    qijian(row) {
@@ -802,6 +663,7 @@
          }
        });
      } else {
        // this.open = true
        qijian(tjNUm, proId).then((res) => {
          if (res.code == 200) {
            cSWebGetPro(tjNUm).then((res) => {
@@ -928,7 +790,8 @@
.el-table .warning-row {
  background: #e5f3ff !important;
}
::v-deep .el-table__body tr.current-row > td {
::v-deep .el-table__body tr.current-row>td {
  background: #edf2fa !important;
}
@@ -937,6 +800,7 @@
  display: flex;
  justify-content: center;
}
.red-text {
  color: red !important;
}
@@ -948,6 +812,7 @@
.a ::v-deep .el-table__cell {
  padding: 1px 0 !important;
}
.check-result-container {
  // background-color: #fafafa;
  padding: 20px;
@@ -970,13 +835,17 @@
.check-description {
  font-size: 14px;
  color: #555; /* 中灰色文字 */
  line-height: 1.6; /* 行高,增加可读性 */
  padding: 8px 0; /* 上下内边距 */
  color: #555;
  /* 中灰色文字 */
  line-height: 1.6;
  /* 行高,增加可读性 */
  padding: 8px 0;
  /* 上下内边距 */
}
.check-description.no-result {
  color: #bbb; /* 如果没有结论,文字为淡灰色 */
  color: #bbb;
  /* 如果没有结论,文字为淡灰色 */
}
::v-deep .el-table {