Selaa lähdekoodia

Merge branch 'iteration-class'

lex 1 vuosi sitten
vanhempi
commit
386ffb7b80
2 muutettua tiedostoa jossa 17 lisäystä ja 10 poistoa
  1. 3 0
      src/views/attend-class/index.tsx
  2. 14 10
      src/views/preview-window/index.tsx

+ 3 - 0
src/views/attend-class/index.tsx

@@ -866,6 +866,7 @@ export default defineComponent({
           ]}
           onClick={async () => {
             if (data.type === 'preview') {
+              handleStop();
               if (state.application) {
                 emit('close');
               } else {
@@ -990,6 +991,7 @@ export default defineComponent({
               round
               onClick={() => {
                 data.modelAttendStatus = false;
+                handleStop();
                 if (state.application) {
                   emit('close');
                 } else {
@@ -1024,6 +1026,7 @@ export default defineComponent({
             onConfirm={() => {
               // 布置完作业之后直接关闭
               setTimeout(() => {
+                handleStop();
                 if (state.application) {
                   emit('close');
                 } else {

+ 14 - 10
src/views/preview-window/index.tsx

@@ -55,16 +55,20 @@ export default defineComponent({
           showIcon={false}
           displayDirective="show">
           <>
-            {type.value == 'attend' ? (
-              <AttendClass
-                type={params.value.type || ''}
-                subjectId={params.value.subjectId || ''}
-                detailId={params.value.detailId || ''}
-                classGroupId={params.value.classGroupId || ''}
-                onClose={() => emit('update:show', false)}
-              />
-            ) : type.value == 'notation' ? (
-              <iframe src={params.value.src}></iframe>
+            {show.value ? (
+              type.value == 'attend' ? (
+                <AttendClass
+                  type={params.value.type || ''}
+                  subjectId={params.value.subjectId || ''}
+                  detailId={params.value.detailId || ''}
+                  classGroupId={params.value.classGroupId || ''}
+                  onClose={() => emit('update:show', false)}
+                />
+              ) : type.value == 'notation' ? (
+                <iframe src={params.value.src}></iframe>
+              ) : (
+                ''
+              )
             ) : (
               ''
             )}