wx
qx
2025-04-15 7a2d49aeff16e1122ed33ebb858f093a379fb960
src/views/doctor/pacsCheck/index.vue
@@ -6,6 +6,7 @@
      size="small"
      :inline="true"
      label-width="68px"
      @submit.native.prevent
    >
      <el-form-item label="体检号" prop="reportDoctorCode">
        <el-input
@@ -15,6 +16,7 @@
          clearable
          @keyup.enter.native="handleQuery"
          style="width: 170px"
          @input="onInput"
        />
      </el-form-item>
      <!--  <el-form-item label="姓名" prop="name">
@@ -88,7 +90,7 @@
      :data="exaLists"
      v-loading="loading"
      border
      max-height="350"
      height="350"
      @current-change="handleCurrentChange"
      @selection-change="handleSelectionChange"
      :row-class-name="tableRowClassName"
@@ -125,11 +127,13 @@
        prop="checkParts"
        width="150px"
      />
      <!--   :formatter="formatDate" -->
      <el-table-column
        label="报告时间"
        align="center"
        prop="examinationDate"
        width="150px"
        width="153px"
      />
      <el-table-column label="门诊号" align="center" prop="mzh" width="140px" />
@@ -253,6 +257,7 @@
  
  <script>
import { getLeftList, getRightList, asyncPacs } from "@/api/doctor/pacsCheck";
import moment from "moment";
export default {
  dicts: ["dict_tj_status"],
@@ -328,6 +333,9 @@
    });
  },
  methods: {
    onInput(val) {
      this.inputVal = val.replace(/\s+/g, ""); // 清除所有空格
    },
    handleDateChange(val) {
      if (val && val.length === 2) {
        this.queryParams.start = val[0]; // 设置开始时间
@@ -344,6 +352,17 @@
    tableRowClassName({ row }) {
      return !row.mzh ? "row-disabled" : "";
    },
    formatDate(row) {
      if (!row.examinationDate) return "";
      // 使用 moment 解析指定格式的日期字符串
      const date = moment(row.examinationDate, "MM DD YYYY hh:mmA");
      if (!date.isValid()) return "无效日期";
      // 格式化为所需格式
      return date.format("YYYY-MM-DD HH:mm");
    },
    handleSelectionChange(val) {
      console.log(val);