2015-07-10 16:43:35 +02:00
|
|
|
'use strict';
|
|
|
|
|
|
|
|
import React from 'react';
|
|
|
|
import Router from 'react-router';
|
|
|
|
|
2015-08-11 14:47:28 +02:00
|
|
|
import Landing from './components/prize_landing';
|
|
|
|
import LoginContainer from './components/prize_login_container';
|
2015-07-17 15:02:44 +02:00
|
|
|
import LogoutContainer from '../../../components/logout_container';
|
2015-08-11 14:47:28 +02:00
|
|
|
import SignupContainer from './components/prize_signup_container';
|
2015-07-13 19:53:16 +02:00
|
|
|
import PasswordResetContainer from '../../../components/password_reset_container';
|
2015-08-11 14:47:28 +02:00
|
|
|
import PrizeRegisterPiece from './components/prize_register_piece';
|
|
|
|
import PrizePieceList from './components/prize_piece_list';
|
|
|
|
import PrizePieceContainer from './components/ascribe_detail/prize_piece_container';
|
2015-07-13 23:29:07 +02:00
|
|
|
import EditionContainer from '../../ascribe_detail/edition_container';
|
2015-08-11 14:47:28 +02:00
|
|
|
import SettingsContainer from './components/prize_settings_container';
|
2015-09-25 11:54:12 +02:00
|
|
|
import CoaVerifyContainer from '../../../components/coa_verify_container';
|
2015-09-29 16:00:58 +02:00
|
|
|
import ErrorNotFoundPage from '../../../components/error_not_found_page';
|
2015-07-10 16:43:35 +02:00
|
|
|
|
2015-08-11 14:47:28 +02:00
|
|
|
import App from './prize_app';
|
2015-07-10 16:43:35 +02:00
|
|
|
import AppConstants from '../../../constants/application_constants';
|
|
|
|
|
|
|
|
let Route = Router.Route;
|
2015-09-29 16:00:58 +02:00
|
|
|
let NotFoundRoute = Router.NotFoundRoute;
|
2015-07-10 16:43:35 +02:00
|
|
|
let baseUrl = AppConstants.baseUrl;
|
|
|
|
|
|
|
|
|
2015-07-31 13:44:57 +02:00
|
|
|
function getRoutes() {
|
2015-07-10 16:43:35 +02:00
|
|
|
return (
|
|
|
|
<Route name="app" path={baseUrl} handler={App}>
|
2015-07-14 18:00:34 +02:00
|
|
|
<Route name="landing" path={baseUrl} handler={Landing} />
|
2015-07-13 19:53:16 +02:00
|
|
|
<Route name="login" path="login" handler={LoginContainer} />
|
2015-07-17 15:02:44 +02:00
|
|
|
<Route name="logout" path="logout" handler={LogoutContainer} />
|
2015-07-13 19:53:16 +02:00
|
|
|
<Route name="signup" path="signup" handler={SignupContainer} />
|
|
|
|
<Route name="password_reset" path="password_reset" handler={PasswordResetContainer} />
|
2015-08-27 14:34:15 +02:00
|
|
|
<Route name="register_piece" path="register_piece" handler={PrizeRegisterPiece} headerTitle="+ NEW WORK" />
|
|
|
|
<Route name="pieces" path="collection" handler={PrizePieceList} headerTitle="COLLECTION" />
|
2015-07-15 11:39:08 +02:00
|
|
|
<Route name="piece" path="pieces/:pieceId" handler={PrizePieceContainer} />
|
2015-07-13 23:29:07 +02:00
|
|
|
<Route name="edition" path="editions/:editionId" handler={EditionContainer} />
|
2015-07-14 18:55:34 +02:00
|
|
|
<Route name="settings" path="settings" handler={SettingsContainer} />
|
2015-09-25 11:54:12 +02:00
|
|
|
<Route name="coa_verify" path="verify" handler={CoaVerifyContainer} />
|
2015-09-29 16:00:58 +02:00
|
|
|
<NotFoundRoute name="notFound" handler={ErrorNotFoundPage} />
|
2015-07-10 16:43:35 +02:00
|
|
|
</Route>
|
|
|
|
);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2015-07-27 18:19:55 +02:00
|
|
|
export default getRoutes;
|