xiatian vor 3 Jahren
Ursprung
Commit
af11e90e03

+ 3 - 4
src/modules/questions/styles/EditPaper.css

@@ -48,7 +48,6 @@ span > p {
   font-size: 16px;
   font-family: "微软雅黑", serif;
   text-align: left;
-  padding-left: 10px;
   position: relative;
   display: flex;
   border-top: 1px dotted;
@@ -74,9 +73,6 @@ span > p {
   border: solid 1px #fff;
   flex: 1;
 }
-.quesSelect:hover {
-  /* border: solid 1px #99a9bf; */
-}
 .text-left {
   margin-left: 3.5%;
   text-align: left;
@@ -243,3 +239,6 @@ textarea {
   font-size: 12px;
   text-align: center;
 }
+.duplicate {
+  background-color: bisque;
+}

+ 31 - 45
src/modules/questions/views/CheckDuplicateInfo.vue

@@ -86,25 +86,30 @@ export default {
         });
     } else if ("paper" == this.from) {
       this.basePaperId = this.$route.params.basePaperId;
-      this.$http
-        .post(
-          QUESTION_API + "/question/duplicate/next",
-          new URLSearchParams({
-            ignoreIds: this.ignoreIds,
-            basePaperId: this.basePaperId,
-          })
-        )
-        .then((response) => {
-          if (response.data) {
-            this.curQuestionId = response.data;
-            this.queryData();
-          } else {
-            this.$notify({
-              message: "没有需要处理的数据",
-              type: "success",
-            });
-          }
-        });
+      if (this.$route.params.quesId) {
+        this.curQuestionId = this.$route.params.quesId;
+        this.queryData();
+      } else {
+        this.$http
+          .post(
+            QUESTION_API + "/question/duplicate/next",
+            new URLSearchParams({
+              ignoreIds: this.ignoreIds,
+              basePaperId: this.basePaperId,
+            })
+          )
+          .then((response) => {
+            if (response.data) {
+              this.curQuestionId = response.data;
+              this.queryData();
+            } else {
+              this.$notify({
+                message: "没有需要处理的数据",
+                type: "success",
+              });
+            }
+          });
+      }
     }
   },
   methods: {
@@ -126,6 +131,7 @@ export default {
               message: "当前已是最后一个",
               type: "success",
             });
+            this.back();
           }
         });
     },
@@ -137,32 +143,12 @@ export default {
         return;
       }
       this.ignoreIds.push(this.curQuestionId);
-      this.$http
-        .post(
-          QUESTION_API + "/question/duplicate/next",
-          new URLSearchParams({
-            ignoreIds: this.ignoreIds,
-            basePaperId: this.basePaperId,
-          })
-        )
-        .then((response) => {
-          if (response.data) {
-            this.curQuestionId = response.data;
-            this.queryData();
-          } else {
-            this.$notify({
-              message: "当前已是最后一个",
-              type: "success",
-            });
-          }
-        });
+      this.next();
     },
     back() {
-      if (this.from == "question" || this.from == "list") {
-        this.$router.push({
-          path: "/questions/check_duplicate_list/0",
-        });
-      }
+      this.$router.push({
+        path: "/questions/check_duplicate_list/0",
+      });
     },
     deleteQues() {
       this.$confirm("确认删除吗?", "提示", {
@@ -184,7 +170,7 @@ export default {
               this.$router.push({
                 path: "/questions/check_duplicate_list/0",
               });
-            } else if (this.from == "list") {
+            } else if (this.from == "list" || this.from == "paper") {
               this.next();
             }
           });
@@ -207,7 +193,7 @@ export default {
             this.$router.push({
               path: "/questions/check_duplicate_list/0",
             });
-          } else if (this.from == "list") {
+          } else if (this.from == "list" || this.from == "paper") {
             this.next();
           }
         });

+ 61 - 100
src/modules/questions/views/EditPaper.vue

@@ -67,6 +67,16 @@
             </el-dropdown-menu>
           </el-dropdown>
         </div>
+        <div v-if="showCheckDuplicateBtn" class="paper-top-right-div">
+          <el-button
+            style="margin-left: 10px"
+            type="primary"
+            size="small"
+            @click="checkDuplicate"
+          >
+            进入查重
+          </el-button>
+        </div>
         <div class="paper-top-right-div">
           <el-button
             style="margin-left: 10px"
