lex 1 vuosi sitten
vanhempi
commit
8c342f2b57

+ 3 - 1
src/constant/index.js

@@ -325,7 +325,9 @@ export const downListType = {
   33: "平衡关系-缴费项目课时明细",
   33: "平衡关系-缴费项目课时明细",
   34: "平衡关系-学员情况总表",
   34: "平衡关系-学员情况总表",
   35: "平衡关系(分表)-乐团在读学员",
   35: "平衡关系(分表)-乐团在读学员",
-  36: "平衡关系(分表)-乐团退团学员"
+  36: "平衡关系(分表)-乐团退团学员",
+  37: "视频观看统计",
+  38: "视频观看详情统计"
 };
 };
 
 
 export const withdrawalStatus = {
 export const withdrawalStatus = {

+ 13 - 12
src/views/main/coursewareDate/exerciseDuration.vue

@@ -176,18 +176,19 @@ import dayjs from "dayjs";
 import histogram from "v-charts/lib/histogram.common";
 import histogram from "v-charts/lib/histogram.common";
 import { getNowDateAndMonday, getNowDateAndSunday } from "@/utils/utils";
 import { getNowDateAndMonday, getNowDateAndSunday } from "@/utils/utils";
 import { api_studentCoursewarePlayRecordList } from "../api";
 import { api_studentCoursewarePlayRecordList } from "../api";
+import { getTimeFormat } from "@/utils";
 let nowTime = dayjs()
 let nowTime = dayjs()
   .subtract(1, "day")
   .subtract(1, "day")
   .format("YYYY-MM-DD");
   .format("YYYY-MM-DD");
-export const getTimes = (times, keys = []) => {
-  if (times && times.length) {
-    return {
-      [keys[0] || "start"]: dayjs(times[0]).format("YYYY-MM-DD"),
-      [keys[1] || "start"]: dayjs(times[1]).format("YYYY-MM-DD")
-    };
-  }
-  return {};
-};
+// export const getTimeFormat = (times, keys = []) => {
+//   if (times && times.length) {
+//     return {
+//       [keys[0] || "start"]: dayjs(times[0]).format("YYYY-MM-DD"),
+//       [keys[1] || "start"]: dayjs(times[1]).format("YYYY-MM-DD")
+//     };
+//   }
+//   return {};
+// };
 export default {
 export default {
   components: { saveform, "ve-histogram": histogram },
   components: { saveform, "ve-histogram": histogram },
   name: "helpCategory",
   name: "helpCategory",
@@ -243,9 +244,9 @@ export default {
           fileName: "云课堂观看统计.xls",
           fileName: "云课堂观看统计.xls",
           method: "post",
           method: "post",
           params: {
           params: {
-            // exportEnum: "EXPORT_CLOUD_TEACHER_SUM",
+            exportEnum: "VIDEO_PLAY_STAT",
             queryInfo: {
             queryInfo: {
-              ...getTimes(dates, ["startDate", "endDate"])
+              ...getTimeFormat(dates, ["startTime", "endTime"])
             }
             }
           }
           }
         },
         },
@@ -309,7 +310,7 @@ export default {
         let params = {
         let params = {
           sort,
           sort,
           asc,
           asc,
-          ...getTimes(dates, ["startDate", "endDate"])
+          ...getTimeFormat(dates, ["startTime", "endTime"])
         };
         };
         const res = await api_studentCoursewarePlayRecordList({
         const res = await api_studentCoursewarePlayRecordList({
           page: 1,
           page: 1,

+ 13 - 11
src/views/main/coursewareDate/exerciseDurationDetail.vue

@@ -191,6 +191,7 @@ import dayjs from "dayjs";
 import histogram from "v-charts/lib/histogram.common";
 import histogram from "v-charts/lib/histogram.common";
 import { getNowDateAndMonday, getNowDateAndSunday } from "@/utils/utils";
 import { getNowDateAndMonday, getNowDateAndSunday } from "@/utils/utils";
 import { api_studentCoursewarePlayRecordDetail } from "../api";
 import { api_studentCoursewarePlayRecordDetail } from "../api";
+import { getTimeFormat } from "@/utils";
 let nowTime = new Date();
 let nowTime = new Date();
 nowTime =
 nowTime =
   nowTime.getFullYear() +
   nowTime.getFullYear() +
@@ -198,15 +199,15 @@ nowTime =
   (nowTime.getMonth() + 1) +
   (nowTime.getMonth() + 1) +
   "-" +
   "-" +
   nowTime.getDate();
   nowTime.getDate();
-export const getTimes = (times, keys = []) => {
-  if (times && times.length) {
-    return {
-      [keys[0] || "start"]: dayjs(times[0]).format("YYYY-MM-DD"),
-      [keys[1] || "start"]: dayjs(times[1]).format("YYYY-MM-DD")
-    };
-  }
-  return {};
-};
+// export const getTimes = (times, keys = []) => {
+//   if (times && times.length) {
+//     return {
+//       [keys[0] || "start"]: dayjs(times[0]).format("YYYY-MM-DD"),
+//       [keys[1] || "start"]: dayjs(times[1]).format("YYYY-MM-DD")
+//     };
+//   }
+//   return {};
+// };
 export default {
 export default {
   components: { saveform, "ve-histogram": histogram, pagination },
   components: { saveform, "ve-histogram": histogram, pagination },
   name: "helpCategory",
   name: "helpCategory",
@@ -292,8 +293,9 @@ export default {
           fileName: "云练习练习时长.xls",
           fileName: "云练习练习时长.xls",
           method: "post",
           method: "post",
           params: {
           params: {
+            exportEnum: "VIDEO_PLAY_DETAIL_STAT",
             queryInfo: {
             queryInfo: {
-              ...getTimes(dates, ["startDate", "endDate"]),
+              ...getTimeFormat(dates, ["startTime", "endTime"]),
               organizationId: organId,
               organizationId: organId,
               asc,
               asc,
               sort
               sort
@@ -354,7 +356,7 @@ export default {
         let params = {
         let params = {
           sort,
           sort,
           asc,
           asc,
-          ...getTimes(dates, ["startDate", "endDate"]),
+          ...getTimeFormat(dates, ["startTime", "endTime"]),
           organId
           organId
         };
         };
         const res = await api_studentCoursewarePlayRecordDetail({
         const res = await api_studentCoursewarePlayRecordDetail({