11
WXL
2024-03-14 70e2bdb8631bfb7ec6c24ced81a236ff3197c937
src/views/project/medicalevaluation/index.vue
@@ -51,13 +51,13 @@
        <el-col :span="6">
          <el-form-item label="捐献进度" prop="recordstate">
            <el-select
              v-model="queryParams.recordstate"
              v-model="queryParams.workflow"
              placeholder="请选择捐献进度"
              clearable
              size="small"
            >
              <el-option
                v-for="dict in dict.type.sys_DonationStatus"
                v-for="dict in dict.type.sys_donornode"
                :key="dict.value"
                :label="dict.label"
                :value="dict.value"
@@ -200,10 +200,13 @@
        width="120"
      >
        <template slot-scope="scope">
          <dict-tag
            :options="dict.type.sys_DonationStatus"
            :value="scope.row.recordstate"
          />
          <div v-if="!scope.row.terminationCase">
            <dict-tag
            :options="dict.type.sys_donornode"
              :value="scope.row.workflow"
            />
          </div>
          <div v-else>任务中止</div>
        </template>
      </el-table-column>
@@ -628,7 +631,8 @@
    "sys_organstate",
    "sys_CoreAssessConclusion",
    "sys_BaseAssessConclusion",
    "sys_OrganDecision"
    "sys_OrganDecision",
    'sys_donornode'
  ],
  data() {
    //这里存放数据
@@ -1015,53 +1019,61 @@
    /** 新增按钮操作 */
    handleAdd(data) {
      console.log("datadata", data);
      this.$router.push({
        path: "/organ/donationdetails/",
        query: {
          id: data.id,
          organType: "edit"
        }
      });
      // if(data.recordstate != 2 && data.recordstate != 4  && data.recordstate != 5 && data.recordstate != 13){
      //   this.$modal.msgError("当前捐献案例不能进行医学捐献评估");
      //   return
      // }
      this.flowname = "捐献医学评估";
      this.annexno = "";
      this.reset();
      //this.curCase = data;
      this.curCase = {
        id: data.id,
        recordstate: null,
        donorno: data.donorno
      };
      //获取医学捐献评估记录
      this.loading = true;
      if (data.meid) {
        let searchParam = {
          id: data.meid
        };
        //listDonatebaseinfo(searchParam).then((response) => {
        listMedicalevaluation(searchParam).then(response => {
          if (response.code == 200 && response.rows.length == 1) {
            this.title = "修改捐献医学评估";
            this.form = response.rows[0];
            this.form.infoid = data.id;
            this.open = true;
            this.$nextTick(function() {
              this.$refs.evaluationannex.getAnnexList();
            });
          } else {
            this.$modal.msgError(
              "获取医学评估记录失败:" + JSON.stringify(response)
            );
          }
        });
      } else {
        this.title = "新增捐献医学评估";
        this.form.infoid = data.id;
        this.form.donorno = data.donorno;
      // this.flowname = "捐献医学评估";
      // this.annexno = "";
      // this.reset();
      // //this.curCase = data;
      // this.curCase = {
      //   id: data.id,
      //   recordstate: null,
      //   donorno: data.donorno
      // };
      // //获取医学捐献评估记录
      // this.loading = true;
      // if (data.meid) {
      //   let searchParam = {
      //     id: data.meid
      //   };
      //   //listDonatebaseinfo(searchParam).then((response) => {
      //   listMedicalevaluation(searchParam).then(response => {
      //     if (response.code == 200 && response.rows.length == 1) {
      //       this.title = "修改捐献医学评估";
      //       this.form = response.rows[0];
      //       this.form.infoid = data.id;
      //       this.open = true;
      //       this.$nextTick(function() {
      //         this.$refs.evaluationannex.getAnnexList();
      //       });
      //     } else {
      //       this.$modal.msgError(
      //         "获取医学评估记录失败:" + JSON.stringify(response)
      //       );
      //     }
      //   });
      // } else {
      //   this.title = "新增捐献医学评估";
      //   this.form.infoid = data.id;
      //   this.form.donorno = data.donorno;
        this.open = true;
        this.$nextTick(function() {
          this.$refs.evaluationannex.getAnnexList();
        });
      }
      this.loading = false;
      //   this.open = true;
      //   this.$nextTick(function() {
      //     this.$refs.evaluationannex.getAnnexList();
      //   });
      // }
      // this.loading = false;
    },
    /** 提交按钮 */
    submitForm() {