@@ -235,17 +245,13 @@
             v-for="(paperDetailUnit, unitIndex) in paperDetail.paperDetailUnits"
             v-show="quesShow(paperDetailUnit.id)"
             :key="unitIndex"
-            class="ques"
+            :class="{
+              ques: true,
+              duplicate:
+                paperDetailUnit.question.checkDuplicateStatus ==
+                'TO_BE_DISPOSE',
+            }"
           >
-            <reduplicate_mark
-              :id="paperDetailUnit.id"
-              :show="reduplicateMarkShow(paperDetailUnit.id)"
-              :fill-color="reduplicateMarkColor(paperDetailUnit.id)"
-              :checked="reduplicateMarkCheck(paperDetailUnit.id)"
-              @reduplicate_mark_check="reduplicate_mark_check"
-            >
-            </reduplicate_mark>
-
             <div
               class="quesSelect"
               @mouseover="quesMouseOver(paperDetailUnit.id)"
@@ -253,6 +259,15 @@
             >
               <div :id="paperDetailUnit.id" class="btnDiv">
                 <span>{{ paperDetailUnit.question.bodyLengthText }}</span>
+                <el-button
+                  v-if="
+                    paperDetailUnit.question.checkDuplicateStatus ==
+                    'TO_BE_DISPOSE'
+                  "
+                  size="small"
+                  @click="checkDuplicateQuestion(paperDetailUnit.question.id)"
+                  >进入查重
+                </el-button>
                 <el-button
                   size="small"
                   @click="editQues(paperDetailUnit, paperDetailUnit.question)"
@@ -374,10 +389,6 @@
                 :key="subIndex"
                 class="subQues"
               >
-                <reduplicate_mark
-                  :show="reduplicateMarkShow(subQuestion.id)"
-                ></reduplicate_mark>
-
                 <div
                   class="quesSelect"
                   @mouseover="
@@ -1072,8 +1083,6 @@
 import { QUESTION_API } from "@/constants/constants";
 import { isEmptyStr, QUESTION_TYPES } from "../constants/constants";
 import { mapState } from "vuex";
-import reduplicate_mark from "../component/reduplicate_mark.vue";
-import randomColor from "randomcolor";
 import ckeditor from "../component/ckeditor.vue";
 import PaperBasicComposition from "./PaperBasicComposition.vue";
 import PaperQuestionType from "./PaperQuestionType.vue";
