Quellcode durchsuchen

Merge branch 'refs/heads/20240604-dev' into 20240904-zyy

# Conflicts:
#	src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskVisualTraining/index.vue
周玉佂 vor 5 Tagen
Ursprung
Commit
9015b854d1
12 geänderte Dateien mit 45 neuen und 53 gelöschten Zeilen
  1. BIN
      public/static/image/cognitiveAbility/SpeechTraining/Visual/书包.png
  2. BIN
      public/static/image/cognitiveAbility/SpeechTraining/Visual/小草.png
  3. BIN
      public/static/image/cognitiveAbility/SpeechTraining/Visual/松树.png
  4. BIN
      public/static/image/cognitiveAbility/SpeechTraining/Visual/牛奶.png
  5. 3 5
      src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskAuditoryTraining/index.vue
  6. 3 6
      src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskOralExpression/index.vue
  7. 8 8
      src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskVisualTraining/components/Words/index.vue
  8. 2 2
      src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskVisualTraining/components/Words/topics.json
  9. 8 8
      src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskVisualTraining/components/diagramMap/index.vue
  10. 8 5
      src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskVisualTraining/components/essay/index.vue
  11. 8 8
      src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskVisualTraining/components/mapWord/index.vue
  12. 5 11
      src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskVisualTraining/index.vue

BIN
public/static/image/cognitiveAbility/SpeechTraining/Visual/书包.png


BIN
public/static/image/cognitiveAbility/SpeechTraining/Visual/小草.png


BIN
public/static/image/cognitiveAbility/SpeechTraining/Visual/松树.png


BIN
public/static/image/cognitiveAbility/SpeechTraining/Visual/牛奶.png


+ 3 - 5
src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskAuditoryTraining/index.vue

