WXL
5 天以前 4c9fdc87987140e8b2c3f0dfc2f6608cdb6be774
src/views/business/GetWitness/index.vue
@@ -26,15 +26,19 @@
            @keyup.enter.native="handleQuery"
          />
        </el-form-item>
        <el-form-item label="获取状态" prop="recordstate">
        <el-form-item label="获取状态" prop="witnessState">
          <el-select
            v-model="queryParams.recordstate"
            v-model="queryParams.witnessState"
            placeholder="请选择获取状态"
            clearable
            style="width: 200px"
          >
            <el-option label="已获取" value="1" />
            <el-option label="待获取" value="0" />
          <el-option
            v-for="dict in dict.type.Obtain_status"
            :key="dict.value"
            :label="dict.label"
            :value="dict.value"
          />
          </el-select>
        </el-form-item>
        <el-form-item>
@@ -84,7 +88,7 @@
          width="120"
        />
        <el-table-column
          label="捐献者姓名"
          label="姓名"
          align="center"
          prop="name"
          width="120"
@@ -99,24 +103,49 @@
        </el-table-column>
        <el-table-column label="年龄" align="center" prop="age" width="80" />
        <el-table-column
          label="血型"
          align="center"
          prop="bloodtype"
          width="80"
        >
          <template slot-scope="scope">
            <dict-tag
              :options="dict.type.sys_BloodType"
              :value="scope.row.bloodtype"
            />
          </template>
        </el-table-column>
        <el-table-column
          label="疾病诊断"
          align="center"
          prop="diagnosisname"
          min-width="180"
          width="200"
          show-overflow-tooltip
        />
        <el-table-column
          label="捐献类型"
          align="center"
          prop="donationcategory"
          width="180"
        >
          <template slot-scope="scope">
            <dict-tag
              :options="dict.type.sys_DonationCategory"
              :value="scope.row.donationcategory"
            />
          </template>
        </el-table-column>
        <el-table-column
          label="获取状态"
          align="center"
          prop="recordstate"
          prop="witnessState"
          width="100"
        >
          <template slot-scope="scope">
            <el-tag
              :type="scope.row.recordstate === '1' ? 'success' : 'warning'"
            >
              {{ scope.row.recordstate === "1" ? "已获取" : "待获取" }}
            </el-tag>
              <dict-tag
              :options="dict.type.Obtain_status"
              :value="scope.row.witnessState"
            />
          </template>
        </el-table-column>
        <el-table-column
@@ -145,10 +174,10 @@
          prop="responsibleusername"
          width="100"
        />
        <el-table-column
         <el-table-column
          label="操作"
          align="center"
          width="210"
          min-width="180"
          fixed="right"
          class-name="small-padding fixed-width"
        >
@@ -157,15 +186,15 @@
              size="mini"
              type="text"
              icon="el-icon-view"
              @click="handleView(scope.row)"
              >详情</el-button
              @click.stop="handleView(scope.row)"
              >查看</el-button
            >
            <el-button
              size="mini"
              type="text"
              icon="el-icon-edit"
              @click="handleUpdate(scope.row)"
              >修改</el-button
              @click.stop="handleUpdate(scope.row)"
              >编辑</el-button
            >
          </template>
        </el-table-column>
@@ -191,7 +220,7 @@
export default {
  name: "OrganProcurementList",
  components: { Pagination },
  dicts: ["sys_user_sex"],
  dicts: ["sys_user_sex", "Obtain_status", "sys_BloodType", "sys_DonationCategory"],
  data() {
    return {
      // 遮罩层
@@ -212,7 +241,7 @@
        pageSize: 10,
        inpatientno: undefined,
        name: undefined,
        recordstate: undefined
        witnessState: undefined
      }
    };
  },
@@ -259,18 +288,19 @@
    handleView(row) {
      this.$router.push({
        path: "/case/GetWitnessInfo",
        query: { id: row.id, infoid: row.infoid }
        query: { id: row.id, infoid: row.infoid, mode: "view" }
      });
    },
    // 新增按钮操作
    handleCreate() {
      this.$router.push("/case/GetWitnessInfo");
    },
    // 修改按钮操作
    // 编辑
    handleUpdate(row) {
      const id = row.id || this.ids[0];
      this.$router.push({
        path: "/case/GetWitnessInfo",
        query: { id: row.id, infoid: row.infoid }
        query: { id: id, infoid: row.infoid, mode: "edit" }
      });
    },
    // 时间格式化