Browse Source

fix: 指法bug修复

TIANYONG 1 year ago
parent
commit
4b93d76599

+ 1 - 1
src/state.ts

@@ -1376,7 +1376,7 @@ const setState = (data: any, index: number) => {
   /**
   /**
    * 单曲,指法根据用户当前的乐器来显示,如果没有则取musicSheetSoundList第一个track
    * 单曲,指法根据用户当前的乐器来显示,如果没有则取musicSheetSoundList第一个track
    */
    */
-  let musicalCode = !storeData.user?.instrumentId ? data.musicSheetSoundList?.[0]?.track || '' : data.musicSheetSoundList?.find((item: any) => item?.musicalInstrumentId === storeData.user?.instrumentId)?.track || '';
+  let musicalCode = !storeData.user?.instrumentId ? data.musicSheetSoundList?.[0]?.track || '' : data.musicSheetSoundList?.find((item: any) => item?.musicalInstrumentId == storeData.user?.instrumentId)?.track || '';
   const pitchSubject = musicalInstrumentCodeInfo.find((n) => n.code.toLocaleLowerCase() === subjectCode.toLocaleLowerCase())
   const pitchSubject = musicalInstrumentCodeInfo.find((n) => n.code.toLocaleLowerCase() === subjectCode.toLocaleLowerCase())
   const pitchMusical = musicalInstrumentCodeInfo.find((n) => n.code.toLocaleLowerCase() === musicalCode.toLocaleLowerCase())
   const pitchMusical = musicalInstrumentCodeInfo.find((n) => n.code.toLocaleLowerCase() === musicalCode.toLocaleLowerCase())
   state.subjectCodeId = pitchSubject ? pitchSubject.id : 0
   state.subjectCodeId = pitchSubject ? pitchSubject.id : 0

File diff suppressed because it is too large
+ 0 - 0
src/view/fingering/fingering-img/hulusi-flute/index.json


+ 3 - 0
src/view/fingering/index.module.less

@@ -37,6 +37,9 @@
   //   background: linear-gradient(360deg, #FFFFFF 0%, rgba(255, 255, 255, 0) 100%);
   //   background: linear-gradient(360deg, #FFFFFF 0%, rgba(255, 255, 255, 0) 100%);
   //   z-index: 1;
   //   z-index: 1;
   // }
   // }
+  &.hulusiTop {
+    padding-top: 20px;
+  }
 }
 }
 
 
 .imgs {
 .imgs {

+ 1 - 1
src/view/fingering/index.tsx

@@ -57,7 +57,7 @@ export default defineComponent({
               )}
               )}
             </div>
             </div>
           ) : (
           ) : (
-            <div onClick={() => doubeClick()} class={[styles.fingeringContainer, styles.vertical, state.fingeringInfo.name]}>
+            <div onClick={() => doubeClick()} class={[styles.fingeringContainer, styles.vertical, state.fingeringInfo.name, state.fingeringInfo.name === 'hulusi-flute' ? styles.hulusiTop : '']}>
               <div class={styles.imgs}>
               <div class={styles.imgs}>
                 <img class="driver-7" src={fingerData.subject?.json?.full} />
                 <img class="driver-7" src={fingerData.subject?.json?.full} />
                 {rs.map((key: number | string, index: number) => {
                 {rs.map((key: number | string, index: number) => {

Some files were not shown because too many files changed in this diff