Переглянути джерело

:recycle: fixing up route info method

tags/0.9.0
J 4 роки тому
джерело
коміт
1465feaf04
1 змінених файлів з 4 додано та 2 видалено
  1. 4
    2
      vue-theme/src/pages/list.vue

+ 4
- 2
vue-theme/src/pages/list.vue Переглянути файл

@@ -198,7 +198,10 @@ export default {
198 198
             this.loadMorePosts()
199 199
         },
200 200
         routeInfoFromPath(fullPath) {
201
+            console.log(fullPath)
202
+            console.log(fullPath.split('/'))
201 203
             const [ potentialType, potentialSort ] = fullPath.split('/')
204
+            console.log(potentialType)
202 205
             return {
203 206
                 sortBy: Object.values(sortTypes).includes(potentialSort) ? potentialSort : null,
204 207
                 type: postTypes.includes(potentialType) ? potentialType : null
@@ -210,7 +213,6 @@ export default {
210 213
         // a list page, to another list page
211 214
         type(newType, oldType) {
212 215
             if(!postTypes.includes(newType)) return console.warn('type not found...')
213
-            // this.clearAndInitPostList()
214 216
         },
215 217
         $route(to, from) {
216 218
             console.log('---')
@@ -224,7 +226,7 @@ export default {
224 226
             if(!toPathInfo.sortBy != sortTypes.material) {
225 227
                 this.setIntersectionLoader()
226 228
             }
227
-            
229
+
228 230
             // Check if we changed sort method
229 231
             // from no sort to sorted
230 232
             // or sorted to no sort

Завантаження…
Відмінити
Зберегти