@@ -1083,7 +1092,6 @@ import AuditInfo from "./AuditInfo.vue";
 export default {
   name: "EditPaperApp",
   components: {
-    reduplicate_mark,
     ckeditor,
     PaperBasicComposition,
     PaperQuestionType,
@@ -1092,6 +1100,7 @@ export default {
   },
   data() {
     return {
+      showCheckDuplicateBtn: false,
       auditInfoDialog: false,
       blueDialog: false,
       typeDialog: false,
@@ -1243,6 +1252,40 @@ export default {
     };
   },
   methods: {
+    showCheckDuplicate() {
+      if (this.paper.checkDuplicateStatus == "DISPOSED") {
+        this.showCheckDuplicateBtn = false;
+      } else {
+        for (let paperDetilData of this.paper.paperDetails) {
+          for (let unit of paperDetilData.paperDetailUnits) {
+            if (unit.question.checkDuplicateStatus == "TO_BE_DISPOSE") {
+              this.showCheckDuplicateBtn = true;
+              return;
+            }
+          }
+        }
+        this.showCheckDuplicateBtn = false;
+      }
+    },
+    checkDuplicate() {
+      this.$router.push({
+        name: "check_duplicate_info",
+        params: {
+          basePaperId: this.paper.id,
+          from: "paper",
+        },
+      });
+    },
+    checkDuplicateQuestion(questionId) {
+      this.$router.push({
+        name: "check_duplicate_info",
+        params: {
+          quesId: questionId,
+          basePaperId: this.paper.id,
+          from: "paper",
+        },
+      });
+    },
     showAuditDialog() {
       this.auditInfoDialog = true;
     },
@@ -1650,6 +1693,7 @@ export default {
               dindx++;
             }
           }
+          this.showCheckDuplicate();
           setTimeout(() => {
             document.documentElement.scrollTop = document.body.scrollTop =
               scrollPosition;
@@ -1722,78 +1766,6 @@ export default {
       }
       return false;
     },
-    reduplicateMarkShow(id) {
-      var found = false;
-      for (var i = 0, imax = this.reduplicateQuestions.length; i < imax; i++) {
-        for (
-          var j = 0, jmax = this.reduplicateQuestions[i].length;
-          j < jmax;
-          j++
-        ) {
-          if (this.reduplicateQuestions[i][j] == id) {
-            found = true;
-            break;
-          }
-        }
-        if (found) {
-          break;
-        }
-      }
-      return found;
-    },
-    reduplicateMarkColor(id) {
-      for (var i = 0, imax = this.reduplicateQuestions.length; i < imax; i++) {
-        for (
-          var j = 0, jmax = this.reduplicateQuestions[i].length;
-          j < jmax;
-          j++
-        ) {
-          if (this.reduplicateQuestions[i][j] == id) {
-            return this.reduplicateQuesColor[i];
-          }
-        }
-      }
-    },
-    reduplicateMarkCheck(id) {
-      for (var i = 0, imax = this.reduplicateGroup.length; i < imax; i++) {
-        if (id == this.reduplicateGroup[i]) {
-          return true;
-        }
-      }
-      return false;
-    },
-    reduplicate_mark_check(id, checked) {
-      console.log(checked);
-      console.log(this.reduplicateQuestions);
-      console.log(id);
-      if (!checked) {
-        for (
-          var i = 0, imax = this.reduplicateQuestions.length;
-          i < imax;
-          i++
-        ) {
-          for (
-            var j = 0, jmax = this.reduplicateQuestions[i].length;
-            j < jmax;
-            j++
-          ) {
-            if (this.reduplicateQuestions[i][j] == id) {
-              this.reduplicateGroup = [];
-              for (
-                var k = 0, kmax = this.reduplicateQuestions[i].length;
-                k < kmax;
-                k++
-              ) {
-                this.reduplicateGroup.push(this.reduplicateQuestions[i][k]);
-              }
-              return;
-            }
-          }
-        }
-      } else {
-        this.reduplicateGroup = [];
-      }
-    },
     //编辑题目
     editQues(paperDetailUnit, question) {
       console.log("question:", question);
@@ -2308,17 +2280,6 @@ export default {
           token
       );
     },
-    initReduplicateQuesColor() {
-      var colorCount = this.reduplicateQuestions.length;
-      if (colorCount > 20) {
-        this.reduplicateQuesColor = randomColor({
-          luminosity: "bright",
-          count: colorCount,
-        });
-      } else {
-        this.reduplicateQuesColor = this.defaultColor;
-      }
-    },
     getSubQuesEditId(paperDetailUnit, subQuestion) {
       return paperDetailUnit.question.id + "_" + subQuestion.subNumber;
     },

+ 61 - 125
src/modules/questions/views/EditPaperPendingTrial.vue

@@ -46,15 +46,6 @@
               更多 <i class="el-icon-arrow-down el-icon--right"></i>
             </el-button>
             <el-dropdown-menu slot="dropdown">
-              <el-dropdown-item>
-                <el-button
-                  type="primary"
-                  :loading="duplicateLoading"
-                  size="small"
-                  @click="getreduplicateQuestions"
-                  ><i class="el-icon-zoom-in"></i>查重
-                </el-button>
-              </el-dropdown-item>
               <el-dropdown-item>
                 <el-button type="primary" size="small" @click="openDialog"
                   ><i class="el-icon-upload2"></i>上传音频
@@ -76,6 +67,16 @@
             </el-dropdown-menu>
           </el-dropdown>
         </div>
+        <div v-if="showCheckDuplicateBtn" class="paper-top-right-div">
+          <el-button
+            style="margin-left: 10px"
+            type="primary"
+            size="small"
+            @click="checkDuplicate"
+          >
+            进入查重
+          </el-button>
+        </div>
         <div class="paper-top-right-div">
           <el-button
             v-show="isShowEditBtn()"
@@ -282,17 +283,13 @@
             v-for="(paperDetailUnit, unitIndex) in paperDetail.paperDetailUnits"
             v-show="quesShow(paperDetailUnit.id)"
             :key="unitIndex"
-            class="ques"
+            :class="{
+              ques: true,
+              duplicate:
+                paperDetailUnit.question.checkDuplicateStatus ==
+                'TO_BE_DISPOSE',
+            }"
           >
-            <reduplicate_mark
-              :id="paperDetailUnit.id"
-              :show="reduplicateMarkShow(paperDetailUnit.id)"
-              :fill-color="reduplicateMarkColor(paperDetailUnit.id)"
-              :checked="reduplicateMarkCheck(paperDetailUnit.id)"
-              @reduplicate_mark_check="reduplicate_mark_check"
-            >
-            </reduplicate_mark>
-
             <div
               class="quesSelect"
               @mouseover="quesMouseOver(paperDetailUnit.id)"
@@ -300,6 +297,15 @@
             >
               <div :id="paperDetailUnit.id" class="btnDiv">
                 <span>{{ paperDetailUnit.question.bodyLengthText }}</span>
+                <el-button
+                  v-if="
+                    paperDetailUnit.question.checkDuplicateStatus ==
+                    'TO_BE_DISPOSE'
+                  "
+                  size="small"
+                  @click="checkDuplicateQuestion(paperDetailUnit.question.id)"
+                  >进入查重
+                </el-button>
                 <span v-show="isShowEditBtn()">
                   <el-button
                     size="small"
@@ -422,10 +428,6 @@
                 :key="subIndex"
                 class="subQues"
               >
-                <reduplicate_mark
-                  :show="reduplicateMarkShow(subQuestion.id)"
-                ></reduplicate_mark>
-
                 <div
                   class="quesSelect"
                   @mouseover="
@@ -1129,8 +1131,6 @@
 import { QUESTION_API } from "@/constants/constants";
 import { isEmptyStr, QUESTION_TYPES } from "../constants/constants";
 import { mapState } from "vuex";
-import reduplicate_mark from "../component/reduplicate_mark.vue";
-import randomColor from "randomcolor";
 import ckeditor from "../component/ckeditor.vue";
 import PaperBasicComposition from "./PaperBasicComposition.vue";
 import PaperQuestionType from "./PaperQuestionType.vue";
@@ -1141,7 +1141,6 @@ import AuditPaper from "./AuditPaper.vue";
 export default {
   name: "EditPaperApp",
   components: {
-    reduplicate_mark,
     ckeditor,
     PaperBasicComposition,
     PaperQuestionType,
@@ -1151,6 +1150,7 @@ export default {
   },
   data() {
     return {
+      showCheckDuplicateBtn: false,
       selectedPaperIds: [],
       auditPaperDialog: false,
       auditResult: "",
@@ -1298,7 +1298,6 @@ export default {
     this.paperId = this.$route.params.id;
     this.parentView = this.$route.params.parentView;
     this.initPaper();
-    this.getreduplicateQuestions();
     this.uploadAction = QUESTION_API + "/uploadRadio/" + this.paperId;
     this.uploadHeaders = {
       key: this.user.key,
@@ -1306,6 +1305,40 @@ export default {
     };
   },
   methods: {
+    showCheckDuplicate() {
+      if (this.paper.checkDuplicateStatus == "DISPOSED") {
+        this.showCheckDuplicateBtn = false;
+      } else {
+        for (let paperDetilData of this.paper.paperDetails) {
+          for (let unit of paperDetilData.paperDetailUnits) {
+            if (unit.question.checkDuplicateStatus == "TO_BE_DISPOSE") {
+              this.showCheckDuplicateBtn = true;
+              return;
+            }
+          }
+        }
+        this.showCheckDuplicateBtn = false;
+      }
+    },
+    checkDuplicate() {
+      this.$router.push({
+        name: "check_duplicate_info",
+        params: {
+          basePaperId: this.paper.id,
+          from: "paper",
+        },
+      });
+    },
+    checkDuplicateQuestion(questionId) {
+      this.$router.push({
+        name: "check_duplicate_info",
+        params: {
+          quesId: questionId,
+          basePaperId: this.paper.id,
+          from: "paper",
+        },
+      });
+    },
     isShowEditBtn() {
       if (
         this.paper.creationBy == this.user.userId &&
@@ -1765,6 +1798,7 @@ export default {
               dindx++;
             }
           }
+          this.showCheckDuplicate();
           setTimeout(() => {
             document.documentElement.scrollTop = document.body.scrollTop =
               scrollPosition;
@@ -1837,78 +1871,6 @@ export default {
       }
       return false;
     },
-    reduplicateMarkShow(id) {
-      var found = false;
-      for (var i = 0, imax = this.reduplicateQuestions.length; i < imax; i++) {
-        for (
-          var j = 0, jmax = this.reduplicateQuestions[i].length;
-          j < jmax;
-          j++
-        ) {
-          if (this.reduplicateQuestions[i][j] == id) {
-            found = true;
-            break;
-          }
-        }
-        if (found) {
-          break;
-        }
-      }
-      return found;
-    },
-    reduplicateMarkColor(id) {
-      for (var i = 0, imax = this.reduplicateQuestions.length; i < imax; i++) {
-        for (
-          var j = 0, jmax = this.reduplicateQuestions[i].length;
-          j < jmax;
-          j++
-        ) {
-          if (this.reduplicateQuestions[i][j] == id) {
-            return this.reduplicateQuesColor[i];
-          }
-        }
-      }
-    },
-    reduplicateMarkCheck(id) {
-      for (var i = 0, imax = this.reduplicateGroup.length; i < imax; i++) {
-        if (id == this.reduplicateGroup[i]) {
-          return true;
-        }
-      }
-      return false;
-    },
-    reduplicate_mark_check(id, checked) {
-      console.log(checked);
-      console.log(this.reduplicateQuestions);
-      console.log(id);
-      if (!checked) {
-        for (
-          var i = 0, imax = this.reduplicateQuestions.length;
-          i < imax;
-          i++
-        ) {
-          for (
-            var j = 0, jmax = this.reduplicateQuestions[i].length;
-            j < jmax;
-            j++
-          ) {
-            if (this.reduplicateQuestions[i][j] == id) {
-              this.reduplicateGroup = [];
-              for (
-                var k = 0, kmax = this.reduplicateQuestions[i].length;
-                k < kmax;
-                k++
-              ) {
-                this.reduplicateGroup.push(this.reduplicateQuestions[i][k]);
-              }
-              return;
-            }
-          }
-        }
-      } else {
-        this.reduplicateGroup = [];
-      }
-    },
     //编辑题目
     editQues(paperDetailUnit, question) {
       console.log("question:", question);
@@ -2359,7 +2321,6 @@ export default {
               .delete(QUESTION_API + "/paperDetailUnit/" + paperDetailUnitId)
               .then(() => {
                 this.initPaper();
-                this.getreduplicateQuestions();
                 this.reduplicateGroup = [];
                 this.loading = true;
                 this.$notify({
@@ -2398,7 +2359,6 @@ export default {
                   });
                 } else {
                   this.initPaper();
-                  this.getreduplicateQuestions();
                   this.reduplicateGroup = [];
                   this.loading = true;
                   this.$notify({
@@ -2412,19 +2372,6 @@ export default {
         },
       });
     },
-    //获取重复试题
-    getreduplicateQuestions() {
-      this.duplicateLoading = true;
-      this.$http
-        .get(QUESTION_API + "/paper/" + this.paperId + "/reduplicate-questions")
-        .then((response) => {
-          this.reduplicateQuestions = response.data;
-          this.duplicateLoading = false;
-          this.initReduplicateQuesColor();
-          // var ques = document.getElementsByClassName("ques")[0];
-          // ques.style.display = "inline";
-        });
-    },
     exportPaperAnswer() {
       var key = this.user.key;
       var token = this.user.token;
@@ -2438,17 +2385,6 @@ export default {
           token
       );
     },
-    initReduplicateQuesColor() {
-      var colorCount = this.reduplicateQuestions.length;
-      if (colorCount > 20) {
-        this.reduplicateQuesColor = randomColor({
-          luminosity: "bright",
-          count: colorCount,
-        });
-      } else {
-        this.reduplicateQuesColor = this.defaultColor;
-      }
-    },
     getSubQuesEditId(paperDetailUnit, subQuestion) {
       return paperDetailUnit.question.id + "_" + subQuestion.subNumber;
     },

+ 1 - 1
src/modules/questions/views/ImportPaper.vue

@@ -707,7 +707,7 @@ export default {
             .catch((error) => {
               this.$notify({
                 type: "error",
-                message: error.response.data.msg,
+                message: error.response.data.desc,
               });
               this.cloneLoading = false;
             });

+ 1 - 115
src/modules/questions/views/ViewPaper.vue

@@ -145,15 +145,6 @@
             :key="unitIndex"
             class="ques"
           >
-            <reduplicate_mark
-              :id="paperDetailUnit.id"
-              :show="reduplicateMarkShow(paperDetailUnit.id)"
-              :fill-color="reduplicateMarkColor(paperDetailUnit.id)"
-              :checked="reduplicateMarkCheck(paperDetailUnit.id)"
-              @reduplicate_mark_check="reduplicate_mark_check"
-            >
-            </reduplicate_mark>
-
             <div
               class="quesSelect"
               @mouseover="quesMouseOver(paperDetailUnit.id)"
@@ -211,10 +202,6 @@
                 :key="subIndex"
                 class="subQues"
               >
-                <reduplicate_mark
-                  :show="reduplicateMarkShow(subQuestion.id)"
-                ></reduplicate_mark>
-
                 <div
                   class="quesSelect"
                   @mouseover="
@@ -508,14 +495,10 @@
 import { QUESTION_API } from "@/constants/constants";
 import { isEmptyStr, QUESTION_TYPES } from "../constants/constants";
 import { mapState } from "vuex";
-import reduplicate_mark from "../component/reduplicate_mark.vue";
-import randomColor from "randomcolor";
 
 export default {
   name: "EditPaperApp",
-  components: {
-    reduplicate_mark,
-  },
+  components: {},
   data() {
     return {
       hValue: "100px",
@@ -647,7 +630,6 @@ export default {
     this.paperId = this.$route.params.id;
     this.parentView = this.$route.params.parentView;
     this.initPaper();
-    this.getreduplicateQuestions();
     this.uploadAction = QUESTION_API + "/uploadRadio/" + this.paperId;
     this.uploadHeaders = {
       key: this.user.key,
@@ -786,78 +768,6 @@ export default {
       }
       return false;
     },
-    reduplicateMarkShow(id) {
-      var found = false;
-      for (var i = 0, imax = this.reduplicateQuestions.length; i < imax; i++) {
-        for (
-          var j = 0, jmax = this.reduplicateQuestions[i].length;
-          j < jmax;
-          j++
-        ) {
-          if (this.reduplicateQuestions[i][j] == id) {
-            found = true;
-            break;
-          }
-        }
-        if (found) {
-          break;
-        }
-      }
-      return found;
-    },
-    reduplicateMarkColor(id) {
-      for (var i = 0, imax = this.reduplicateQuestions.length; i < imax; i++) {
-        for (
-          var j = 0, jmax = this.reduplicateQuestions[i].length;
-          j < jmax;
-          j++
-        ) {
-          if (this.reduplicateQuestions[i][j] == id) {
-            return this.reduplicateQuesColor[i];
-          }
-        }
-      }
-    },
-    reduplicateMarkCheck(id) {
-      for (var i = 0, imax = this.reduplicateGroup.length; i < imax; i++) {
-        if (id == this.reduplicateGroup[i]) {
-          return true;
-        }
-      }
-      return false;
-    },
-    reduplicate_mark_check(id, checked) {
-      console.log(checked);
-      console.log(this.reduplicateQuestions);
-      console.log(id);
-      if (!checked) {
-        for (
-          var i = 0, imax = this.reduplicateQuestions.length;
-          i < imax;
-          i++
-        ) {
-          for (
-            var j = 0, jmax = this.reduplicateQuestions[i].length;
-            j < jmax;
-            j++
-          ) {
-            if (this.reduplicateQuestions[i][j] == id) {
-              this.reduplicateGroup = [];
-              for (
-                var k = 0, kmax = this.reduplicateQuestions[i].length;
-                k < kmax;
-                k++
-              ) {
-                this.reduplicateGroup.push(this.reduplicateQuestions[i][k]);
-              }
-              return;
-            }
-          }
-        }
-      } else {
-        this.reduplicateGroup = [];
-      }
-    },
     //编辑题目
     editQues(paperDetailUnit, question) {
       console.log("question:", question);
@@ -956,30 +866,6 @@ export default {
         }
       }
     },
-    //获取重复试题
-    getreduplicateQuestions() {
-      this.duplicateLoading = true;
-      this.$http
-        .get(QUESTION_API + "/paper/" + this.paperId + "/reduplicate-questions")
-        .then((response) => {
-          this.reduplicateQuestions = response.data;
-          this.duplicateLoading = false;
-          this.initReduplicateQuesColor();
-          // var ques = document.getElementsByClassName("ques")[0];
-          // ques.style.display = "inline";
-        });
-    },
-    initReduplicateQuesColor() {
-      var colorCount = this.reduplicateQuestions.length;
-      if (colorCount > 20) {
-        this.reduplicateQuesColor = randomColor({
-          luminosity: "bright",
-          count: colorCount,
-        });
-      } else {
-        this.reduplicateQuesColor = this.defaultColor;
-      }
-    },
     getSubQuesEditId(paperDetailUnit, subQuestion) {
       return paperDetailUnit.question.id + "_" + subQuestion.subNumber;
     },