zhangjie 2 years ago
parent
commit
8d68139adc

+ 26 - 7
card/assets/styles/card-preview.scss

@@ -22,10 +22,10 @@
       display: none;
       display: none;
     }
     }
   }
   }
-  .elem-fill-question .option-item {
-    border-width: 0.5pt;
-  }
-  .card-head-body .head-stdno .stdno-fill-option {
+  .elem-fill-question .option-item,
+  .card-head-body .head-stdno .stdno-fill-option,
+  .page-number-rect-list li.rect-li-act,
+  .card-head-body .head-dynamic-rect {
     border-width: 0.5pt;
     border-width: 0.5pt;
   }
   }
 }
 }
@@ -650,6 +650,7 @@
           margin-left: 54px;
           margin-left: 54px;
           height: 14px;
           height: 14px;
           text-align: center;
           text-align: center;
+          font-size: 0;
         }
         }
       }
       }
       &-fill {
       &-fill {
@@ -762,13 +763,14 @@
       }
       }
       &-rect {
       &-rect {
         display: inline-block;
         display: inline-block;
-        width: 30px;
-        height: 14px;
+        vertical-align: middle;
+        width: 24px;
+        height: 12px;
         // border-rect
         // border-rect
         border: 1px solid #000;
         border: 1px solid #000;
         font-size: 12px;
         font-size: 12px;
         text-align: center;
         text-align: center;
-        line-height: 1;
+        line-height: 10px;
         color: #000;
         color: #000;
         margin: 0 5px;
         margin: 0 5px;
         font-family: "Times New Roman", Arial, sans-serif;
         font-family: "Times New Roman", Arial, sans-serif;
@@ -1097,6 +1099,23 @@
       background-color: mix(#fff, $--color-warning, 20%);
       background-color: mix(#fff, $--color-warning, 20%);
     }
     }
   }
   }
+  &-boolean {
+    .option-item {
+      &:nth-of-type(2) i {
+        background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAItJREFUOE/Vk9ERgCAMQ8M+GUInEyfTITKQV065KuDh8SWftHkNAQIGVxjU44cAkhHAAmCVFD8dwYktulnS3g2oiY2SAdZglmq34sS7pNn3JADJCcAGoGggaftWL2qFgzOc3OjEKbCau1sG3uo51TRN8c3BRX+E9SquAlwmU8t2EeLIf+h+B60hw4ADyTE7EWzzfYYAAAAASUVORK5CYII=);
+        background-size: 100% 100%;
+        width: 10px;
+        height: 10px;
+        margin-top: -1px;
+      }
+      &:nth-of-type(3) i {
+        background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAIVJREFUOE+tk9sNwCAIRa/7MES7WTerQ7BPGxolCpKmVT+Fe3gnTL40qUcHIKKNmXMEFTsA8TmqjwKK8SyG3YIiewQQjkKMGMysOlcCgJrFAykZdX9tdq6JNprphyttOIUA4sQCXw+YKmEg/tZEIrqapoVjbEe8bpEk8tsqj3zWHtOfy7wB41tXEXo/wKEAAAAASUVORK5CYII=);
+        background-size: 100% 100%;
+        width: 8px;
+        height: 8px;
+      }
+    }
+  }
 
 
   .elem-body {
   .elem-body {
     padding: 10px 5px;
     padding: 10px 5px;

+ 22 - 7
card/assets/styles/card-temp.css

@@ -19,10 +19,10 @@
 .card-print .elem-fill-question-first::before {
 .card-print .elem-fill-question-first::before {
   display: none;
   display: none;
 }
 }
-.card-print .elem-fill-question .option-item {
-  border-width: 0.5pt;
-}
-.card-print .card-head-body .head-stdno .stdno-fill-option {
+.card-print .elem-fill-question .option-item,
+.card-print .card-head-body .head-stdno .stdno-fill-option,
+.card-print .page-number-rect-list li.rect-li-act,
+.card-print .card-head-body .head-dynamic-rect {
   border-width: 0.5pt;
   border-width: 0.5pt;
 }
 }
 
 
@@ -562,6 +562,7 @@
   margin-left: 54px;
   margin-left: 54px;
   height: 14px;
   height: 14px;
   text-align: center;
   text-align: center;
+  font-size: 0;
 }
 }
 .card-head-body .head-dynamic-fill {
 .card-head-body .head-dynamic-fill {
   padding: 10px;
   padding: 10px;
@@ -619,12 +620,13 @@
 }
 }
 .card-head-body .head-dynamic-rect {
 .card-head-body .head-dynamic-rect {
   display: inline-block;
   display: inline-block;
-  width: 30px;
-  height: 14px;
+  vertical-align: middle;
+  width: 24px;
+  height: 12px;
   border: 1px solid #000;
   border: 1px solid #000;
   font-size: 12px;
   font-size: 12px;
   text-align: center;
   text-align: center;
-  line-height: 1;
+  line-height: 10px;
   color: #000;
   color: #000;
   margin: 0 5px;
   margin: 0 5px;
   font-family: "Times New Roman", Arial, sans-serif;
   font-family: "Times New Roman", Arial, sans-serif;
@@ -902,6 +904,19 @@
   content: "判断";
   content: "判断";
   background-color: #ffa952;
   background-color: #ffa952;
 }
 }
