Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

145 rader
4.8 KiB

  1. import { lazy } from 'react';
  2. // project import
  3. import Loadable from 'components/Loadable';
  4. // import MinimalLayout from 'layout/MinimalLayout';
  5. import MainLayout from 'layout/MainLayout';
  6. // render - login
  7. const AuthLogin = Loadable(lazy(() => import('pages/authentication/Login')));
  8. const AuthRegister = Loadable(lazy(() => import('pages/authentication/RegisterCustom')));
  9. const RegisterForm = Loadable(lazy(() => import('pages/authentication/Register')));
  10. const BusRegisterForm = Loadable(lazy(() => import('pages/authentication/BusRegister')));
  11. const IAmSmartRegister = Loadable(lazy(() => import('pages/authentication/IAmSmartRegister')));
  12. const ErrorPage = Loadable(lazy(() => import('pages/extra-pages/ErrorPage')));
  13. const ForgotPassword = Loadable(lazy(() => import('pages/authentication/ForgotPassword')));
  14. const AfterForgotPasswordPage = Loadable(lazy(() => import('pages/authentication/ForgotPassword/AfterForgotPasswordPage')));
  15. const ForgotPassword_Callback = Loadable(lazy(() => import('pages/authentication/ForgotPassword/AuthCallback')));
  16. const ForgotPassword_Success = Loadable(lazy(() => import('pages/authentication/ForgotPassword/AuthCallback/ResetPasswordSuccess')));
  17. const ForgotUsername = Loadable(lazy(() => import('pages/authentication/ForgotUsername')));
  18. const AfterForgotUsernamePage = Loadable(lazy(() => import('pages/authentication/ForgotUsername/AfterForgotPasswordPage')));
  19. const ForgotUsername_Callback = Loadable(lazy(() => import('pages/authentication/ForgotUsername/AuthCallback')));
  20. const ForgotUsername_Success = Loadable(lazy(() => import('pages/authentication/ForgotUsername/AuthCallback/ResetPasswordSuccess')));
  21. const IAmSmart_DirectLoginCallback = Loadable(lazy(() => import('pages/iAmSmart/DirectLoginCallback')));
  22. //const IAmSmart_FallCallback = Loadable(lazy(() => import('pages/iAmSmart/FallCallback')));
  23. const IAmSmart_FailCallback = Loadable(lazy(() => import('pages/iAmSmart/FailCallback')));
  24. const FailCallback_VerifyMail = Loadable(lazy(() => import('pages/iAmSmart/FailCallback_VerifyMail')));
  25. const IAmSmart_SuccessCallback = Loadable(lazy(() => import('pages/iAmSmart/SuccessCallback')));
  26. const IAmSmart_AuthCallback = Loadable(lazy(() => import('pages/iAmSmart/AuthCallback')));
  27. const IAmSmart_RegistryCallback = Loadable(lazy(() => import('pages/iAmSmart/RegistryCallback')));
  28. //TODO: this page for testing only, please remove at prod
  29. const VerifyPage = Loadable(lazy(() => import('pages/authentication/Verify')));
  30. const Testfps = Loadable(lazy(() => import('pages/Payment/FPS/FPSTest')));
  31. const Payment_FPS_CallBack = Loadable(lazy(() => import('pages/Payment/FPS/fpscallback')));
  32. // ==============================|| AUTH ROUTING ||============================== //
  33. const LoginRoutes = {
  34. path: '/',
  35. element: <MainLayout />,
  36. children: [
  37. {
  38. path: 'login',
  39. element: <AuthLogin />
  40. },
  41. {
  42. path: 'register',
  43. element: <AuthRegister />
  44. },
  45. {
  46. path: 'registerFrom',
  47. element: <RegisterForm />
  48. },
  49. {
  50. path: 'registerFromOrganization',
  51. element: <BusRegisterForm />
  52. },
  53. {
  54. path: 'iAmSmartRegisterFrom',
  55. element: <IAmSmartRegister />
  56. },
  57. {
  58. path: 'error',
  59. element: <ErrorPage/>
  60. },
  61. {
  62. path: 'iamsmart/logincallback',
  63. element: <IAmSmart_DirectLoginCallback/>
  64. },
  65. {
  66. path: 'iamsmart/loginfallback',
  67. element: <IAmSmart_FailCallback/>
  68. },
  69. {
  70. path: 'iamsmart/notverify',
  71. element: <FailCallback_VerifyMail/>
  72. },
  73. {
  74. path: 'iamsmart/authcallback',
  75. element: <IAmSmart_AuthCallback/>
  76. },
  77. {
  78. path: 'iamsmart/registrycallback',
  79. element: <IAmSmart_RegistryCallback/>
  80. },
  81. {
  82. path: 'iamsmart/loginFail',
  83. element: <IAmSmart_FailCallback/>
  84. },
  85. {
  86. path: 'iamsmart/loginSucess',
  87. element: <IAmSmart_SuccessCallback/>
  88. },
  89. {
  90. path: 'verify/:verifyCode/:email',
  91. element: <VerifyPage/>
  92. },
  93. {
  94. path: 'testfps',
  95. element: <Testfps/>
  96. },
  97. {
  98. path: 'testfpscallback',
  99. element: <Payment_FPS_CallBack/>
  100. },
  101. {
  102. path: 'forgot/password',
  103. element: <ForgotPassword/>
  104. },
  105. {
  106. path: 'forgot/password/sent',
  107. element: <AfterForgotPasswordPage/>
  108. },
  109. {
  110. path: 'forgot/password/verify/:verifyCode/:email',
  111. element: <ForgotPassword_Callback/>
  112. },
  113. {
  114. path: 'forgot/password/success',
  115. element: <ForgotPassword_Success/>
  116. },
  117. {
  118. path: 'forgot/username',
  119. element: <ForgotUsername/>
  120. },
  121. {
  122. path: 'forgot/username/sent',
  123. element: <AfterForgotUsernamePage/>
  124. },
  125. {
  126. path: 'forgot/username/verify/:verifyCode/:email',
  127. element: <ForgotUsername_Callback/>
  128. },
  129. {
  130. path: 'forgot/username/success',
  131. element: <ForgotUsername_Success/>
  132. },
  133. ]
  134. };
  135. export default LoginRoutes;