zengyicheng 2 роки тому
батько
коміт
cb2cd29e35

BIN
src/assets/icon/secondToolList/eval.png


+ 274 - 14
src/components/study.vue

@@ -900,6 +900,14 @@
                                 class="iframeCss"
                               ></iframe>
                             </div>
+                            <div v-if="tooC == 40">
+                              <img
+                                @click="addTools(tooC, toolIndex, taskCount)"
+                                src="../assets/icon/secondToolList/eval.png"
+                                alt
+                              />
+                              <div style="margin: 5px 0">学生评价</div>
+                            </div>
                           </div>
                         </div>
                       </div>
@@ -930,7 +938,11 @@
                       >
                         <div
                           class="works"
-                          style="width: 200px; height: 140px; padding: 25px 0"
+                          style="
+                            width: 200px;
+                            height: 140px;
+                            margin: 10px 10px 10px 0;
+                          "
                           v-for="(w, wIndex) in worksStudent[jdIndex][rwIndex][
                             toolIndex
                           ]"
@@ -978,7 +990,10 @@
                                 </div>
                                 <div>{{ w.likesCount }}</div>
                               </div>
-                              <div class="commentList">
+                              <div
+                                class="commentList"
+                                style="margin-right: 15px"
+                              >
                                 <div
                                   class="commentImg"
                                   @click="commentOther(w)"
@@ -1167,7 +1182,10 @@
                                 </div>
                                 <div>{{ w.likesCount }}</div>
                               </div>
-                              <div class="commentList">
+                              <div
+                                class="commentList"
+                                style="margin-right: 15px"
+                              >
                                 <div
                                   class="commentImg"
                                   @click="commentOther(w)"
@@ -1222,7 +1240,11 @@
                       >
                         <div
                           class="works"
-                          style="width: 200px; height: 140px; padding: 25px 0"
+                          style="
+                            width: 200px;
+                            height: 140px;
+                            margin: 10px 10px 10px 0;
+                          "
                           v-for="(w, wIndex) in worksStudent[jdIndex][rwIndex][
                             toolIndex
                           ]"
@@ -1255,7 +1277,10 @@
                                 </div>
                                 <div>{{ w.likesCount }}</div>
                               </div>
-                              <div class="commentList">
+                              <div
+                                class="commentList"
+                                style="margin-right: 15px"
+                              >
                                 <div
                                   class="commentImg"
                                   @click="commentOther(w)"
@@ -1310,7 +1335,11 @@
                       >
                         <div
                           class="works"
-                          style="width: 200px; height: 140px; padding: 25px 0"
+                          style="
+                            width: 200px;
+                            height: 140px;
+                            margin: 10px 10px 10px 0;
+                          "
                           v-for="(w, wIndex) in worksStudent[jdIndex][rwIndex][
                             toolIndex
                           ]"
@@ -1343,7 +1372,10 @@
                                 </div>
                                 <div>{{ w.likesCount }}</div>
                               </div>
-                              <div class="commentList">
+                              <div
+                                class="commentList"
+                                style="margin-right: 15px"
+                              >
                                 <div
                                   class="commentImg"
                                   @click="commentOther(w)"
@@ -1398,7 +1430,11 @@
                       >
                         <div
                           class="works"
-                          style="width: 200px; height: 140px; padding: 25px 0"
+                          style="
+                            width: 200px;
+                            height: 140px;
+                            margin: 10px 10px 10px 0;
+                          "
                           v-for="(w, wIndex) in worksStudent[jdIndex][rwIndex][
                             toolIndex
                           ]"
@@ -1431,7 +1467,10 @@
                                 </div>
                                 <div>{{ w.likesCount }}</div>
                               </div>
-                              <div class="commentList">
+                              <div
+                                class="commentList"
+                                style="margin-right: 15px"
+                              >
                                 <div
                                   class="commentImg"
                                   @click="commentOther(w)"
@@ -1486,7 +1525,11 @@
                       >
                         <div
                           class="works"
