From 77ee1ce7fee698847e211dc15d4673300901aa48 Mon Sep 17 00:00:00 2001
From: Harrison Healey <harrisonmhealey@gmail.com>
Date: Fri, 8 Apr 2016 11:51:28 -0400
Subject: PLT-2553 Updated backstage page navigation (#2661)

* Updated integrations list based on feedback

* Reorganized Integrations pages

* Repurposed AddIntegration page as a landing page for Integrations

* Moved backstage breadcrumb header into its own component

* Removed unnecessary prop

* Fixed Save links on AddIntegration pages
---
 webapp/root.jsx | 40 +++++++++++++++++++++++++++++-----------
 1 file changed, 29 insertions(+), 11 deletions(-)

(limited to 'webapp/root.jsx')

diff --git a/webapp/root.jsx b/webapp/root.jsx
index a76f7cf7e..9268643f3 100644
--- a/webapp/root.jsx
+++ b/webapp/root.jsx
@@ -38,8 +38,10 @@ import AdminConsole from 'components/admin_console/admin_controller.jsx';
 import TutorialView from 'components/tutorial/tutorial_view.jsx';
 import BackstageNavbar from 'components/backstage/backstage_navbar.jsx';
 import BackstageSidebar from 'components/backstage/backstage_sidebar.jsx';
-import InstalledIntegrations from 'components/backstage/installed_integrations.jsx';
-import AddIntegration from 'components/backstage/add_integration.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';
@@ -253,41 +255,57 @@ function renderRootComponent() {
                         onEnter={onLoggedOut}
                     />
                     <Route path='settings/integrations'>
-                        <IndexRedirect to='installed'/>
-                        <Route
-                            path='installed'
+                        <IndexRoute
                             components={{
                                 navbar: BackstageNavbar,
                                 sidebar: BackstageSidebar,
-                                center: InstalledIntegrations
+                                center: Integrations
                             }}
                         />
-                        <Route path='add'>
+                        <Route path='incoming_webhooks'>
                             <IndexRoute
                                 components={{
                                     navbar: BackstageNavbar,
                                     sidebar: BackstageSidebar,
-                                    center: AddIntegration
+                                    center: InstalledIncomingWebhooks
                                 }}
                             />
                             <Route
-                                path='incoming_webhook'
+                                path='add'
                                 components={{
                                     navbar: BackstageNavbar,
                                     sidebar: BackstageSidebar,
                                     center: AddIncomingWebhook
                                 }}
                             />
+                        </Route>
+                        <Route path='outgoing_webhooks'>
+                            <IndexRoute
+                                components={{
+                                    navbar: BackstageNavbar,
+                                    sidebar: BackstageSidebar,
+                                    center: InstalledOutgoingWebhooks
+                                }}
+                            />
                             <Route
-                                path='outgoing_webhook'
+                                path='add'
                                 components={{
                                     navbar: BackstageNavbar,
                                     sidebar: BackstageSidebar,
                                     center: AddOutgoingWebhook
                                 }}
                             />
+                        </Route>
+                        <Route path='commands'>
+                            <IndexRoute
+                                components={{
+                                    navbar: BackstageNavbar,
+                                    sidebar: BackstageSidebar,
+                                    center: InstalledCommands
+                                }}
+                            />
                             <Route
-                                path='command'
+                                path='add'
                                 components={{
                                     navbar: BackstageNavbar,
                                     sidebar: BackstageSidebar,
-- 
cgit v1.2.3-1-g7c22

