From 16e7a54b2707bfcb47b6be12bc02e516551545d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim=20Daubensch=C3=BCtz?= Date: Fri, 25 Sep 2015 11:50:55 +0200 Subject: [PATCH 1/2] add coa_verify route to wallet_routes to avoid crash --- js/components/whitelabel/wallet/wallet_routes.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/js/components/whitelabel/wallet/wallet_routes.js b/js/components/whitelabel/wallet/wallet_routes.js index 40f092d6..8d149d2e 100644 --- a/js/components/whitelabel/wallet/wallet_routes.js +++ b/js/components/whitelabel/wallet/wallet_routes.js @@ -4,6 +4,7 @@ import React from 'react'; import Router from 'react-router'; // general components +import CoaVerifyContainer from '../../../components/coa_verify_container'; import LoginContainer from '../../../components/login_container'; import LogoutContainer from '../../../components/logout_container'; import SignupContainer from '../../../components/signup_container'; @@ -45,6 +46,7 @@ let ROUTES = { + ), @@ -60,6 +62,7 @@ let ROUTES = { + ), @@ -76,6 +79,7 @@ let ROUTES = { + ) From e20e3785334f91dc1ec6ec34b8b1d9182449f1af Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim=20Daubensch=C3=BCtz?= Date: Fri, 25 Sep 2015 11:54:12 +0200 Subject: [PATCH 2/2] Remove PrizeDashboard from codebase, add coa_verify to prize app --- .../prizes_dashboard.js | 82 ------------------- .../whitelabel/prize/prize_routes.js | 2 + js/routes.js | 3 - 3 files changed, 2 insertions(+), 85 deletions(-) delete mode 100644 js/components/ascribe_prizes_dashboard/prizes_dashboard.js diff --git a/js/components/ascribe_prizes_dashboard/prizes_dashboard.js b/js/components/ascribe_prizes_dashboard/prizes_dashboard.js deleted file mode 100644 index b4c695f4..00000000 --- a/js/components/ascribe_prizes_dashboard/prizes_dashboard.js +++ /dev/null @@ -1,82 +0,0 @@ -'use strict'; - -import React from 'react'; - -import PrizeListActions from '../../actions/prize_list_actions'; -import PrizeListStore from '../../stores/prize_list_store'; - -import Table from '../ascribe_table/table'; -import TableItem from '../ascribe_table/table_item'; -import TableItemText from '../ascribe_table/table_item_text'; - -import { ColumnModel} from '../ascribe_table/models/table_models'; -import { getLangText } from '../../utils/lang_utils'; - -let PrizesDashboard = React.createClass({ - - getInitialState() { - return PrizeListStore.getState(); - }, - - componentDidMount() { - PrizeListStore.listen(this.onChange); - PrizeListActions.fetchPrizeList(); - }, - - componentWillUnmount() { - PrizeListStore.unlisten(this.onChange); - }, - - onChange(state) { - this.setState(state); - }, - - getColumnList() { - return [ - new ColumnModel( - (item) => { - return { - 'content': item.name - }; }, - 'name', - getLangText('Name'), - TableItemText, - 6, - false, - null - ), - new ColumnModel( - (item) => { - return { - 'content': item.domain - }; }, - 'domain', - getLangText('Domain'), - TableItemText, - 1, - false, - null - ) - ]; - }, - - render() { - return ( - - {this.state.prizeList.map((item, i) => { - return ( - - ); - })} -
- ); - } -}); - -export default PrizesDashboard; \ No newline at end of file diff --git a/js/components/whitelabel/prize/prize_routes.js b/js/components/whitelabel/prize/prize_routes.js index a389cb83..d3031774 100644 --- a/js/components/whitelabel/prize/prize_routes.js +++ b/js/components/whitelabel/prize/prize_routes.js @@ -13,6 +13,7 @@ import PrizePieceList from './components/prize_piece_list'; import PrizePieceContainer from './components/ascribe_detail/prize_piece_container'; import EditionContainer from '../../ascribe_detail/edition_container'; import SettingsContainer from './components/prize_settings_container'; +import CoaVerifyContainer from '../../../components/coa_verify_container'; import App from './prize_app'; import AppConstants from '../../../constants/application_constants'; @@ -34,6 +35,7 @@ function getRoutes() { + ); } diff --git a/js/routes.js b/js/routes.js index f76e4b45..12e5c1f4 100644 --- a/js/routes.js +++ b/js/routes.js @@ -22,8 +22,6 @@ import CoaVerifyContainer from './components/coa_verify_container'; import RegisterPiece from './components/register_piece'; -import PrizesDashboard from './components/ascribe_prizes_dashboard/prizes_dashboard'; - import AppConstants from './constants/application_constants'; let Route = Router.Route; @@ -45,7 +43,6 @@ const COMMON_ROUTES = ( - );