From 20a5526c376990153033b790d5ee498d319b1416 Mon Sep 17 00:00:00 2001 From: Thomas Bouquet <thomas.bouquet@student-cs.fr> Date: Mon, 31 May 2021 19:57:19 +0200 Subject: [PATCH] pills --- front/src/components/Login/Gestion.js | 10 +++++----- front/src/components/Login/Gestion/GestionStaffeurs.js | 2 -- .../Login/Gestion/gestionStaffeurs/NouveauStaffeur.js | 2 +- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/front/src/components/Login/Gestion.js b/front/src/components/Login/Gestion.js index 925ec1f3..1a4e2abe 100644 --- a/front/src/components/Login/Gestion.js +++ b/front/src/components/Login/Gestion.js @@ -36,27 +36,27 @@ class Pills extends Component { <h2><MDBIcon icon="edit" className="mr-1" /> Gestion</h2> <MDBNav className="mt-5 nav-pills"> <MDBNavItem> - <MDBNavLink link to="#" active={this.state.items["default"] === "1"} onClick={this.togglePills("default", "1")} > + <MDBNavLink link to="#admin" active={this.state.items["default"] === "1"} onClick={this.togglePills("default", "1")} > <MDBIcon icon="tools" className="mr-1" /> Administrateurs </MDBNavLink> </MDBNavItem> <MDBNavItem> - <MDBNavLink link to="#" active={this.state.items["default"] === "2"} onClick={this.togglePills("default", "2")} > + <MDBNavLink link to="#equipes" active={this.state.items["default"] === "2"} onClick={this.togglePills("default", "2")} > <MDBIcon icon="users" className="mr-1" /> Associations </MDBNavLink> </MDBNavItem> <MDBNavItem> - <MDBNavLink link to="#" active={this.state.items["default"] === "5"} onClick={this.togglePills("default", "5")} > + <MDBNavLink link to="#participants" active={this.state.items["default"] === "5"} onClick={this.togglePills("default", "5")} > <MDBIcon icon="address-book" className="mr-1" /> Participants </MDBNavLink> </MDBNavItem> <MDBNavItem> - <MDBNavLink link to="#" active={this.state.items["default"] === "6"} onClick={this.togglePills("default", "6")} > + <MDBNavLink link to="#scores" active={this.state.items["default"] === "6"} onClick={this.togglePills("default", "6")} > <MDBIcon icon="chart-line" className="mr-1" /> Scores </MDBNavLink> </MDBNavItem> <MDBNavItem> - <MDBNavLink link to="#" active={this.state.items["default"] === "7"} onClick={this.togglePills("default", "7")} > + <MDBNavLink link to="#staff" active={this.state.items["default"] === "7"} onClick={this.togglePills("default", "7")} > <MDBIcon icon="user-edit" className="mr-1" /> Staffeurs </MDBNavLink> </MDBNavItem> diff --git a/front/src/components/Login/Gestion/GestionStaffeurs.js b/front/src/components/Login/Gestion/GestionStaffeurs.js index 2660d13e..fd6ae08c 100644 --- a/front/src/components/Login/Gestion/GestionStaffeurs.js +++ b/front/src/components/Login/Gestion/GestionStaffeurs.js @@ -2,7 +2,6 @@ import React from 'react'; import { TableauStaffeursAdmin } from './gestionStaffeurs/TableauStaffeursAdmin'; import { useIsAdmin } from '../../../hooks/authTools'; import BtnNouvauStaffeur from "./gestionStaffeurs/ModalNouveauStaffeur"; -import GestionAdministrateurs from './GestionAdministrateurs'; const GestionStaffeurs = function(){ @@ -17,7 +16,6 @@ const GestionStaffeurs = function(){ <h1>Gestion des staffeurs</h1> </div> <div className="col-3"> - {/*<a className="btn btn-secondary" href="/Gestion/admins/nouveau" role="button">Nouvel administrateur</a>*/} <BtnNouvauStaffeur /> </div> </div> diff --git a/front/src/components/Login/Gestion/gestionStaffeurs/NouveauStaffeur.js b/front/src/components/Login/Gestion/gestionStaffeurs/NouveauStaffeur.js index 7ee27462..2e979cdf 100644 --- a/front/src/components/Login/Gestion/gestionStaffeurs/NouveauStaffeur.js +++ b/front/src/components/Login/Gestion/gestionStaffeurs/NouveauStaffeur.js @@ -11,7 +11,7 @@ export function AddStaffeurForm(){ }) .then(() => { alert("Staffeur ajouté"); - window.location='/Gestion'; + window.location='/Gestion#staff'; }, (error) => { console.log(error); }); -- GitLab