zengyicheng 3 years ago
parent
commit
10381fafa4

+ 1 - 1
dist/index.html

@@ -25,4 +25,4 @@
       height: 100%;
       width: 100%;
       background: #e6eaf0;
-    }</style><link href=./static/css/app.c428b67e945fa12b2a7fee6a1f5082ae.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.fed1de90e0941b3846db.js></script><script type=text/javascript src=./static/js/vendor.57c88615aac160d2c474.js></script><script type=text/javascript src=./static/js/app.4dcded77cf28e62c129b.js></script></body></html>
+    }</style><link href=./static/css/app.4d1da405e143059969233ade34820ee2.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.fed1de90e0941b3846db.js></script><script type=text/javascript src=./static/js/vendor.57c88615aac160d2c474.js></script><script type=text/javascript src=./static/js/app.e390d3183b45586b2255.js></script></body></html>

File diff suppressed because it is too large
+ 0 - 0
dist/static/css/app.4d1da405e143059969233ade34820ee2.css


File diff suppressed because it is too large
+ 0 - 0
dist/static/css/app.4d1da405e143059969233ade34820ee2.css.map


File diff suppressed because it is too large
+ 0 - 0
dist/static/css/app.c428b67e945fa12b2a7fee6a1f5082ae.css.map


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/app.4dcded77cf28e62c129b.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/app.4dcded77cf28e62c129b.js.map


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/app.e390d3183b45586b2255.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/app.e390d3183b45586b2255.js.map


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/manifest.fed1de90e0941b3846db.js.map


+ 39 - 21
src/components/pages/addCourse.vue

@@ -150,7 +150,9 @@
                 <div class="right_first">
                   <div>
                     <div style="flex: 0.5 1 0%; margin: 0 20px 0 0">
-                      <div class="bInfo_title">课程封面</div>
+                      <div class="bInfo_title">
+                        <span style="color: red">*</span>课程封面
+                      </div>
 
                       <el-upload
                         :class="{ disUoloadSty: noneBtnImg }"
