Browse Source

Merge branch 'startLogin'

mo 1 year ago
parent
commit
d0182100f9
3 changed files with 20 additions and 5 deletions
  1. 2 2
      dev-dist/sw.js
  2. 17 2
      src/views/classList/index.tsx
  3. 1 1
      vite.config.ts

+ 2 - 2
dev-dist/sw.js

@@ -79,10 +79,10 @@ define(['./workbox-5357ef54'], (function (workbox) { 'use strict';
    */
   workbox.precacheAndRoute([{
     "url": "registerSW.js",
-    "revision": "b17c881594570d5574b0e0d280c3df6d"
+    "revision": "6137f3202e711e407da62c90631d3729"
   }, {
     "url": "index.html",
-    "revision": "0.ab482jjgat8"
+    "revision": "0.4248ndag8lg"
   }], {});
   workbox.cleanupOutdatedCaches();
   workbox.registerRoute(new workbox.NavigationRoute(workbox.createHandlerBoundToURL("index.html"), {

+ 17 - 2
src/views/classList/index.tsx

@@ -29,6 +29,7 @@ import TheEmpty from '/src/components/TheEmpty';
 import TheTooltip from '/src/components/TheTooltip';
 import PreviewWindow from '../preview-window';
 import { state as globalState } from '/src/state';
+import {courseSchedulePage} from '../home/api'
 export default defineComponent({
   name: 'class-classList',
   setup(props, { emit }) {
@@ -55,7 +56,8 @@ export default defineComponent({
       removeVisiable: false,
       removeRow: {} as any,
       previewModal: false,
-      previewParams: {} as any
+      previewParams: {} as any,
+      lastCourse:null as any
     });
     const formRef = ref();
     const dialog = useDialog();
@@ -237,7 +239,20 @@ export default defineComponent({
       state.studentVisible = true;
     };
 
-    const classesBegin = (row: any) => {
+    const classesBegin = async(row: any) => {
+       try{
+        const res = await courseSchedulePage({"classGroupId": row.id})
+      if(res.data.rows.length>0){
+        state.lastCourse = res.data.rows[0]
+        console.log(state.lastCourse,'state.lastCourse')
+      }else{
+        state.lastCourse = null
+      }
+        console.log(res)
+        // const lastCorse =
+       }catch(e){
+        console.log(e)
+       }
       state.activeRow = row;
       state.goCourseVisiable = true;
     };

+ 1 - 1
vite.config.ts

@@ -67,7 +67,7 @@ export default defineConfig({
         name: '酷乐秀-音乐数字课堂',
         short_name: '音乐数字课堂',
         theme_color: '#E8EAED',
-        display: 'standalone',
+        display: 'fullscreen',
         icons: [
           {
             src: './logo.png',