+.elem-fill-question-boolean .option-item:nth-of-type(2) i {
+  background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAItJREFUOE/Vk9ERgCAMQ8M+GUInEyfTITKQV065KuDh8SWftHkNAQIGVxjU44cAkhHAAmCVFD8dwYktulnS3g2oiY2SAdZglmq34sS7pNn3JADJCcAGoGggaftWL2qFgzOc3OjEKbCau1sG3uo51TRN8c3BRX+E9SquAlwmU8t2EeLIf+h+B60hw4ADyTE7EWzzfYYAAAAASUVORK5CYII=);
+  background-size: 100% 100%;
+  width: 10px;
+  height: 10px;
+  margin-top: -1px;
+}
+.elem-fill-question-boolean .option-item:nth-of-type(3) i {
+  background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAIVJREFUOE+tk9sNwCAIRa/7MES7WTerQ7BPGxolCpKmVT+Fe3gnTL40qUcHIKKNmXMEFTsA8TmqjwKK8SyG3YIiewQQjkKMGMysOlcCgJrFAykZdX9tdq6JNprphyttOIUA4sQCXw+YKmEg/tZEIrqapoVjbEe8bpEk8tsqj3zWHtOfy7wB41tXEXo/wKEAAAAASUVORK5CYII=);
+  background-size: 100% 100%;
+  width: 8px;
+  height: 8px;
+}
 .elem-fill-question .elem-body {
 .elem-fill-question .elem-body {
   padding: 10px 5px;
   padding: 10px 5px;
   font-size: 0;
   font-size: 0;

+ 0 - 72
card/elements/fill-question/EditFillQuestion.vue

@@ -77,38 +77,6 @@
           >
           >
         </el-radio-group>
         </el-radio-group>
       </el-form-item>
       </el-form-item>
-      <el-form-item v-if="modalForm.isBoolean" label="是否配置:">
-        <el-select
-          v-model="modalForm.booleanType"
-          style="width: 125px"
-          placeholder="请选择"
-          @change="booleanTypeChange"
-        >
-          <el-option
-            v-for="item in BOOLEAN_TYPE"
-            :key="item"
-            :label="item"
-            :value="item"
-          ></el-option>
-        </el-select>
-        <span>(备选是否配置)</span>
-      </el-form-item>
-      <el-form-item v-if="modalForm.isBoolean" prop="booleanType">
-        <span>是:</span>
-        <el-input
-          v-model.trim="booleanTypes.yes"
-          :maxlength="1"
-          placeholder="是"
-          style="margin-right: 20px; width: 60px"
-        ></el-input>
-        <span>否:</span>
-        <el-input
-          v-model.trim="booleanTypes.no"
-          :maxlength="1"
-          placeholder="否"
-          style="margin-right: 20px; width: 60px"
-        ></el-input>
-      </el-form-item>
     </el-form>
     </el-form>
   </div>
   </div>
 </template>
 </template>
@@ -160,32 +128,11 @@ export default {
       }
       }
     };
     };
 
 
