WXL
2024-06-20 8d2e62da290ba8c40101f282a60efcdb29b22cd2
src/views/knowledge/questionnaire/compilequer/index.vue
@@ -39,6 +39,8 @@
          label-width="100px"
          class="demo-ruleForm"
        >
          <el-row :gutter="10">
            <el-col :span="10">
          <el-form-item label="问卷分类" prop="region">
            <el-select
              v-model="ruleForm.categoryid"
@@ -61,6 +63,24 @@
              </el-option-group>
            </el-select>
          </el-form-item>
            </el-col>
            <el-col :span="10">
              <el-form-item label="评价类型">
                <el-select
                  v-model="ruleForm.scoreType"
                  placeholder="请选择分类"
                >
                  <el-option
                    v-for="group in appraiselist"
                    :key="group.value"
                    :label="group.label"
                    :value="group.value"
                  >
                  </el-option>
                </el-select>
              </el-form-item>
            </el-col>
          </el-row>
          <el-form-item label="问卷标题" prop="name">
            <div style="width: 30%">
              <el-input v-model="ruleForm.svyname"></el-input>
@@ -393,7 +413,7 @@
                <div class="headline">选项设置</div>
                <div
                  class="topicxq"
                  v-for="item in topicobj.svyLibTemplateTargetoptions"
                  v-for="item in topicobj.svyLibScriptOptions"
                >
                  <el-row :gutter="10">
                    <el-col :span="11"
@@ -657,6 +677,11 @@
        { value: "topic", table: "topic" },
        { value: "topic", table: "topic" },
      ],
      appraiselist: [
        { label: "分数", value: "1" },
        { label: "ABC等级", value: "2" },
        { label: "优良等级", value: "3" },
      ],
      fileList: [
        {
@@ -799,11 +824,9 @@
      this.ruleForm.svyLibScripts = this.ruleForm.svyLibScripts.concat(
        this.delScriptVOList
      );
      console.log(this.ruleForm.svyLibScripts, "this.ruleForm.svyLibScripts");
      const result = this.tempDetpRelevanceslist.map(
        (subArr) => subArr[subArr.length - 1]
      );
      console.log(result, "result");
      // id数组查数组对象
      result.forEach((item) => {
        const condition = this.ruleForm.tempDetpRelevances.some(
@@ -817,7 +840,6 @@
          });
        }
      });
      console.log(this.ruleForm.tempDetpRelevances);
      // 数组对象查id数组
      this.ruleForm.tempDetpRelevances.forEach((item) => {
        const condition = result.some((obj) => obj === item.deptId);
@@ -827,7 +849,6 @@
          this.ruleForm.tempDetpRelevances[index].delFlag = 1;
        }
      });
      console.log(this.ruleForm.tempDetpRelevances);
      setTimeout(() => {
        this.submitForm();
      }, 1000);
@@ -872,10 +893,11 @@
    // 新增题目
    addtopic(row) {
      row.isoperation = 1;
      row.svyLibTemplateTargetoptions.forEach((item) => {
      row.svyLibScriptOptions.forEach((item) => {
        item.isoperation = 1;
      });
      this.ruleForm.svyLibScripts.push(row);
      this.$modal.msgSuccess("新增成功");
    },
    handleDelete(row) {
      let index = this.ruleForm.svyLibScripts.indexOf(row);
@@ -917,9 +939,7 @@
    },
    // 修改题目信息
    Submittopicobj() {
    },
    Submittopicobj() {},
    // 新增变量
    addvariable() {
      this.variablelist.push({