Browse Source

refactor: move Radio to RadioShows

boyska 1 year ago
parent
commit
bac222c2e3
3 changed files with 7 additions and 5 deletions
  1. 5 3
      src/js/routes.js
  2. 0 0
      src/pages/RadioShows.vue
  3. 2 2
      src/pages/home.vue

+ 5 - 3
src/js/routes.js

@@ -1,6 +1,6 @@
 
 import HomePage from '../pages/home.vue'
-import RadioPage from '../pages/Radio.vue'
+import RadioShowsPage from '../pages/RadioShows.vue'
 import ShowPage from '../pages/Show.vue'
 import NotFoundPage from '../pages/404.vue'
 
@@ -10,10 +10,12 @@ var routes = [
     master: true,
     component: HomePage,
     detailRoutes: [{
-      path: '/radio/:radioName',
-      component: RadioPage,
+      name: 'RadioShows',
+      path: '/radio/:radioName/shows',
+      component: RadioShowsPage,
     },
     {
+      name: 'ShowPage',
       path: '/radio/:radioId/shows/:showId',
       component: ShowPage
     }],

+ 0 - 0
src/pages/Radio.vue → src/pages/RadioShows.vue


+ 2 - 2
src/pages/home.vue

@@ -8,9 +8,9 @@ import radiomanifest from '../js/radiomanifest'
     <!-- Page content-->
     <f7-block-title>Radio</f7-block-title>
     <f7-list>
-      <f7-list-item v-for='(radio, id) in radiomanifest.radio' :key='id' :link="`/radio/${id}`" :title="radio.name" />
+      <f7-list-item v-for='(radio, id) in radiomanifest.radio' :key='id' :link="`/radio/${id}/shows`" :title="radio.name" />
     </f7-list>
 
 
   </f7-page>
-</template>
+</template>