Quellcode durchsuchen

fix 学生界面代码作业统计数据显示错误

靳炳淑 vor 6 Jahren
Ursprung
Commit
dcbe7af8a9

+ 4 - 1
src/views/student/Code/ProjectDetail/Statistics.vue

@@ -102,7 +102,10 @@ export default {
   async mounted() {
     const { homeworkId, courseId } = this.$route.params;
     const groupId = await getStudentGroup(courseId);
-    const statistics = await getCodeWorkStatistics(homeworkId, groupId.data.id);
+    const statistics = await getCodeWorkStatistics(
+      homeworkId,
+      groupId.data[0].id
+    );
     console.log(statistics);
     this.statistics = statistics.data;
     this.buildChartDOM = document.getElementById("build-chart");

+ 1 - 0
src/views/teacher/Code/test.vue

@@ -77,6 +77,7 @@ export default {
     this.detailLoading = true;
     const detail = await getProjectDetail(projectId);
     this.projectDetail = detail.data;
+    console.log("DETAIL", this.projectDetail);
     this.detailLoading = false;
   }
 };

+ 2 - 1
vue.config.js

@@ -2,10 +2,11 @@ module.exports = {
   devServer: {
     proxy: {
       "^/api": {
-        target: "http://localhost:4000/",
+        // target: "http://localhost:4000/",
         // target: "http://10.1.1.198:8080/",
         // target: "http://192.168.0.100:8080",
         // target: "http://seec.yangshan.tech",
+        target: "http://seec.seecoder.cn",
 
         ws: true,
         changeOrigin: true