summaryrefslogtreecommitdiffstats
path: root/webapp/routes/route_integrations.jsx
diff options
context:
space:
mode:
authorChristopher Speller <crspeller@gmail.com>2016-06-22 10:30:01 -0400
committerGitHub <noreply@github.com>2016-06-22 10:30:01 -0400
commit14510ce19470c176a7f286d4a3238e813f7dc959 (patch)
tree3aeb058bd9fc0395a040785c876a2762e523df96 /webapp/routes/route_integrations.jsx
parent00dc8e734c5af9e2a7de778b60a2eeaa0e1be269 (diff)
downloadchat-14510ce19470c176a7f286d4a3238e813f7dc959.tar.gz
chat-14510ce19470c176a7f286d4a3238e813f7dc959.tar.bz2
chat-14510ce19470c176a7f286d4a3238e813f7dc959.zip
Adding webpack code splitting (#3377)
Diffstat (limited to 'webapp/routes/route_integrations.jsx')
-rw-r--r--webapp/routes/route_integrations.jsx84
1 files changed, 84 insertions, 0 deletions
diff --git a/webapp/routes/route_integrations.jsx b/webapp/routes/route_integrations.jsx
new file mode 100644
index 000000000..6ebd09a72
--- /dev/null
+++ b/webapp/routes/route_integrations.jsx
@@ -0,0 +1,84 @@
+// Copyright (c) 2016 Mattermost, Inc. All Rights Reserved.
+// See License.txt for license information.
+
+import * as RouteUtils from 'routes/route_utils.jsx';
+import {Route, IndexRoute, Redirect} from 'react-router/es6';
+import React from 'react';
+
+import BackstageNavbar from 'components/backstage/backstage_navbar.jsx';
+import BackstageSidebar from 'components/backstage/backstage_sidebar.jsx';
+import Integrations from 'components/backstage/integrations.jsx';
+import InstalledIncomingWebhooks from 'components/backstage/installed_incoming_webhooks.jsx';
+import InstalledOutgoingWebhooks from 'components/backstage/installed_outgoing_webhooks.jsx';
+import InstalledCommands from 'components/backstage/installed_commands.jsx';
+import AddIncomingWebhook from 'components/backstage/add_incoming_webhook.jsx';
+import AddOutgoingWebhook from 'components/backstage/add_outgoing_webhook.jsx';
+import AddCommand from 'components/backstage/add_command.jsx';
+
+export default (
+ <Route path='integrations'>
+ <IndexRoute
+ components={{
+ navbar: BackstageNavbar,
+ sidebar: BackstageSidebar,
+ center: Integrations
+ }}
+ />
+ <Route path='incoming_webhooks'>
+ <IndexRoute
+ components={{
+ navbar: BackstageNavbar,
+ sidebar: BackstageSidebar,
+ center: InstalledIncomingWebhooks
+ }}
+ />
+ <Route
+ path='add'
+ components={{
+ navbar: BackstageNavbar,
+ sidebar: BackstageSidebar,
+ center: AddIncomingWebhook
+ }}
+ />
+ </Route>
+ <Route path='outgoing_webhooks'>
+ <IndexRoute
+ components={{
+ navbar: BackstageNavbar,
+ sidebar: BackstageSidebar,
+ center: InstalledOutgoingWebhooks
+ }}
+ />
+ <Route
+ path='add'
+ components={{
+ navbar: BackstageNavbar,
+ sidebar: BackstageSidebar,
+ center: AddOutgoingWebhook
+ }}
+ />
+ </Route>
+ <Route path='commands'>
+ <IndexRoute
+ components={{
+ navbar: BackstageNavbar,
+ sidebar: BackstageSidebar,
+ center: InstalledCommands
+ }}
+ />
+ <Route
+ path='add'
+ components={{
+ navbar: BackstageNavbar,
+ sidebar: BackstageSidebar,
+ center: AddCommand
+ }}
+ />
+ </Route>
+ <Redirect
+ from='*'
+ to='/error'
+ query={RouteUtils.notFoundParams}
+ />
+ </Route>
+);