ソースを参照

准备提交创建群聊

1
mo 1 年間 前
コミット
b4fde76ace

+ 34 - 44
dev-dist/sw.js

@@ -20,21 +20,23 @@ if (!self.define) {
   let nextDefineUri;
 
   const singleRequire = (uri, parentUri) => {
-    uri = new URL(uri + '.js', parentUri).href;
-    return (
-      registry[uri] ||
-      new Promise(resolve => {
-        if ('document' in self) {
-          const script = document.createElement('script');
-          script.src = uri;
-          script.onload = resolve;
-          document.head.appendChild(script);
-        } else {
-          nextDefineUri = uri;
-          importScripts(uri);
-          resolve();
-        }
-      }).then(() => {
+    uri = new URL(uri + ".js", parentUri).href;
+    return registry[uri] || (
+      
+        new Promise(resolve => {
+          if ("document" in self) {
+            const script = document.createElement("script");
+            script.src = uri;
+            script.onload = resolve;
+            document.head.appendChild(script);
+          } else {
+            nextDefineUri = uri;
+            importScripts(uri);
+            resolve();
+          }
+        })
+      
+      .then(() => {
         let promise = registry[uri];
         if (!promise) {
           throw new Error(`Module ${uri} didn’t register its module`);
@@ -45,10 +47,7 @@ if (!self.define) {
   };
 
   self.define = (depsNames, factory) => {
-    const uri =
-      nextDefineUri ||
-      ('document' in self ? document.currentScript.src : '') ||
-      location.href;
+    const uri = nextDefineUri || ("document" in self ? document.currentScript.src : "") || location.href;
     if (registry[uri]) {
       // Module is already loading or loaded.
       return;
@@ -60,16 +59,15 @@ if (!self.define) {
       exports,
       require
     };
-    registry[uri] = Promise.all(
-      depsNames.map(depName => specialDeps[depName] || require(depName))
-    ).then(deps => {
+    registry[uri] = Promise.all(depsNames.map(
+      depName => specialDeps[depName] || require(depName)
+    )).then(deps => {
       factory(...deps);
       return exports;
     });
   };
 }
-define(['./workbox-5357ef54'], function (workbox) {
-  'use strict';
+define(['./workbox-5357ef54'], (function (workbox) { 'use strict';
 
   self.skipWaiting();
   workbox.clientsClaim();
@@ -79,24 +77,16 @@ define(['./workbox-5357ef54'], function (workbox) {
    * requests for URLs in the manifest.
    * See https://goo.gl/S9QRab
    */
-  workbox.precacheAndRoute(
-    [
-      {
-        url: 'registerSW.js',
-        revision: '2ef9ea5f8ce5b3efb031d9c53700e57a'
-      },
-      {
-        url: 'index.html',
-        revision: '0.f2qovfbkdhg'
-      }
-    ],
-    {}
-  );
+  workbox.precacheAndRoute([{
+    "url": "registerSW.js",
+    "revision": "fbe553e78a1e04cfe0370756493c2178"
+  }, {
+    "url": "index.html",
+    "revision": "0.d5gsaiahvc"
+  }], {});
   workbox.cleanupOutdatedCaches();
-  workbox.strategies = 'NetworkOnly';
-  workbox.registerRoute(
-    new workbox.NavigationRoute(workbox.createHandlerBoundToURL('index.html'), {
-      allowlist: [/^\/$/]
-    })
-  );
-});
+  workbox.registerRoute(new workbox.NavigationRoute(workbox.createHandlerBoundToURL("index.html"), {
+    allowlist: [/^\/$/]
+  }));
+
+}));

+ 4 - 1
src/custom-plugins/guide-page/music-guide.tsx

@@ -49,7 +49,10 @@ export default defineComponent({
             top:7,
             width:14,
             height:14
-          }
+          },
+          boxStyle:{
+
+          },
         },
         {
           ele: '',

+ 4 - 1
src/views/classList/api.ts

@@ -160,7 +160,6 @@ export const getTrainingClassDetail = (params: any) => {
   });
 };
 
-
 /**
  * 学生练习记录
  */
@@ -169,3 +168,7 @@ export const getTrainingStatList = (params: any) => {
     data: params
   });
 };
+
+/***
+ * 创建班级群聊
+ */

+ 13 - 1
src/views/classList/index.tsx

@@ -124,7 +124,7 @@ export default defineComponent({
         {
           title: '学生人数',
           key: 'preStudentNum',
-          width: '25%'
+
         },
         {
           title: '上次学习',
@@ -227,6 +227,15 @@ export default defineComponent({
                       删除
                     </p>
                   ) : null}
+
+                    <NButton
+                      type="primary"
+                      text
+                      onClick={() => {
+                        createImgroup(row);
+                      }}>
+                      创建群聊
+                    </NButton>
                 </NSpace>
               </div>
             );
@@ -257,6 +266,9 @@ export default defineComponent({
       state.activeRow = row;
       state.goCourseVisiable = true;
     };
+    const createImgroup = async(row:any)=>{
+      console.log(row,'row')
+    }
     onMounted(() => {
       getList();
     });