Quellcode durchsuchen

:recycle: just checking for sort and clear

tags/0.9.0
J vor 4 Jahren
Ursprung
Commit
c46759d19d
1 geänderte Dateien mit 5 neuen und 4 gelöschten Zeilen
  1. 5
    4
      vue-theme/src/pages/list.vue

+ 5
- 4
vue-theme/src/pages/list.vue Datei anzeigen

89
             let dispatchAction = `getAll${this.pType}`
89
             let dispatchAction = `getAll${this.pType}`
90
 
90
 
91
             let res = null
91
             let res = null
92
-            if(clear) {
92
+            
93
+            if(['event', 'exhibition'].includes(this.type)) {
93
                 dispatchParams.sortType = sortTypes.currentAndUpcoming
94
                 dispatchParams.sortType = sortTypes.currentAndUpcoming
94
-                res = await this.$store.dispatch(dispatchAction, dispatchParams)
95
             }
95
             }
96
             // Add to existing except episodes
96
             // Add to existing except episodes
97
-            else if (this.type != 'episode') {
97
+            else if (!clear) {
98
                 dispatchAction = `getMore${this.pType}`
98
                 dispatchAction = `getMore${this.pType}`
99
-                res = await this.$store.dispatch(dispatchAction, dispatchParams)
100
             }
99
             }
100
+
101
+            res = await this.$store.dispatch(dispatchAction, dispatchParams)
101
             
102
             
102
             if(!res.length) {
103
             if(!res.length) {
103
                 console.warn('nothing left to get...')
104
                 console.warn('nothing left to get...')

Laden…
Abbrechen
Speichern