-                          style="width: 200px; height: 140px; padding: 25px 0"
+                          style="
+                            width: 200px;
+                            height: 140px;
+                            margin: 10px 10px 10px 0;
+                          "
                           v-for="(w, wIndex) in worksStudent[jdIndex][rwIndex][
                             toolIndex
                           ]"
@@ -1519,7 +1562,10 @@
                                 </div>
                                 <div>{{ w.likesCount }}</div>
                               </div>
-                              <div class="commentList">
+                              <div
+                                class="commentList"
+                                style="margin-right: 15px"
+                              >
                                 <div
                                   class="commentImg"
                                   @click="commentOther(w)"
@@ -1613,6 +1659,112 @@
                         </div>
                       </div>
                     </div>
+                    <div
+                      v-if="
+                        worksStudent[jdIndex] &&
+                        worksStudent[jdIndex][rwIndex] &&
+                        tType &&
+                        tType == 3 &&
+                        tool.tool.indexOf(40) != -1
+                      "
+                      class="worksBox"
+                    >
+                      <div
+                        style="padding-top: 15px; font-size: 18px"
+                        v-if="
+                          worksStudent[jdIndex][rwIndex][toolIndex].length > 0
+                        "
+                      >
+                        作业预览
+                      </div>
+                      <div
+                        class="worksDetailBox"
+                        v-if="
+                          worksStudent[jdIndex][rwIndex][toolIndex].length > 0
+                        "
+                      >
+                        <div
+                          class="works"
+                          v-for="(w, wIndex) in worksStudent[jdIndex][rwIndex][
+                            toolIndex
+                          ]"
+                          :key="wIndex"
+                        >
+                          <div
+                            class="workImg"
+                            style="
+                              border-radius: 15px;
+                              box-shadow: 0px 0px 10px 10px #f2f2f2;
+                            "
+                          >
+                            <!-- <img
+                            src="../assets/icon/works/noImg.png"
+                            @click="openTools(15, toolIndex, taskCount, w.works)"
+                            alt=""
+                          />-->
+                            <div
+                              class="answerBg"
+                              style="border-radius: 15px 15px 0 0"
+                            >
+                              <div>{{ w.sName }}</div>
+                              <el-tooltip
+                                class="item"
+                                effect="light"
+                                :content="w.works"
+                                placement="top"
+                              >
+                                <div class="answerContent">
+                                  {{ w.works }}
+                                </div>
+                              </el-tooltip>
+                            </div>
+                            <div class="comment">
+                              <div class="commentList">
+                                <div
+                                  class="commentImg"
+                                  @click="
+                                    isLikes(w.wid, userid, 1, null, w.isLikes)
+                                  "
+                                >
+                                  <img
+                                    :src="w.isLikes == true ? likes : noLikes"
+                                    alt=""
+                                  />
+                                </div>
+                                <div>{{ w.likesCount }}</div>
+                              </div>
+                              <div
+                                class="commentList"
+                                style="margin-right: 15px"
+                              >
+                                <div
+                                  class="commentImg"
+                                  @click="commentOther(w)"
+                                >
+                                  <img
+                                    src="../assets/icon/comment/comment.png"
+                                    alt=""
+                                  />
+                                </div>
+                                <div>{{ w.commentCount }}</div>
+                              </div>
+                            </div>
+                          </div>
+                        </div>
+                      </div>
+                      <div style="padding-top: 15px; font-size: 18px">
+                        未提交
+                      </div>
+                      <div class="noWorksS">
+                        <div
+                          v-for="(s, sIndex) in noWorksS[toolIndex]"
+                          :key="sIndex"
+                          class="noWorksName"
+                        >
+                          {{ s.student }}
+                        </div>
+                      </div>
+                    </div>
                   </div>
                   <!-- <div class="upload_toolBtn" @click="addImg($event)">
                   上传文件
@@ -2334,6 +2486,12 @@
             style="width: 90%; height: 100%; margin: 0 0 0 30px"
           ></video-player>
         </div>
