UserPanel.js 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378
  1. import { Authenticated, canSeeUserProfilePanel, HasOverdueInstalment } from 'src/router/middleware/middleware'
  2. export default {
  3. path: 'panel',
  4. name: 'UserPanel',
  5. layoutConfig: {
  6. layoutView: 'hHh LpR lfr',
  7. layoutHeaderType: 'user-panel',
  8. layoutHeaderBordered: true,
  9. layoutLeftDrawer: true,
  10. layoutLeftDrawerVisible: true,
  11. layoutLeftSideBarType: 'user-panel',
  12. layoutLeftDrawerBordered: true,
  13. layoutLeftDrawerWidth: 240,
  14. layoutFooterType: 'panel',
  15. layoutFooter: true
  16. },
  17. meta: { middlewares: [Authenticated, canSeeUserProfilePanel] },
  18. component: () => import('src/layouts/UserPanelLayout.vue'),
  19. children: [
  20. {
  21. name: 'UserPanel.ShopCompleteInfo',
  22. path: 'shop/completeInfo',
  23. layoutConfig: {
  24. layoutView: 'hHh LpR fff',
  25. layoutHeaderType: 'main',
  26. layoutHeaderBordered: true,
  27. layoutLeftDrawer: false,
  28. layoutLeftDrawerVisible: false,
  29. layoutFooter: true
  30. },
  31. component: () => import('src/pages/User/Shop/completeInfo.vue')
  32. },
  33. {
  34. name: 'UserPanel.ShopPaymentFromWallet',
  35. path: 'shop/payment-from-wallet',
  36. layoutConfig: {
  37. layoutView: 'hHh LpR fff',
  38. layoutHeaderType: 'main',
  39. layoutHeaderBordered: true,
  40. layoutLeftDrawer: false,
  41. layoutLeftDrawerVisible: false,
  42. layoutFooter: true
  43. },
  44. meta: { middlewares: [Authenticated] },
  45. component: () => import('src/pages/User/Shop/paymentFromWallet.vue')
  46. },
  47. {
  48. name: 'UserPanel.PaymentResult',
  49. path: 'shop/payment-result',
  50. meta: { middlewares: [Authenticated] },
  51. component: () => import('src/pages/User/Shop/paymentResult.vue')
  52. },
  53. {
  54. path: 'profile',
  55. name: 'UserPanel.Profile',
  56. component: () => import('src/layouts/bareLayout.vue'),
  57. meta: { middlewares: [Authenticated] },
  58. children: [
  59. {
  60. name: 'UserPanel.Profile.OverdueInstalments',
  61. path: 'overdue-instalments',
  62. component: () => import('src/pages/User/Profile/OverdueInstalment.vue')
  63. },
  64. {
  65. name: 'UserPanel.Profile.AllDiscussionCirclesClassrooms',
  66. path: 'all-discussion-circles-classrooms',
  67. component: () => import('src/pages/User/Profile/DiscussionCirclesClassrooms.vue'),
  68. meta: {
  69. breadcrumbs: {
  70. visible: true,
  71. loading: false,
  72. path: [
  73. {
  74. label: 'حلقه های مباحثاتی من',
  75. to: { name: 'UserPanel.Profile.AllDiscussionCirclesClassrooms' }
  76. }
  77. ]
  78. },
  79. middlewares: [HasOverdueInstalment]
  80. }
  81. },
  82. {
  83. name: 'UserPanel.Profile.AllClassrooms',
  84. path: 'all-classrooms',
  85. component: () => import('src/pages/User/Profile/classrooms.vue'),
  86. meta: {
  87. breadcrumbs: {
  88. visible: true,
  89. loading: false,
  90. path: [
  91. {
  92. label: 'دوره های من',
  93. to: { name: 'UserPanel.Profile.AllClassrooms' }
  94. }
  95. ]
  96. },
  97. middlewares: [HasOverdueInstalment]
  98. }
  99. },
  100. {
  101. name: 'UserPanel.Profile.ClassroomInfo',
  102. path: 'classroom/:id',
  103. component: () => import('src/pages/User/Profile/classroomInfo.vue'),
  104. meta: {
  105. middlewares: [HasOverdueInstalment]
  106. }
  107. },
  108. {
  109. name: 'UserPanel.Profile.Test',
  110. path: 'test/:id',
  111. component: () => import('src/pages/User/Profile/test.vue'),
  112. meta: {
  113. middlewares: [HasOverdueInstalment]
  114. }
  115. },
  116. {
  117. name: 'UserPanel.Profile.AllEvents',
  118. path: 'all-events',
  119. component: () => import('src/pages/User/Profile/Events.vue'),
  120. meta: {
  121. breadcrumbs: {
  122. visible: true,
  123. loading: false,
  124. path: [
  125. {
  126. label: 'رویدادهای من',
  127. to: { name: 'UserPanel.Profile.AllEvents' }
  128. }
  129. ]
  130. },
  131. middlewares: [HasOverdueInstalment]
  132. }
  133. },
  134. {
  135. name: 'UserPanel.Profile.EventInfo',
  136. path: 'event/:id',
  137. component: () => import('src/pages/User/Profile/EventInfo.vue'),
  138. meta: {
  139. middlewares: [HasOverdueInstalment]
  140. }
  141. },
  142. { name: 'UserPanel.Profile.Classroom.Project.Show', path: 'classroom/:classroom_id/project/:project_id', component: () => import('src/pages/User/Profile/projectInfo.vue') },
  143. {
  144. name: 'UserPanel.Profile.SessionInfo',
  145. path: 'session/:id',
  146. component: () => import('src/pages/User/Profile/sessionInfo.vue'),
  147. meta: {
  148. middlewares: [HasOverdueInstalment]
  149. }
  150. },
  151. {
  152. name: 'UserPanel.Profile.UserInfo',
  153. path: 'user-info',
  154. component: () => import('src/pages/User/Profile/profile.vue')
  155. },
  156. {
  157. name: 'UserPanel.Leader',
  158. path: 'leader',
  159. component: () => import('layouts/bareLayout.vue'),
  160. children: [
  161. { name: 'UserPanel.Leader.Teams.Index', path: 'teams', component: () => import('pages/Admin/Leader/MyTeams.vue') },
  162. { name: 'UserPanel.Leader.Teams.Show', path: 'teams/:team_id', component: () => import('pages/Admin/Leader/ShowTeam.vue') }
  163. ]
  164. },
  165. {
  166. name: 'UserPanel.Test',
  167. path: 'test/:test_id',
  168. component: () => import('layouts/bareLayout.vue'),
  169. children: [
  170. { name: 'UserPanel.Test.AnswerBook.Confirmation', path: 'answer_book/:answer_book_id/confirmation', component: () => import('src/pages/User/Test/Confirmation.vue') },
  171. { name: 'UserPanel.Test.AnswerBook.Participate.AllQuestions', path: 'answer_book/:answer_book_id/participate/all_questions', component: () => import('src/pages/User/Test/ParticipateAllQuestions.vue') },
  172. { name: 'UserPanel.Test.AnswerBook.Participate.SingleQuestion', path: 'answer_book/:answer_book_id/participate/question/:question_number', component: () => import('src/pages/User/Test/ParticipateSingleQuestion.vue') },
  173. { name: 'UserPanel.Test.AnswerBook.Show', path: 'answer_book/:answer_book_id/show', component: () => import('src/pages/User/Test/Show.vue') },
  174. { name: 'UserPanel.Test.AnswerBook.SendObjection', path: 'answer_book/:answer_book_id/sendObjection', component: () => import('src/pages/User/Test/SendObjection.vue') }
  175. ]
  176. },
  177. {
  178. name: 'UserPanel.Classroom.MyAsGraderClassroom',
  179. path: 'my_as_a_grader_classrooms',
  180. component: () => import('src/layouts/bareLayout.vue'),
  181. children: [
  182. { name: 'UserPanel.Classroom.MyAsGraderClassroom.Index', path: '', component: () => import('src/pages/Admin/Classroom/MyAsGraderClassrooms.vue') },
  183. { name: 'UserPanel.Classroom.MyAsGraderClassroom.AnswerBooks', path: ':classroom_id/answer_books', component: () => import('src/pages/Admin/Classroom/ClassroomAnswerBooksForGrader.vue') },
  184. { name: 'UserPanel.Classroom.MyAsGraderClassroom.AnswerBooks.ShowGrade', path: ':classroom_id/answer_books/:answer_book_id/show_grades', component: () => import('src/pages/Admin/Classroom/ClassroomAnswerBookShowGradeForGrader.vue') },
  185. { name: 'UserPanel.Classroom.MyAsGraderClassroom.AnswerBooks.SubmitGrade', path: ':classroom_id/answer_books/:answer_book_id/submit_grade', component: () => import('src/pages/Admin/Classroom/ClassroomAnswerBookSubmitGrade.vue') }
  186. ]
  187. }
  188. ]
  189. },
  190. {
  191. path: 'invoice',
  192. name: 'UserPanel.Invoice',
  193. component: () => import('layouts/bareLayout.vue'),
  194. children: [
  195. {
  196. path: '',
  197. name: 'UserPanel.Invoice.List',
  198. meta: {
  199. breadcrumbs: {
  200. visible: true,
  201. loading: false,
  202. path: [
  203. {
  204. label: 'بخش مالی'
  205. },
  206. {
  207. label: 'صورتحساب ها',
  208. to: { name: 'UserPanel.Invoice.List' }
  209. }
  210. ]
  211. }
  212. },
  213. component: () => import('src/pages/User/Invoice/List.vue')
  214. },
  215. {
  216. path: 'thankyou',
  217. name: 'UserPanel.Invoice.Thankyou',
  218. component: () => import('src/pages/User/Invoice/Thankyou.vue')
  219. },
  220. {
  221. path: ':id',
  222. name: 'UserPanel.Invoice.Show',
  223. meta: {
  224. breadcrumbs: {
  225. visible: true,
  226. loading: false,
  227. path: [
  228. {
  229. label: 'بخش مالی'
  230. },
  231. {
  232. label: 'صورتحساب ها',
  233. to: { name: 'UserPanel.Invoice.List' }
  234. },
  235. {
  236. label: 'جزییات صورتحساب'
  237. }
  238. ]
  239. }
  240. },
  241. component: () => import('src/pages/User/Invoice/Show.vue')
  242. },
  243. {
  244. path: 'ticket',
  245. name: 'UserPanel.Invoice.Ticket',
  246. component: () => import('layouts/bareLayout.vue'),
  247. children: [
  248. {
  249. path: '',
  250. name: 'UserPanel.Invoice.Ticket.List',
  251. component: () => import('src/pages/User/Invoice/Ticket/List.vue')
  252. },
  253. {
  254. path: ':id',
  255. name: 'UserPanel.Invoice.Ticket.Show',
  256. component: () => import('src/pages/User/Invoice/Ticket/Show.vue')
  257. },
  258. {
  259. path: 'create',
  260. name: 'UserPanel.Invoice.Ticket.Create',
  261. component: () => import('src/pages/User/Invoice/Ticket/Create.vue')
  262. }
  263. ]
  264. }
  265. ]
  266. },
  267. {
  268. path: 'ticket',
  269. name: 'UserPanel.Ticket',
  270. component: () => import('layouts/bareLayout.vue'),
  271. children: [
  272. {
  273. path: '',
  274. name: 'UserPanel.Ticket.List',
  275. component: () => import('src/pages/User/Ticket/List.vue')
  276. },
  277. {
  278. path: ':id',
  279. name: 'UserPanel.Ticket.Show',
  280. meta: {
  281. breadcrumbs: {
  282. visible: true,
  283. loading: false,
  284. path: [
  285. {
  286. label: 'درخواست ها',
  287. to: { name: 'UserPanel.Ticket.List' }
  288. },
  289. {
  290. label: 'جزییات درخواست'
  291. }
  292. ]
  293. }
  294. },
  295. component: () => import('src/pages/User/Ticket/Show.vue')
  296. },
  297. {
  298. path: 'create',
  299. name: 'UserPanel.Ticket.Create',
  300. meta: { middlewares: [Authenticated] },
  301. component: () => import('src/pages/User/Ticket/Create.vue')
  302. }
  303. ]
  304. },
  305. {
  306. path: 'notice',
  307. name: 'UserPanel.Notice.List',
  308. component: () => import('src/pages/User/Notice/List.vue')
  309. },
  310. {
  311. path: 'wallet',
  312. name: 'UserPanel.Wallet',
  313. component: () => import('src/pages/User/Wallet/Show.vue'),
  314. meta: {
  315. breadcrumbs: {
  316. visible: true,
  317. loading: false,
  318. path: [
  319. {
  320. label: 'بخش مالی'
  321. },
  322. {
  323. label: 'کیف پول الکترونیک',
  324. to: { name: 'UserPanel.Wallet' }
  325. }
  326. ]
  327. }
  328. }
  329. },
  330. {
  331. path: 'my-orders',
  332. name: 'UserPanel.MyOrders',
  333. component: () => import('layouts/bareLayout.vue'),
  334. children: [
  335. { path: '', name: 'UserPanel.MyOrders.List', component: () => import('src/pages/User/MyOrders/List.vue') },
  336. { path: ':id', name: 'UserPanel.MyOrders.Show', component: () => import('src/pages/User/MyOrders/Show.vue') }
  337. ]
  338. },
  339. {
  340. path: 'payment',
  341. name: 'UserPanel.Payment',
  342. component: () => import('src/layouts/bareLayout.vue'),
  343. children: [
  344. {
  345. path: '',
  346. name: 'UserPanel.Payment.List',
  347. component: () => import('src/pages/User/Payment/List.vue')
  348. },
  349. {
  350. path: 'transactions',
  351. name: 'UserPanel.Payment.TransactionList',
  352. component: () => import('src/pages/User/Payment/TransactionList.vue')
  353. },
  354. {
  355. name: 'UserPanel.Payment.Show',
  356. path: ':id',
  357. component: () => import('src/pages/User/Payment/Show.vue'),
  358. meta: {
  359. breadcrumbs: {
  360. visible: true,
  361. loading: false,
  362. path: [
  363. {
  364. label: 'کیف پول الکترونیک',
  365. to: { name: 'UserPanel.Wallet' }
  366. },
  367. {
  368. label: 'جزییات پرداخت'
  369. }
  370. ]
  371. }
  372. }
  373. }
  374. ]
  375. }
  376. ]
  377. }