@@ -1134,6 +1136,7 @@ export default {
         if (
           this.courseName != "" &&
           this.courseText != "" &&
+          this.cover.length != 0 &&
           this.checkboxList.length != 0
         ) {
           this.steps = 2;
@@ -1157,6 +1160,7 @@ export default {
         if (
           this.courseName != "" &&
           this.courseText != "" &&
+          this.cover.length != 0 &&
           this.checkboxList.length != 0
         ) {
           this.steps++;
@@ -1443,9 +1447,13 @@ export default {
             title: "",
             courseName: "",
             chapterData: [],
+            toolChoose: [],
+            askCount: 1,
+            askTitle: "",
+            askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
+            checkJson: [{ checkCount: [], checkPerent: [] }],
             itemCount: 1,
             fileList1: [],
-            toolChoose: [],
             homeworkList: [],
             video: [],
             testData: [],
@@ -1671,31 +1679,41 @@ export default {
           this.dialogVisible4 = true;
         }
       } else {
-        if (
-          this.unitJson[this.unitIndex].chapterInfo[0].toolChoose.indexOf(i) !=
-          -1
-        ) {
-          this.unitJson[this.unitIndex].chapterInfo[0].toolChoose.splice(
-            this.unitJson[this.unitIndex].chapterInfo[0].toolChoose.indexOf(i),
-            1
-          );
-          if (i == 4) {
-            this.unitJson[this.unitIndex].chapterInfo[0].askTitle = "";
-            this.unitJson[this.unitIndex].chapterInfo[0].askJson = [];
-            this.unitJson[this.unitIndex].chapterInfo[0].askJson.push({
-              askstitle: "",
-              askItem: 1,
-              checkList: [],
-            });
-          }
+        if (i == 4) {
+          this.dialogVisible4 = true;
         } else {
-          this.unitJson[this.unitIndex].chapterInfo[0].toolChoose.push(i);
+          if (
+            this.unitJson[this.unitIndex].chapterInfo[0].toolChoose.indexOf(
+              i
+            ) != -1
+          ) {
+            this.unitJson[this.unitIndex].chapterInfo[0].toolChoose.splice(
+              this.unitJson[this.unitIndex].chapterInfo[0].toolChoose.indexOf(
+                i
+              ),
+              1
+            );
+            // if (i == 4) {
+            //   this.unitJson[this.unitIndex].chapterInfo[0].askTitle = "";
+            //   this.unitJson[this.unitIndex].chapterInfo[0].askJson = [];
+            //   this.unitJson[this.unitIndex].chapterInfo[0].askJson.push({
+            //     askstitle: "",
+            //     askItem: 1,
+            //     checkList: [],
+            //   });
+            // }
+          } else {
+            this.unitJson[this.unitIndex].chapterInfo[0].toolChoose.push(i);
+          }
         }
       }
       this.$forceUpdate();
     },
     cleanAsk(p) {
-      this.unitJson[this.unitIndex].chapterInfo[0].toolChoose.splice(p, 1);
+      this.unitJson[this.unitIndex].chapterInfo[0].toolChoose.splice(
+        this.unitJson[this.unitIndex].chapterInfo[0].toolChoose.indexOf(p),
+        1
+      );
       this.unitJson[this.unitIndex].chapterInfo[0].askTitle = "";
       this.unitJson[this.unitIndex].chapterInfo[0].askJson = [];
       this.unitJson[this.unitIndex].chapterInfo[0].askJson.push({

+ 62 - 14
src/components/pages/ask.vue

@@ -1,12 +1,36 @@
 <template>
-  <div class="pb_content">
-    <div class="pb_head">
-      <span>问卷调查</span>
-      <div>
-        <el-button type="primary" @click="createPop">创建问卷调查</el-button>
-        <el-button type="primary" @click="goTo('/ask/askList?userid=' + userid)"
-          >查看已提交问卷</el-button
-        >
+  <div
+    class="pb_content"
+    style="
+      margin: 20px;
+      width: 98%;
+      height: 95%;
+      min-height: 750px;
+      border-radius: 5px;
+      min-width: 960px;
+      background: unset;
+      padding-top: 20px;
+    "
+  >
+    <div
+      class="pb_content_body"
+      style="
+        background: #fff;
+        padding: 0px 25px;
+        box-sizing: border-box;
+        border-radius: 5px;
+      "
+    >
+      <div class="pb_head">
+        <span>问卷调查</span>
+        <div class="askButton">
+          <el-button type="primary" @click="createPop">创建问卷调查</el-button>
+          <el-button
+            type="primary"
+            @click="goTo('/ask/askList?userid=' + userid)"
+            >查看已提交问卷</el-button
+          >
+        </div>
       </div>
     </div>
     <div class="pb_content_body">
@@ -15,12 +39,12 @@
           ref="table"
           :data="tableData"
           border
-          stripe
           :height="tableHeight"
           :fit="true"
           v-loading="isLoading"
-          style="width: 100%; height: 60%"
-          :header-cell-style="{ background: '#f1f1f1' }"
+          style="width: 100%"
+          :header-cell-style="{ background: '#f1f1f1', fontSize: '17px' }"
+          :row-class-name="tableRowClassName"
         >
           <el-table-column
             prop="title"
@@ -70,7 +94,7 @@
       title="创建问卷调查"
       :visible.sync="dialogVisible"
       :append-to-body="true"
-      width="750px"
+      width="800px"
       :before-close="handleClose"
       class="dialog_diy"
     >
@@ -287,6 +311,13 @@ export default {
     };
   },
   methods: {
+    tableRowClassName({ row, rowIndex }) {
+      if ((rowIndex + 1) % 2 === 0) {
+        return "even_row";
+      } else {
+        return "";
+      }
+    },
     addAskList() {
       this.checkJson.push({ checkCount: [], checkPerent: [] });
       this.askJson.push({ askstitle: "", askItem: 1, checkList: [] });
@@ -563,10 +594,10 @@ export default {
 .dialog_diy >>> .el-dialog__headerbtn .el-dialog__close:hover {
   color: #fff;
 }
-.dialog_diy >>> .el-dialog__body {
+/* .dialog_diy >>> .el-dialog__body {
   max-height: 750px;
   overflow: auto;
-}
+} */
 .dialog_diy >>> .el-dialog {
   background: #fafafa;
 }
@@ -585,6 +616,8 @@ export default {
   margin: 10px 0;
   background: #fff;
   padding: 15px;
+  max-height: 400px;
+  overflow: auto;
 }
 .a_add_box {
   border-bottom: 2px solid #eee;
@@ -651,4 +684,19 @@ export default {
   justify-content: center;
   flex-direction: column;
 }
+.askButton > button {
+  color: #fff;
+  background: #2268bc;
+  width: 105px;
+  height: 40px;
+  padding: 0 !important;
+  font-size: 12px;
+  line-height: 40px;
+}
+.student_table >>> .el-table--border td {
+  border-right: 0px !important;
+}
+.el-table >>> .even_row {
+  background-color: #f1f1f1 !important;
+}
 </style>

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