-    const booleanTypeValidater = (rule, value, callback) => {
-      if (this.modalForm.isBoolean) {
-        if (
-          this.booleanTypes.yes &&
-          this.booleanTypes.no &&
-          this.booleanTypes.yes.length <= 2 &&
-          this.booleanTypes.no.length <= 2
-        ) {
-          callback();
-        } else {
-          callback(new Error("请设置是否配置,单个设置最多两个字符。"));
-        }
-      } else {
-        callback();
-      }
-    };
-
     return {
     return {
       modalForm: { ...initModalForm },
       modalForm: { ...initModalForm },
       BOOLEAN_TYPE,
       BOOLEAN_TYPE,
       DIRECTION_TYPE,
       DIRECTION_TYPE,
       topicType: null,
       topicType: null,
-      booleanTypes: {
-        yes: "",
-        no: "",
-      },
       rules: {
       rules: {
         topicType: [
         topicType: [
           {
           {
@@ -228,13 +175,6 @@ export default {
             trigger: "change",
             trigger: "change",
           },
           },
         ],
         ],
-        booleanType: [
-          {
-            required: true,
-            validator: booleanTypeValidater,
-            trigger: "change",
-          },
-        ],
       },
       },
     };
     };
   },
   },
@@ -248,12 +188,6 @@ export default {
       this.modalForm = Object.assign({}, initModalForm, valInfo);
       this.modalForm = Object.assign({}, initModalForm, valInfo);
       this.modalForm.endNumber =
       this.modalForm.endNumber =
         this.modalForm.startNumber + this.modalForm.questionsCount - 1;
         this.modalForm.startNumber + this.modalForm.questionsCount - 1;
-      this.booleanTypeChange();
-    },
-    booleanTypeChange() {
-      const [yes, no] = this.modalForm.booleanType.split(",");
-      this.booleanTypes.yes = yes;
-      this.booleanTypes.no = no;
     },
     },
     topicTypeChange() {
     topicTypeChange() {
       if (this.topicType === "single") {
       if (this.topicType === "single") {
@@ -268,8 +202,6 @@ export default {
         this.modalForm.isMultiply = false;
         this.modalForm.isMultiply = false;
         this.modalForm.isBoolean = true;
         this.modalForm.isBoolean = true;
         this.modalForm.optionCount = 2;
         this.modalForm.optionCount = 2;
-        this.modalForm.booleanType = BOOLEAN_TYPE[0];
-        this.booleanTypeChange();
       }
       }
     },
     },
     getTopicType(info) {
     getTopicType(info) {
@@ -283,10 +215,6 @@ export default {
 
 
       this.modalForm.questionsCount =
       this.modalForm.questionsCount =
         this.modalForm.endNumber - this.modalForm.startNumber + 1;
         this.modalForm.endNumber - this.modalForm.startNumber + 1;
-      this.modalForm.booleanType = [
-        this.booleanTypes.yes,
-        this.booleanTypes.no,
-      ].join();
       this.modalForm.topicName = this.modalForm.topicName.trim();
       this.modalForm.topicName = this.modalForm.topicName.trim();
       this.$emit("modified", this.modalForm);
       this.$emit("modified", this.modalForm);
     },
     },

+ 1 - 1
card/elements/fill-question/ElemFillQuestion.vue

@@ -106,7 +106,7 @@ export default {
     },
     },
     getChoiceList(data) {
     getChoiceList(data) {
       if (data.isBoolean) {
       if (data.isBoolean) {
-        return data.booleanType.split(",");
+        return ["", ""];
       } else {
       } else {
         return "abcdefghijklmnopqrstuv"
         return "abcdefghijklmnopqrstuv"
           .toUpperCase()
           .toUpperCase()

File diff suppressed because it is too large
+ 0 - 0
card/previewTemp.js


Some files were not shown because too many files changed in this diff