@@ -235,12 +235,8 @@ const startTask = useThrottleFn(() => {
   if (modeSelect.value === 0) {
     checkItems.value[modeCurrentIndex].isTraining = true
   } else {
-    // let tempIndex = checkItems.value.findIndex((item: CheckItem) => item.active && !item.isTraining && !item.isFinish)
-    // checkItems.value[tempIndex].isTraining = true
     let tempIndex = checkItems.value.findIndex((item: CheckItem) => item.active && !item.isTraining && !item.isFinish)
-    checkItems.value.forEach((item, index) => {
-      item.isTraining = tempIndex === index
-    })
+    checkItems.value[tempIndex].isTraining = true
   }
   taskBegin.value = true
   if (!isMainWin.value) {
@@ -337,6 +333,8 @@ onMounted(() => {
 
       if (val.key === 'tow-win-auditory-change-status') {
         checkItems.value[modeCurrentIndex].isFinish = true
+        modeCurrentIndex++
+        startTask()
         localStorage.removeItem('tow-win-auditory-change-status')
       }
     } else {

+ 3 - 6
src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskOralExpression/index.vue

@@ -222,11 +222,7 @@ const startTask = useThrottleFn(() => {
     checkItems.value[modeCurrentIndex].isTraining = true
   } else {
     let tempIndex = checkItems.value.findIndex((item: CheckItem) => item.active && !item.isTraining && !item.isFinish)
-    checkItems.value.forEach((item, index) => {
-      item.isTraining = tempIndex === index
-    })
-    // let tempIndex = checkItems.value.findIndex((item: CheckItem) => item.active && !item.isTraining && !item.isFinish)
-    // checkItems.value[tempIndex].isTraining = true
+    checkItems.value[tempIndex].isTraining = true
   }
   taskBegin.value = true
   if (!isMainWin.value) {
@@ -323,7 +319,8 @@ onMounted(() => {
 
       if (val.key === 'tow-win-auditory-change-status') {
         checkItems.value[modeCurrentIndex].isFinish = true
-        childTaskOver(JSON.parse(val.newValue!))
+        modeCurrentIndex++
+        startTask()
         localStorage.removeItem('tow-win-auditory-change-status')
       }
     } else {

+ 8 - 8
src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskVisualTraining/components/Words/index.vue

@@ -221,18 +221,18 @@ onMounted(() => {
         showTopics.value = true
         currentIndex.value = Number(val.newValue!)
         useClickIndex.value = -1
-        VoiceImpRef.value.videoPlay(
-          'Speech-Auditory',
-          `static/voice/cognitiveAbility/SpeechTraining/Auditory/SentenceImgMatching/${TopicsVal.value[currentIndex.value].correct}.mp3`
-        )
+        // VoiceImpRef.value.videoPlay(
+        //   'Speech-Auditory',
+        //   `static/voice/cognitiveAbility/SpeechTraining/Auditory/SentenceImgMatching/${TopicsVal.value[currentIndex.value].correct}.mp3`
+        // )
         localStorage.removeItem('tow-win-auditory-sentence-img-matching-show-topics')
       }
 
       if (val.key === 'two-win-auditory-sentence-img-matching-item-check') {
-        VoiceImpRef.value.videoPlay(
-          'Speech-Auditory',
-          `static/voice/cognitiveAbility/SpeechTraining/Auditory/SentenceImgMatching/${val.newValue}.mp3`
-        )
+        // VoiceImpRef.value.videoPlay(
+        //   'Speech-Auditory',
+        //   `static/voice/cognitiveAbility/SpeechTraining/Auditory/SentenceImgMatching/${val.newValue}.mp3`
+        // )
         localStorage.removeItem('two-win-auditory-sentence-img-matching-item-check')
       }
 

+ 2 - 2
src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskVisualTraining/components/Words/topics.json

@@ -11,7 +11,7 @@
     },
     {
       "choices": ["是", "不是"],
-      "correct": "是",
+      "correct": "是",
       "Tips": "",
       "Topic": "开的花是红色的吗?",
       "userAnswer": ""
@@ -25,7 +25,7 @@
     },
     {
       "choices": ["是", "不是"],
-      "correct": "是",
+      "correct": "是",
       "Tips": "",
       "Topic": "花生会在冬天结果吗?",
       "userAnswer": ""

+ 8 - 8
src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskVisualTraining/components/diagramMap/index.vue

@@ -201,18 +201,18 @@ onMounted(() => {
         showTopics.value = true
         currentIndex.value = Number(val.newValue!)
         useClickIndex.value = -1
-        VoiceImpRef.value.videoPlay(
-          'Speech-Auditory',
-          `static/voice/cognitiveAbility/SpeechTraining/Auditory/SentenceImgMatching/${TopicsVal.value[currentIndex.value].correct}.mp3`
-        )
+        // VoiceImpRef.value.videoPlay(
+        //   'Speech-Auditory',
+        //   `static/voice/cognitiveAbility/SpeechTraining/Auditory/SentenceImgMatching/${TopicsVal.value[currentIndex.value].correct}.mp3`
+        // )
         localStorage.removeItem('tow-win-auditory-sentence-img-matching-show-topics')
       }
 
       if (val.key === 'two-win-auditory-sentence-img-matching-item-check') {
-        VoiceImpRef.value.videoPlay(
-          'Speech-Auditory',
-          `static/voice/cognitiveAbility/SpeechTraining/Auditory/SentenceImgMatching/${val.newValue}.mp3`
-        )
+        // VoiceImpRef.value.videoPlay(
+        //   'Speech-Auditory',
+        //   `static/voice/cognitiveAbility/SpeechTraining/Auditory/SentenceImgMatching/${val.newValue}.mp3`
+        // )
         localStorage.removeItem('two-win-auditory-sentence-img-matching-item-check')
       }
 

+ 8 - 5
src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskVisualTraining/components/essay/index.vue

@@ -236,7 +236,10 @@ const handleSubmit = () => {
     return
   }
   VoiceImpRef.value.videoPlay(
-    TopicsVal.value[currentIndex.value].userAnswer === TopicsVal.value[currentIndex.value].correct ? 'right' : 'error'
+    TopicsVal.value[currentIndex.value].userAnswer === TopicsVal.value[currentIndex.value].correct[0] ||
+      TopicsVal.value[currentIndex.value].userAnswer === TopicsVal.value[currentIndex.value].correct[1]
+      ? 'right'
+      : 'error'
   )
   showSubmitBtn.value = false
   localStorage.setItem('two-win-auditory-word-img-matching-try-over', 'YES')
@@ -302,10 +305,10 @@ onMounted(() => {
         showScoreArea.value = false
         scoreIndex.value = -1
         tipsFlag.value = false
-        VoiceImpRef.value.videoPlay(
-          'Speech-Auditory',
-          `static/voice/cognitiveAbility/SpeechTraining/Auditory/WordImgMatching/${TopicsVal.value[currentIndex.value].correct}.mp3`
-        )
+        // VoiceImpRef.value.videoPlay(
+        //   'Speech-Auditory',
+        //   `static/voice/cognitiveAbility/SpeechTraining/Auditory/WordImgMatching/${TopicsVal.value[currentIndex.value].correct}.mp3`
+        // )
         localStorage.removeItem('tow-win-auditory-word-img-matching-show-topics')
       }
 

+ 8 - 8
src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskVisualTraining/components/mapWord/index.vue

@@ -207,18 +207,18 @@ onMounted(() => {
         showTopics.value = true
         currentIndex.value = Number(val.newValue!)
         useClickIndex.value = -1
-        VoiceImpRef.value.videoPlay(
-          'Speech-Auditory',
-          `static/voice/cognitiveAbility/SpeechTraining/Auditory/SentenceImgMatching/${TopicsVal.value[currentIndex.value].correct}.mp3`
-        )
+        // VoiceImpRef.value.videoPlay(
+        //   'Speech-Auditory',
+        //   `static/voice/cognitiveAbility/SpeechTraining/Auditory/SentenceImgMatching/${TopicsVal.value[currentIndex.value].correct}.mp3`
+        // )
         localStorage.removeItem('tow-win-auditory-sentence-img-matching-show-topics')
       }
 
       if (val.key === 'two-win-auditory-sentence-img-matching-item-check') {
-        VoiceImpRef.value.videoPlay(
-          'Speech-Auditory',
-          `static/voice/cognitiveAbility/SpeechTraining/Auditory/SentenceImgMatching/${val.newValue}.mp3`
-        )
+        // VoiceImpRef.value.videoPlay(
+        //   'Speech-Auditory',
+        //   `static/voice/cognitiveAbility/SpeechTraining/Auditory/SentenceImgMatching/${val.newValue}.mp3`
+        // )
         localStorage.removeItem('two-win-auditory-sentence-img-matching-item-check')
       }
 

+ 5 - 11
src/views/tester/components/RehabilitationEvaluation/CognitiveAbilityTask/CognitiveAbilityTaskVisualTraining/index.vue

@@ -232,21 +232,14 @@ const modeSelectFn = useThrottleFn((mode: number, flag: number = 0) => {
 })
 
 const startTask = useThrottleFn(() => {
-  let tempIndex = checkItems.value.findIndex((item: CheckItem) => item.active && !item.isTraining && !item.isFinish)
-
   if (modeSelect.value === 0) {
     checkItems.value[modeCurrentIndex].isTraining = true
   } else {
-    // let tempIndex = checkItems.value.findIndex((item: CheckItem) => item.active && !item.isTraining && !item.isFinish)
-    // checkItems.value[tempIndex].isTraining = true
-    console.log(tempIndex, 'tempIndex241')
-    checkItems.value.forEach((item, index) => {
-      item.isTraining = tempIndex === index
-    })
+    let tempIndex = checkItems.value.findIndex((item: CheckItem) => item.active && !item.isTraining && !item.isFinish)
+    checkItems.value[tempIndex].isTraining = true
   }
   taskBegin.value = true
   if (!isMainWin.value) {
-    console.log(tempIndex, 'tempIndex248')
     localStorage.setItem('two-win-auditory-task-begin', 'YES')
   }
 })
@@ -297,7 +290,7 @@ const countDownEnd = () => {
   countDownBegin.value = false
   showCountDown.value = false
   if (!isMainWin.value) {
-    VoiceImpRef.value.videoPlay('Speech-Auditory', 'static/voice/cognitiveAbility/SpeechTraining/Auditory/1.mp3')
+    // VoiceImpRef.value.videoPlay('Speech-Auditory', 'static/voice/cognitiveAbility/SpeechTraining/Auditory/1.mp3')
   }
 }
 
@@ -339,7 +332,8 @@ onMounted(() => {
 
       if (val.key === 'tow-win-auditory-change-status') {
         checkItems.value[modeCurrentIndex].isFinish = true
-        childTaskOver(JSON.parse(val.newValue!))
+        modeCurrentIndex++
+        startTask()
         localStorage.removeItem('tow-win-auditory-change-status')
       }
     } else {