WXL
3 天以前 dc082351978a1e9f75d7a1471a0ca7ebeac552a5
src/views/business/transfer/index.vue
@@ -217,34 +217,49 @@
      >
        <template slot-scope="scope">
          <el-button
            size="mini"
            type="text"
            icon="el-icon-view"
            size="small"
            type="primary"
            @click="handleDetail(scope.row)"
            >详情</el-button
          >
          <el-button
            size="mini"
            type="text"
            icon="el-icon-edit"
            size="small"
            type="primary"
            style="margin-bottom: 10px;"
            plain
            @click="handleUpdate(scope.row)"
            >编辑</el-button
          >
          <el-button
            size="mini"
            type="text"
            icon="el-icon-video-play"
            size="small"
            type="primary"
            plain
            @click="handleStartTransport(scope.row)"
            v-if="scope.row.transitStatus === 1"
            >开始转运</el-button
          >
          <el-button
            size="mini"
            type="text"
            icon="el-icon-check"
            size="small"
            type="success"
            plain
            @click="handleCompleteTransport(scope.row)"
            v-if="scope.row.transitStatus === 2"
            >完成转运</el-button
          ><el-button
            size="small"
            type="danger"
            plain
            @click="cancelTransport(scope.row)"
            v-if="scope.row.transitStatus === 2"
            >取消转运</el-button
          >
          <el-button
            size="small"
            type="warning"
            plain
            @click="recoverTransport(scope.row)"
            v-if="scope.row.transitStatus === 4"
            >恢复转运</el-button
          >
        </template>
      </el-table-column>
@@ -664,6 +679,8 @@
        // 其他字段可以根据需要从案例中获取
        transportStartPlace: caseData.treatmenthospitalname || "",
        contactPerson: caseData.coordinatorName || "",
        icuDoctor: caseData.icuDoctor,
        icuDoctorPhone: caseData.icuDoctorPhone,
        transitStatus: 1, // 默认待转运
        // 清空其他字段
        id: undefined,
@@ -793,6 +810,18 @@
      this.actionTitle = "完成转运";
      this.actionText = "完成";
      this.actionOpen = true;
    } /** 完成转运操作 */,
    async cancelTransport(row) {
      this.currentTransport = row;
      this.actionTitle = "取消转运";
      this.actionText = "取消";
      this.actionOpen = true;
    } /** 完成转运操作 */,
    async recoverTransport(row) {
      this.currentTransport = row;
      this.actionTitle = "恢复转运";
      this.actionText = "恢复";
      this.actionOpen = true;
    },
    /** 确认操作 */
@@ -806,8 +835,14 @@
          requestData.transitStatus = 2; // 设置为转运中
        } else if (this.actionText === "完成") {
          requestData.transitStatus = 3; // 设置为转运完成
        } else if (this.actionText === "取消") {
          requestData.transitStatus = 4; // 设置为转运取消
        } else if (this.actionText === "恢复") {
          requestData.transitStatus = 2; // 设置为转运中
        }
        requestData.annexfilesList.forEach(item => {
          item.id = null;
        });
        const response = await transportEdit(requestData);
        if (response.code == 200) {