Browse Source

:recycle: trying set only on non-material sorts

tags/0.9.0
J 4 years ago
parent
commit
eade56649d
1 changed files with 7 additions and 7 deletions
  1. 7
    7
      vue-theme/src/pages/list.vue

+ 7
- 7
vue-theme/src/pages/list.vue View File

203
         // a list page, to another list page
203
         // a list page, to another list page
204
         type(newType, oldType) {
204
         type(newType, oldType) {
205
             if(!postTypes.includes(newType)) return console.warn('type not found...')
205
             if(!postTypes.includes(newType)) return console.warn('type not found...')
206
-            this.setIntersectionLoader()
206
+                
207
+            if(this._getSortBy() != sortTypes.material) {
208
+                this.setIntersectionLoader()
209
+            }
207
             this.clearAndInitPostList()
210
             this.clearAndInitPostList()
208
         },
211
         },
209
         $route(to, from) {
212
         $route(to, from) {
210
-            if(this._getSortBy() == sortTypes.material && this.type == 'artist') {
211
-                this.unsetIntersectionLoader()
212
-            } else if(this._getSortBy() == sortTypes.alpha && this.type == 'artist') {
213
-                this.setIntersectionLoader()
214
-            }
215
             // Check if we changed sort method
213
             // Check if we changed sort method
216
             // from no sort to sorted
214
             // from no sort to sorted
217
             // or sorted to no sort
215
             // or sorted to no sort
228
     },
226
     },
229
     mounted() {
227
     mounted() {
230
         this.clearAndInitPostList()
228
         this.clearAndInitPostList()
231
-        this.setIntersectionLoader()
229
+        if(this._getSortBy() != sortTypes.material) {
230
+            this.setIntersectionLoader()
231
+        }
232
     },
232
     },
233
     beforeDestroy() {
233
     beforeDestroy() {
234
         this.unsetIntersectionLoader()
234
         this.unsetIntersectionLoader()

Loading…
Cancel
Save