+        <div
+          class="worksAnswer"
+          v-if="commentDetail.works && commentDetail.type == 4"
+        >
+          {{ commentDetail.works }}
+        </div>
         <div class="comment">
           <div class="commentList">
             <div class="commentImg">
@@ -2461,6 +2619,48 @@
         <el-button @click="fullDialogVisible = false">关 闭</el-button>
       </div> -->
     </el-dialog>
+    <el-dialog
+      title="学生评价"
+      :visible.sync="studentEvalDialogVisible"
+      :append-to-body="true"
+      width="800px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <div class="evalCss">
+        <div class="nav">请选择星星进行评分</div>
+        <div class="middleBox">
+          <div class="pfBox" v-for="(e, eIndex) in rateJson" :key="eIndex">
+            <div class="nameAndrate">
+              <div>{{ e.value }}</div>
+              <el-rate v-model="e.score" disabled></el-rate>
+            </div>
+            <div>{{ e.detail }}</div>
+          </div>
+          <div class="bz">
+            <div>备注</div>
+            <textarea
+              rows="4"
+              class="pj"
+              style="
+                padding: 10px 5px;
+                width: 70%;
+                background: #f7f6f9;
+                font-size: 14px;
+                text-indent: 10px;
+              "
+              cols
+              v-model="bzText"
+              placeholder="请输入评价内容..."
+            ></textarea>
+          </div>
+        </div>
+      </div>
+      <div slot="footer">
+        <el-button @click="studentEvalDialogVisible = false">取 消</el-button>
+        <el-button type="primary" @click="addBzWorks">确 定</el-button>
+      </div>
+    </el-dialog>
   </div>
 </template>
 
