index.js 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. import Vue from 'vue'
  2. import Router from 'vue-router'
  3. import Home from 'pages/Home'
  4. import Item from 'pages/Item'
  5. import ListCorpus from 'pages/ListCorpus'
  6. // import Corpus from 'pages/Corpus'
  7. import EditionToc from 'pages/EditionToc'
  8. import IndexNominum from 'pages/IndexNominum'
  9. import IndexLocorum from 'pages/IndexLocorum'
  10. import IndexOperum from 'pages/IndexOperum'
  11. import Nominum from 'pages/Nominum'
  12. import Locorum from 'pages/Locorum'
  13. import Operum from 'pages/Operum'
  14. import Bibliographie from 'pages/Bibliographie'
  15. Vue.use(Router)
  16. const routes = [
  17. {
  18. name: 'home',
  19. path: '/',
  20. component: Home
  21. },
  22. {
  23. name: 'item',
  24. path: '/babar/:uuid',
  25. component: Item,
  26. props: true
  27. },
  28. {
  29. name: 'listcorpus',
  30. path: '/corpus',
  31. component: ListCorpus
  32. },
  33. // {
  34. // name: 'corpus',
  35. // path: '/corpus/:id',
  36. // component: Corpus
  37. // },
  38. {
  39. name: 'editiontoc',
  40. path: '/edition/:id',
  41. component: EditionToc
  42. },
  43. {
  44. name: 'editiontoctext',
  45. path: '/edition/:id/:textid',
  46. component: EditionToc
  47. },
  48. {
  49. name: 'indexNominum',
  50. path: '/nominum',
  51. component: IndexNominum
  52. },
  53. {
  54. name: 'nominum',
  55. path: '/nominum/:id',
  56. component: Nominum
  57. },
  58. {
  59. name: 'indexLocorum',
  60. path: '/locorum',
  61. component: IndexLocorum
  62. },
  63. {
  64. name: 'locorum',
  65. path: '/locorum/:id',
  66. component: Locorum
  67. },
  68. {
  69. name: 'indexOperum',
  70. path: '/operum',
  71. component: IndexOperum
  72. },
  73. {
  74. name: 'operum',
  75. path: '/operum/:id',
  76. component: Operum
  77. },
  78. {
  79. name: 'bibliographie',
  80. path: '/bibliographie',
  81. component: Bibliographie
  82. }
  83. ]
  84. export default new Router({
  85. mode: 'history',
  86. routes
  87. })