gaoluyang
2025-03-13 ee6ea1e6886d9432dc31d42158786a6b06027760
src/views/CNAS/process/method/standardMethod/index.vue
@@ -194,12 +194,7 @@
              name: "编辑",
              type: "text",
              clickFun: (row) => {
                this.title = "编辑";
                this.addForm = row;
                this.addForm.structureTestObjectId = JSON.parse(
                  this.addForm.structureTestObjectId
                );
                this.addDlog = true;
                this.openEdit(row)
              },
            },
            {
@@ -276,34 +271,18 @@
      this.queryParams = {};
      this.getList();
    },
    // 权限分配
    getPower() {
      let power = JSON.parse(sessionStorage.getItem("power"));
      let up = false;
      let del = false;
      let add = false;
      let inPower = false;
      for (var i = 0; i < power.length; i++) {
        if (power[i].menuMethod == "addStandardMethod") {
          add = true;
        }
        if (power[i].menuMethod == "delStandardMethod") {
          del = true;
        }
        if (power[i].menuMethod == "upStandardMethod") {
          up = true;
        }
        if (power[i].menuMethod == "importStandardDetails") {
          inPower = true;
        }
      }
      this.addPower = add;
      this.inPower = inPower;
    },
    openAdd() {
      this.title = "新增";
      this.addForm = {};
      this.addDlog = true;
    },
    openEdit(row) {
      this.title = "编辑";
      this.addDlog = true;
      this.addForm = this.HaveJson(row)
      this.addForm.structureTestObjectId = JSON.parse(
        this.addForm.structureTestObjectId
      );
    },
    getQualificationList() {
      this.getDicts("cnas_method_qualification").then((response) => {
@@ -377,6 +356,7 @@
        }
      });
    },
    // 删除
    handleDelete(row) {
      this.$confirm("是否删除该条数据?", "提示", {
        confirmButtonText: "确定",
@@ -385,7 +365,6 @@
      })
        .then(() => {
          delStandardMethod({ id: row.id }).then((res) => {
            if (res.code == 201) return;
            this.$message.success("删除成功");
            this.getList();
          });