lsc 1 年之前
父节点
当前提交
42dd731149

+ 28 - 2
src/components/pages/dataBoardNew/course/index.vue

@@ -1,5 +1,5 @@
 <template>
-  <div class="body1">
+  <div class="body1" v-loading="isLoading">
     <!-- 课程数据 -->
     <div class="left">
       <div class="top">
@@ -385,6 +385,7 @@ export default {
   },
   data() {
     return {
+      isLoading:false,
       cType: "全部年级",
       cType1: "全部年级",
       cType2: "全部学科",
@@ -403,7 +404,9 @@ export default {
       xtType: false,
     };
   },
-  mounted() {},
+  mounted() {
+    this.getData()
+  },
   methods: {
     otherEchart() {
       this.oType = !this.oType;
@@ -414,6 +417,29 @@ export default {
     xtEchart(){
       this.xtType = !this.xtType;
     },
+    getData() {
+      this.isLoading = true;
+      let params = [
+        {
+          oid: this.oid,
+          org: this.org,
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "selectDataBoardCourseNew", params)
+        .then((res) => {
+          this.isLoading = false;
+          let _grade = res.data[0] //年级
+          let _subject = res.data[1]  //学科
+          let _course = res.data[2] //课程
+
+          this.$forceUpdate();
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
   },
 };
 </script>

+ 27 - 2
src/components/pages/dataBoardNew/project/index.vue

@@ -1,5 +1,5 @@
 <template>
-  <div class="body1">
+  <div class="body1" v-loading="isLoading">
     <!-- 课程数据 -->
     <div class="left">
       <div class="top">
@@ -331,6 +331,7 @@ export default {
   },
   data() {
     return {
+      isLoading:false,
       cType: "全部年级",
       cType1: "全部年级",
       cType2: "全部学科",
@@ -351,7 +352,9 @@ export default {
       xtType: false,
     };
   },
-  mounted() {},
+  mounted() {
+    this.getData();
+  },
   methods: {
     otherEchart() {
       this.oType = !this.oType;
@@ -362,6 +365,28 @@ export default {
     xtEchart() {
       this.xtType = !this.xtType;
     },
+    getData() {
+      this.isLoading = true;
+      let params = [
+        {
+          oid: this.oid,
+          org: this.org,
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "selectDataBoardStudentCourseNew", params)
+        .then((res) => {
+          this.isLoading = false;
+          let _grade = res.data[0] //赛道
+          let _subject = res.data[1]  //主题
+
+          this.$forceUpdate();
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
   },
 };
 </script>

+ 27 - 1
src/components/pages/dataBoardNew/school/index.vue

@@ -414,6 +414,7 @@ export default {
   },
   data() {
     return {
+      isLoading:false,
       cType: "全部",
       cType1: "全部年级",
       cType2: "全部活动",
@@ -428,7 +429,9 @@ export default {
       shType: false,
     };
   },
-  mounted() {},
+  mounted() {
+    this.getData();
+  },
   methods: {
     otherEchart() {
       this.oType = !this.oType;
@@ -436,6 +439,29 @@ export default {
     shEchart() {
       this.shType = !this.shType;
     },
+    getData() {
+      this.isLoading = true;
+      let params = [
+        {
+          oid: this.oid,
+          org: this.org,
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "selectDataBoardSchoolNew", params)
+        .then((res) => {
+          this.isLoading = false;
+          let _grade = res.data[0] //年级
+          let _subject = res.data[1]  //学科
+          let _course = res.data[2] //课程
+
+          this.$forceUpdate();
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
   },
 };
 </script>

+ 28 - 2
src/components/pages/dataBoardNew/student/index.vue

@@ -1,5 +1,5 @@
 <template>
-  <div class="body1">
+  <div class="body1" v-loading="isLoading">
     <!-- 学生数据 -->
     <div class="left">
       <div class="top">
@@ -362,6 +362,7 @@ export default {
   },
   data() {
     return {
+      isLoading:false,
       skType: 0,
       tType: 0,
       courseType: 0,
@@ -381,11 +382,36 @@ export default {
       oType: false,
     };
   },
-  mounted() {},
+  mounted() {
+    this.getData();
+  },
   methods: {
     otherEchart() {
       this.oType = !this.oType;
     },
+    getData() {
+      this.isLoading = true;
+      let params = [
+        {
+          oid: this.oid,
+          org: this.org,
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "selectDataBoardStudentNew", params)
+        .then((res) => {
+          this.isLoading = false;
+          let _grade = res.data[0] //年级
+          let _subject = res.data[1]  //学科
+          let _course = res.data[2] //课程
+
+          this.$forceUpdate();
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
   },
 };
 </script>

+ 28 - 2
src/components/pages/dataBoardNew/teacher/index.vue

@@ -1,5 +1,5 @@
 <template>
-  <div class="body1">
+  <div class="body1" v-loading="isLoading">
     <!-- 教师数据 -->
     <div class="left">
       <div class="top">
@@ -389,6 +389,7 @@ export default {
   },
   data() {
     return {
+      isLoading:false,
       skType: 0,
       tType: 0,
       tType1: 0,
@@ -405,11 +406,36 @@ export default {
       oType: false,
     };
   },
-  mounted() {},
+  mounted() {
+    this.getData();
+  },
   methods: {
     otherEchart() {
       this.oType = !this.oType;
     },
+    getData() {
+      this.isLoading = true;
+      let params = [
+        {
+          oid: this.oid,
+          org: this.org,
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "selectDataBoardTeacherNew", params)
+        .then((res) => {
+          this.isLoading = false;
+          let _grade = res.data[0] //年级
+          let _subject = res.data[1]  //学科
+          let _course = res.data[2] //课程
+
+          this.$forceUpdate();
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
   },
 };
 </script>