@@ -2480,8 +2680,10 @@ export default {
       dialogVisible: false,
       commentDialogVisible: false,
       videoVisible: false,
+      studentEvalDialogVisible: false,
       videoDetail: {},
       commentDetail: [],
+      rateJson: [],
       id: this.$route.query.courseId,
       userid: this.$route.query.userid,
       classId: this.$route.query.cid,
@@ -2598,6 +2800,7 @@ export default {
       timeCount: 0,
       answerCount: 0,
       trainCount: 0,
+      evalCount: 0,
       dialogImageUrl: "",
       pictureDialog: false,
       toolTypeList: [],
@@ -2620,6 +2823,7 @@ export default {
       },
       checkJson: [],
       askList: [],
+      sIsOpen: false,
       answerList: [],
       navList: [],
       worksStudent: [],
@@ -2639,6 +2843,7 @@ export default {
       noteName: "",
       evaJuri: [],
       evalua: "",
+      bzText:"",
       eTitle: "",
       eName: "",
       eJson: {},
@@ -3077,7 +3282,7 @@ export default {
 
                     if (b[j].stage == q && b[j].task == w) {
                       // 1、电子白板,3、思维导图,6协同文档,7思维网格 16、作业提交
-                      let _toolsAarry1 = [1, 3, 6, 7, 16];
+                      let _toolsAarry1 = [1, 3, 6, 7, 16,40];
                       let _toolsAarry2 = [4];
                       let _toolsAarry3 = [15];
                       for (var k = 0; k < p.length; k++) {
@@ -3104,7 +3309,10 @@ export default {
                         }
                       }
                       if (
-                        (b[j].type == 1 || b[j].type == 4 || b[j].type == 5) &&
+                        (b[j].type == 1 ||
+                          b[j].type == 4 ||
+                          b[j].type == 5 ||
+                          b[j].type == 6) &&
                         _toolsAarry1.indexOf(e[i].tool[0]) != -1
                       ) {
                         if (
@@ -3147,6 +3355,18 @@ export default {
                             isLikes: isLikes,
                             commentJson: commentJson,
                           });
+                        } else if (b[j].type == 6) {
+                          this.worksStudent[q][w][i].push({
+                            wid: b[j].id,
+                            works: b[j].content,
+                            sName: b[j].name,
+                            type: 4,
+                            time: b[j].time,
+                            likesCount: likesCount,
+                            commentCount: commentCount,
+                            isLikes: isLikes,
+                            commentJson: commentJson,
+                          });
                         } else {
                           this.worksStudent[q][w][i].push({
                             wid: b[j].id,
@@ -4027,6 +4247,33 @@ export default {
     openAddWork() {
       this.dialogVisible = true;
     },
+    addBzWorks() {
+      let params = [
+        {
+          uid: this.userid,
+          cid: this.id,
+          stage: this.courseType,
+          task: this.taskCount,
+          tool: this.toolindex,
+          content: this.bzText,
+          type: 6,
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "addCourseWorks", params)
+        .then((res) => {
+          this.$message({
+            message: "提交成功",
+            type: "success",
+          });
+          this.bzText = "";
+          this.studentEvalDialogVisible = false;
+        })
+        .catch((err) => {
+          this.$message.error("提交失败");
+          console.error(err);
+        });
+    },
     addStudentAsk() {
       this.askList.push({ askJson: this.askJson, anwer: this.radio.join(",") });
       let params = [
@@ -4431,6 +4678,19 @@ export default {
           },
           "*"
         );
+      } else if (t == 40) {
+        if (this.evalCount > 0) {
+          this.updateCount(this.evalCount, t);
+        } else {
+          this.evalCount++;
+          a = this.evalCount;
+          this.toolsCount(a, t);
+        }
+        this.rateJson =
+          this.chapInfoList[this.courseType].chapterInfo[0].taskJson[
+            index
+          ].toolChoose[i].rateJson;
+        this.studentEvalDialogVisible = true;
       }
     },
     toolsCount(a, t) {
@@ -5730,7 +5990,7 @@ export default {
 }
 .workImg {
   width: 100%;
-  height: calc(100% - 40px);
+  height: 105px;
 }
 .workImg > img {
   width: 100%;

+ 356 - 23
src/components/studyStudent.vue

@@ -849,6 +849,14 @@
                             />
                             <div style="margin: 5px 0">源码编辑</div>
                           </div>
+                          <div v-if="tooC == 40">
+                            <img
+                              @click="addTools(tooC, toolIndex, taskCount)"
+                              src="../assets/icon/secondToolList/eval.png"
+                              alt
+                            />
+                            <div style="margin: 5px 0">学生评价</div>
+                          </div>
                         </div>
                       </div>
                     </div>
@@ -875,7 +883,11 @@
                     >
                       <div
                         class="works"
-                        style="width: 200px; height: 140px; padding: 25px 0"
+                        style="
+                          width: 200px;
+                          height: 140px;
+                          margin: 10px 10px 10px 0;
+                        "
                         v-for="(w, wIndex) in workStudent[toolIndex]"
                         :key="wIndex"
                       >
@@ -1014,7 +1026,11 @@
                     >
                       <div
                         class="works"
-                        style="width: 200px; height: 140px; padding: 25px 0"
+                        style="
+                          width: 200px;
+                          height: 140px;
+                          margin: 10px 10px 10px 0;
+                        "
                         v-for="(w, wIndex) in workStudent[toolIndex]"
                         :key="wIndex"
                       >
@@ -1047,7 +1063,11 @@
                     >
                       <div
                         class="works"
-                        style="width: 200px; height: 140px; padding: 25px 0"
+                        style="
+                          width: 200px;
+                          height: 140px;
+                          margin: 10px 10px 10px 0;
+                        "
                         v-for="(w, wIndex) in workStudent[toolIndex]"
                         :key="wIndex"
                       >
@@ -1080,7 +1100,11 @@
                     >
                       <div
                         class="works"
-                        style="width: 200px; height: 140px; padding: 25px 0"
+                        style="
+                          width: 200px;
+                          height: 140px;
+                          margin: 10px 10px 10px 0;
+                        "
                         v-for="(w, wIndex) in workStudent[toolIndex]"
                         :key="wIndex"
                       >
@@ -1113,7 +1137,11 @@
                     >
                       <div
                         class="works"
-                        style="width: 200px; height: 140px; padding: 25px 0"
+                        style="
+                          width: 200px;
+                          height: 140px;
+                          margin: 10px 10px 10px 0;
+                        "
                         v-for="(w, wIndex) in workStudent[toolIndex]"
                         :key="wIndex"
                       >
@@ -1146,7 +1174,11 @@
                     >
                       <div
                         class="works"
-                        style="width: 200px; height: 140px; padding: 25px 0"
+                        style="
+                          width: 200px;
+                          height: 140px;
+                          margin: 10px 10px 10px 0;
+                        "
                         v-for="(w, wIndex) in workStudent[toolIndex]"
                         :key="wIndex"
                       >
@@ -1189,7 +1221,11 @@
                     >
                       <div
                         class="works"
-                        style="width: 200px; height: 140px; padding: 25px 0"
+                        style="
+                          width: 200px;
+                          height: 140px;
+                          margin: 10px 10px 10px 0;
+                        "
                         v-for="(w, wIndex) in worksStudent[toolIndex]"
                         :key="wIndex"
                         :class="w.type == 1 ? 'isTypeOne' : ''"
@@ -1236,7 +1272,7 @@
                               </div>
                               <div>{{ w.likesCount }}</div>
                             </div>
-                            <div class="commentList">
+                            <div class="commentList" style="margin-right: 15px">
                               <div class="commentImg" @click="commentOther(w)">
                                 <img
                                   src="../assets/icon/comment/comment.png"
@@ -1413,7 +1449,7 @@
                               </div>
                               <div>{{ w.likesCount }}</div>
                             </div>
-                            <div class="commentList">
+                            <div class="commentList" style="margin-right: 15px">
                               <div class="commentImg" @click="commentOther(w)">
                                 <img
                                   src="../assets/icon/comment/comment.png"
@@ -1463,7 +1499,11 @@
                     >
                       <div
                         class="works"
-                        style="width: 200px; height: 140px; padding: 25px 0"
+                        style="
+                          width: 200px;
+                          height: 140px;
+                          margin: 10px 10px 10px 0;
+                        "
                         v-for="(w, wIndex) in worksStudent[toolIndex]"
                         :key="wIndex"
                       >
@@ -1494,7 +1534,7 @@
                               </div>
                               <div>{{ w.likesCount }}</div>
                             </div>
-                            <div class="commentList">
+                            <div class="commentList" style="margin-right: 15px">
                               <div class="commentImg" @click="commentOther(w)">
                                 <img
                                   src="../assets/icon/comment/comment.png"
@@ -1544,7 +1584,11 @@
                     >
                       <div
                         class="works"
-                        style="width: 200px; height: 140px; padding: 25px 0"
+                        style="
+                          width: 200px;
+                          height: 140px;
+                          margin: 10px 10px 10px 0;
+                        "
                         v-for="(w, wIndex) in worksStudent[toolIndex]"
                         :key="wIndex"
                       >
@@ -1556,9 +1600,6 @@
                             alt
                           />
                         </div>
-                        <div class="worksName">
-                          <div>{{ w.sName }}</div>
-                        </div>
                         <div class="comment" style="min-width: 200px">
                           <div class="worksName">
                             <div>{{ w.sName }}</div>
@@ -1578,7 +1619,7 @@
                               </div>
                               <div>{{ w.likesCount }}</div>
                             </div>
-                            <div class="commentList">
+                            <div class="commentList" style="margin-right: 15px">
                               <div class="commentImg" @click="commentOther(w)">
                                 <img
                                   src="../assets/icon/comment/comment.png"
@@ -1628,7 +1669,11 @@
                     >
                       <div
                         class="works"
-                        style="width: 200px; height: 140px; padding: 25px 0"
+                        style="
+                          width: 200px;
+                          height: 140px;
+                          margin: 10px 10px 10px 0;
+                        "
                         v-for="(w, wIndex) in worksStudent[toolIndex]"
                         :key="wIndex"
                       >
@@ -1659,7 +1704,7 @@
                               </div>
                               <div>{{ w.likesCount }}</div>
                             </div>
-                            <div class="commentList">
+                            <div class="commentList" style="margin-right: 15px">
                               <div class="commentImg" @click="commentOther(w)">
                                 <img
                                   src="../assets/icon/comment/comment.png"
@@ -1709,7 +1754,11 @@
                     >
                       <div
                         class="works"
-                        style="width: 200px; height: 140px; padding: 25px 0"
+                        style="
+                          width: 200px;
+                          height: 140px;
+                          margin: 10px 10px 10px 0;
+                        "
                         v-for="(w, wIndex) in worksStudent[toolIndex]"
                         :key="wIndex"
                       >
@@ -1740,7 +1789,7 @@
                               </div>
                               <div>{{ w.likesCount }}</div>
                             </div>
-                            <div class="commentList">
+                            <div class="commentList" style="margin-right: 15px">
                               <div class="commentImg" @click="commentOther(w)">
                                 <img
                                   src="../assets/icon/comment/comment.png"
@@ -1825,6 +1874,144 @@
                       </div>
                     </div>
                   </div>
+                  <div
+                    v-if="
+                      tType &&
+                      ((tType == 2 && sIsOpen == true) || tType == 1) &&
+                      tool.tool.indexOf(40) != -1
+                    "
+                    class="worksBox"
+                  >
+                    <div
+                      style="padding-top: 15px; font-size: 18px"
+                      v-if="
+                        worksStudent.length &&
+                        worksStudent[toolIndex].length > 0
+                      "
+                    >
+                      作业预览
+                    </div>
+                    <div
+                      class="worksDetailBox"
+                      v-if="
+                        worksStudent.length &&
+                        worksStudent[toolIndex].length > 0
+                      "
+                    >
+                      <div
+                        class="works"
+                        v-for="(w, wIndex) in worksStudent[toolIndex]"
+                        :key="wIndex"
+                      >
+                        <div
+                          class="workImg"
+                          style="
+                            border-radius: 15px;
+                            box-shadow: 0px 0px 10px 10px #f2f2f2;
+                          "
+                        >
+                          <!-- <img
+                            src="../assets/icon/works/noImg.png"
+                            @click="openTools(15, toolIndex, taskCount, w.works)"
+                            alt=""
+                          />-->
+                          <div
+                            class="answerBg"
+                            style="border-radius: 15px 15px 0 0"
+                          >
+                            <div>{{ w.sName }}</div>
+                            <el-tooltip
+                              class="item"
+                              effect="light"
+                              :content="w.works"
+                              placement="top"
+                            >
+                              <div class="answerContent">
+                                {{ w.works }}
+                              </div>
+                            </el-tooltip>
+                          </div>
+                          <div class="comment">
+                            <div class="commentList">
+                              <div
+                                class="commentImg"
+                                @click="
+                                  isLikes(w.wid, userid, 1, null, w.isLikes)
+                                "
+                              >
+                                <img
+                                  :src="w.isLikes == true ? likes : noLikes"
+                                  alt=""
+                                />
+                              </div>
+                              <div>{{ w.likesCount }}</div>
+                            </div>
+                            <div class="commentList" style="margin-right: 15px">
+                              <div class="commentImg" @click="commentOther(w)">
+                                <img
+                                  src="../assets/icon/comment/comment.png"
+                                  alt=""
+                                />
+                              </div>
+                              <div>{{ w.commentCount }}</div>
+                            </div>
+                          </div>
+                        </div>
+                      </div>
+                    </div>
+                    <div style="padding-top: 15px; font-size: 18px">未提交</div>
+                    <div class="noWorksS">
+                      <div
+                        v-for="(s, sIndex) in noWorksS[toolIndex]"
+                        :key="sIndex"
+                        class="noWorksName"
+                      >
+                        {{ s.student }}
+                      </div>
+                    </div>
+                  </div>
+                  <div
+                    v-if="tType && tType == 2 && tool.tool.indexOf(40) != -1"
+                    class="worksBox"
+                  >
+                    <div
+                      style="padding-top: 15px; font-size: 18px"
+                      v-if="workStudent[toolIndex].length > 0"
+                    >
+                      作业预览
+                    </div>
+                    <div
+                      class="worksDetailBox"
+                      v-if="workStudent[toolIndex].length > 0"
+                    >
+                      <div
+                        class="works"
+                        v-for="(w, wIndex) in workStudent[toolIndex]"
+                        :key="wIndex"
+                      >
+                        <div class="workImg">
+                          <!-- <img
+                            src="../assets/icon/works/noImg.png"
+                            @click="openTools(15, toolIndex, taskCount, w.works)"
+                            alt=""
+                          />-->
+                          <div class="answerBg">
+                            <div>{{ w.sName }}</div>
+                            <el-tooltip
+                              class="item"
+                              effect="light"
+                              :content="w.works"
+                              placement="top"
+                            >
+                              <div class="answerContent">
+                                {{ w.works }}
+                              </div>
+                            </el-tooltip>
+                          </div>
+                        </div>
+                      </div>
+                    </div>
+                  </div>
                 </div>
                 <!-- <div class="upload_toolBtn" @click="addImg($event)">
                   上传文件
@@ -2542,6 +2729,12 @@
             style="width: 90%; height: 100%; margin: 0 0 0 30px"
           ></video-player>
         </div>
+        <div
+          class="worksAnswer"
+          v-if="commentDetail.works && commentDetail.type == 4"
+        >
+          {{ commentDetail.works }}
+        </div>
         <div class="comment">
           <div class="commentList">
             <div class="commentImg">
@@ -2685,6 +2878,48 @@
         <el-button @click="fullDialogVisible = false">关 闭</el-button>
       </div> -->
     </el-dialog>
+    <el-dialog
+      title="学生评价"
+      :visible.sync="studentEvalDialogVisible"
+      :append-to-body="true"
+      width="800px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <div class="evalCss">
+        <div class="nav">请选择星星进行评分</div>
+        <div class="middleBox">
+          <div class="pfBox" v-for="(e,eIndex) in rateJson" :key="eIndex">
+            <div class="nameAndrate">
+              <div>{{ e.value }} </div>
+              <el-rate v-model="e.score" disabled></el-rate>
+            </div>
+            <div>{{ e.detail }}</div>
+          </div>
+          <div class="bz">
+            <div>备注</div>
+            <textarea
+              rows="4"
+              class="pj"
+              style="
+                padding: 10px 5px;
+                width: 70%;
+                background: #f7f6f9;
+                font-size: 14px;
+                text-indent: 10px;
+              "
+              cols
+              v-model="bzText"
+              placeholder="请输入评价内容..."
+            ></textarea>
+          </div>
+        </div>
+      </div>
+      <div slot="footer">
+        <el-button @click="studentEvalDialogVisible = false">取 消</el-button>
+        <el-button type="primary" @click="addBzWorks">确 定</el-button>
+      </div>
+    </el-dialog>
   </div>
 </template>
 
@@ -2704,6 +2939,8 @@ export default {
       dialogVisible: false,
       commentDialogVisible: false,
       videoVisible: false,
+      studentEvalDialogVisible: false,
+      bzText:"",
       commentDetail: [],
       videoDetail: {},
       id: this.$route.query.courseId,
@@ -2812,6 +3049,7 @@ export default {
       progress: 0,
       questionAnswer: "",
       answerQ: "", //问答标题
+      rateJson: [],
       wbCount: 0,
       wordCount: 0,
       mindCount: 0,
@@ -2823,6 +3061,7 @@ export default {
       timeCount: 0,
       answerCount: 0,
       trainCount: 0,
+      evalCount: 0,
       dialogImageUrl: "",
       pictureDialog: false,
       toolTypeList: [],
@@ -3328,7 +3567,7 @@ export default {
                   }
                 }
                 if (
-                  (b[j].type == 1 || b[j].type == 4 || b[j].type == 5) &&
+                  (b[j].type == 1 || b[j].type == 4 || b[j].type == 5 || b[j].type == 6) &&
                   a[i].tool[0] != 15 &&
                   a[i].tool[0] != 4
                 ) {
@@ -3368,6 +3607,18 @@ export default {
                       isLikes: isLikes,
                       commentJson: commentJson,
                     });
+                  }else if(b[j].type == 6){
+                    this.worksStudent[i].push({
+                      wid: b[j].id,
+                      works: b[j].content,
+                      sName: b[j].name,
+                      type: 4,
+                      time: b[j].time,
+                      likesCount: likesCount,
+                      commentCount: commentCount,
+                      isLikes: isLikes,
+                      commentJson: commentJson,
+                    });
                   } else {
                     this.worksStudent[i].push({
                       wid: b[j].id,
@@ -4254,6 +4505,33 @@ export default {
     openAddWork() {
       this.dialogVisible = true;
     },
+    addBzWorks(){
+      let params = [
+        {
+          uid: this.userid,
+          cid: this.id,
+          stage: this.courseType,
+          task: this.taskCount,
+          tool: this.toolindex,
+          content: this.bzText,
+          type: 6,
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "addCourseWorks", params)
+        .then((res) => {
+          this.$message({
+            message: "提交成功",
+            type: "success",
+          });
+          this.bzText = "";
+          this.studentEvalDialogVisible = false;
+        })
+        .catch((err) => {
+          this.$message.error("提交失败");
+          console.error(err);
+        });
+    },
     addStudentAsk() {
       this.askList.push({ askJson: this.askJson, anwer: this.radio.join(",") });
       let params = [
@@ -4650,6 +4928,19 @@ export default {
           },
           "*"
         );
+      } else if (t == 40) {
+        if (this.evalCount > 0) {
+          this.updateCount(this.evalCount, t);
+        } else {
+          this.evalCount++;
+          a = this.evalCount;
+          this.toolsCount(a, t);
+        }
+        this.rateJson =
+          this.chapInfoList[this.courseType].chapterInfo[0].taskJson[
+            index
+          ].toolChoose[i].rateJson;
+        this.studentEvalDialogVisible = true;
       }
     },
     toolsCount(a, t) {
@@ -5880,7 +6171,7 @@ export default {
   flex-wrap: wrap;
   align-items: center;
   justify-content: flex-start;
-  padding-top: 30px;
+  padding: 30px 0;
 }
 .works {
   display: flex;
@@ -5898,7 +6189,7 @@ export default {
 .workImg {
   width: 100%;
   /* height: calc(100% - 40px); */
-  height: calc(100%);
+  height: 105px;
 }
 .workImg > img {
   width: 100%;
@@ -6411,4 +6702,46 @@ export default {
   align-items: baseline;
   color: #78787a;
 }
+.evalCss {
+  background: #fff;
+  font-size: 18px;
+}
+.nav {
+  color: #9d9d9d;
+  padding: 5px 0 15px 20px;
+}
+.middleBox {
+  padding: 5px 0 15px 20px;
+}
+.pfBox {
+  padding-bottom: 30px;
+}
+.nameAndrate {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: center;
+  padding-bottom: 10px;
+}
+.nameAndrate > div {
+  margin-left: 10px;
+}
+.pfBox > div:nth-child(2) {
+  background: #f7f6f9;
+  width: 400px;
+  height: 45px;
+  border-radius: 10px;
+  text-indent: 18px;
+  line-height: 45px;
+  font-size: 16px;
+}
+.bz {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: flex-start;
+}
+.bz > div {
+  padding: 0 10px;
+}
 </style>