commit
						917a38d998
					
				| @ -22,7 +22,7 @@ public class AppMain extends Application { | ||||
|         testMode = res!=null&&res.equals("true"); | ||||
| 
 | ||||
| 
 | ||||
|         ScreenController.addScreen("Accueil",FXMLLoader.load(getClass().getResource("/fr/univ_amu/iut/fp/fp.fxml"))); | ||||
|         ScreenController.addScreen("Accueil",FXMLLoader.load(getClass().getResource("/fr/univ_amu/iut/ui/fenetrePrincipale/fp.fxml"))); | ||||
|          | ||||
|         //TODO Ajouter les pages d'admin pour l'ajout des usages | ||||
|         //ScreenController.addScreen("admin1",pane); | ||||
|  | ||||
| @ -5,6 +5,7 @@ import de.mkammerer.argon2.Argon2Factory; | ||||
| 
 | ||||
| public class LocalSecretProvider implements SecretProvider { | ||||
| 
 | ||||
| 	// Le mot de passe est "azerty" | ||||
| 	private final static String ARGON_HASH = "$argon2id$v=19$m=16,t=2,p=1$Tms1dkJYWEZ5OTdJTndVTg$+iBsHiILEshy1JLZsTfZFQ"; | ||||
| 	private final static Argon2 argon2 = Argon2Factory.create(Argon2Factory.Argon2Types.ARGON2id); | ||||
| 
 | ||||
|  | ||||
| @ -1,4 +1,4 @@ | ||||
| package fr.univ_amu.iut.admin2; | ||||
| package fr.univ_amu.iut.ui.admin2; | ||||
| 
 | ||||
| import javafx.event.ActionEvent; | ||||
| import javafx.event.EventHandler; | ||||
| @ -1,4 +1,4 @@ | ||||
| package fr.univ_amu.iut.admin2; | ||||
| package fr.univ_amu.iut.ui.admin2; | ||||
| 
 | ||||
| 
 | ||||
| import javafx.application.Application; | ||||
| @ -15,7 +15,7 @@ public class Main extends Application { | ||||
|     @Override | ||||
|     public void start(Stage stage) throws Exception { | ||||
|         try { | ||||
|             AnchorPane root = FXMLLoader.load(getClass().getResource("/fr/univ_amu/iut/admin2/admin2.fxml")); | ||||
|             AnchorPane root = FXMLLoader.load(getClass().getResource("/fr/univ_amu/iut/ui/admin2/admin2.fxml")); | ||||
|             stage.setScene(new Scene(root)); | ||||
|             stage.show(); | ||||
|         } catch (Exception e) { | ||||
| @ -10,7 +10,7 @@ | ||||
| <?import javafx.scene.text.Font?> | ||||
| <?import javafx.scene.text.Text?> | ||||
| 
 | ||||
| <AnchorPane prefHeight="837.0" prefWidth="1350.0" style="-fx-background-color: #f5f0e1#f5f0e1;" xmlns="http://javafx.com/javafx/18" xmlns:fx="http://javafx.com/fxml/1" fx:controller="fr.univ_amu.iut.admin2.Controller"> | ||||
| <AnchorPane prefHeight="837.0" prefWidth="1350.0" style="-fx-background-color: #f5f0e1#f5f0e1;" xmlns="http://javafx.com/javafx/18" xmlns:fx="http://javafx.com/fxml/1" fx:controller="fr.univ_amu.iut.ui.admin2.Controller"> | ||||
|    <children> | ||||
|       <ScrollPane id="acteurs" layoutX="14.0" layoutY="136.0" prefHeight="234.0" prefWidth="589.0" style="-fx-background-radius: 10;"> | ||||
|         <content> | ||||
| @ -1,4 +1,4 @@ | ||||
| package fr.univ_amu.iut.detailResultats; | ||||
| package fr.univ_amu.iut.ui.detailResultats; | ||||
| import javafx.event.ActionEvent; | ||||
| import javafx.event.EventHandler; | ||||
| import javafx.fxml.FXML; | ||||
| @ -4,7 +4,7 @@ | ||||
| <?import javafx.scene.layout.*?> | ||||
| <?import javafx.scene.text.*?> | ||||
| 
 | ||||
| <AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="600.0" prefWidth="1200.0" style="-fx-background-color: #f5f0e1#f5f0e1;" xmlns="http://javafx.com/javafx/16" xmlns:fx="http://javafx.com/fxml/1" fx:controller="fr.univ_amu.iut.detailResultats.Controller"> | ||||
| <AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="600.0" prefWidth="1200.0" style="-fx-background-color: #f5f0e1#f5f0e1;" xmlns="http://javafx.com/javafx/16" xmlns:fx="http://javafx.com/fxml/1" fx:controller="fr.univ_amu.iut.ui.detailResultats.Controller"> | ||||
|    <children> | ||||
|       <Text fill="#ff6e40" layoutX="93.0" layoutY="76.0" strokeType="OUTSIDE" strokeWidth="0.0" text="Academie " wrappingWidth="175.0749652342431" AnchorPane.leftAnchor="93.0" AnchorPane.topAnchor="47.0"> | ||||
|          <font> | ||||
| @ -1,4 +1,4 @@ | ||||
| package fr.univ_amu.iut.fp; | ||||
| package fr.univ_amu.iut.ui.fenetrePrincipale; | ||||
| 
 | ||||
| import fr.univ_amu.iut.AppMain; | ||||
| import fr.univ_amu.iut.Donnees; | ||||
| @ -186,7 +186,7 @@ public class Controller implements Initializable { | ||||
| 
 | ||||
|             Stage resultats = new Stage(); | ||||
|             try { | ||||
|                 resultats.setScene(new Scene(FXMLLoader.load(getClass().getResource("/fr/univ_amu/iut/fResultat/FResultat.fxml")))); | ||||
|                 resultats.setScene(new Scene(FXMLLoader.load(getClass().getResource("/fr/univ_amu/iut/ui/fenetreResultats/FResultat.fxml")))); | ||||
|                 resultats.show(); | ||||
|             } catch (IOException e) { | ||||
|                 e.printStackTrace(); | ||||
| @ -200,7 +200,7 @@ public class Controller implements Initializable { | ||||
|             Donnees.setUsagesObtenus(daoUsage.findByCriterias(Donnees.getThematiqueSelectionee(),Donnees.getDisciplineSelectionee(),Donnees.getAcademieSelectionee())); | ||||
|             Stage resultats = new Stage(); | ||||
|             try { | ||||
|                 resultats.setScene(new Scene(FXMLLoader.load(getClass().getResource("/fr/univ_amu/iut/fResultat/FResultat.fxml")))); | ||||
|                 resultats.setScene(new Scene(FXMLLoader.load(getClass().getResource("/fr/univ_amu/iut/ui/fenetreResultats/FResultat.fxml")))); | ||||
|                 resultats.show(); | ||||
|             } catch (IOException e) { | ||||
|                 e.printStackTrace(); | ||||
| @ -211,7 +211,7 @@ public class Controller implements Initializable { | ||||
|         EventHandler<ActionEvent> loginPrompt = event ->{ | ||||
|             Stage loginWindow = new Stage(); | ||||
|             try { | ||||
|                 loginWindow.setScene(new Scene(FXMLLoader.load(getClass().getResource("/fr/univ_amu/iut/loginPrompt/Code_accessa.fxml")))); | ||||
|                 loginWindow.setScene(new Scene(FXMLLoader.load(getClass().getResource("/fr/univ_amu/iut/ui/loginPrompt/Code_access.fxml")))); | ||||
|                 loginWindow.show(); | ||||
|             } catch (IOException e) { | ||||
|                 e.printStackTrace(); | ||||
| @ -4,7 +4,7 @@ | ||||
| <?import javafx.scene.control.*?> | ||||
| <?import javafx.scene.layout.*?> | ||||
| 
 | ||||
| <AnchorPane id="root" prefHeight="860.0" prefWidth="1365.0" style="-fx-background-color: #f5f0e1#f5f0e1;" xmlns="http://javafx.com/javafx/18" xmlns:fx="http://javafx.com/fxml/1" fx:controller="fr.univ_amu.iut.fp.Controller"> | ||||
| <AnchorPane id="root" prefHeight="860.0" prefWidth="1365.0" style="-fx-background-color: #f5f0e1#f5f0e1;" xmlns="http://javafx.com/javafx/18" xmlns:fx="http://javafx.com/fxml/1" fx:controller="fr.univ_amu.iut.ui.fenetrePrincipale.Controller"> | ||||
|    <children> | ||||
|       <StackPane id="stackPaneFrance" fx:id="stackPaneFrance" layoutX="43.0" layoutY="92.0" prefHeight="649.0" prefWidth="642.0" style="-fx-background-color: blue;" /> | ||||
|       <AnchorPane layoutX="11.0" prefHeight="80.0" prefWidth="1019.0" style="-fx-background-color: #1e3d59#1e3d59;" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0"> | ||||
| @ -1,9 +1,8 @@ | ||||
| package fr.univ_amu.iut.fResultat; | ||||
| package fr.univ_amu.iut.ui.fenetreResultats; | ||||
| 
 | ||||
| 
 | ||||
| import javafx.collections.FXCollections; | ||||
| import javafx.collections.ObservableList; | ||||
| import javafx.event.Event; | ||||
| import javafx.fxml.FXML; | ||||
| import javafx.fxml.FXMLLoader; | ||||
| import javafx.fxml.Initializable; | ||||
| @ -68,7 +67,7 @@ public class Controller implements Initializable{ | ||||
|             Donnees.setUsageSelectione(table.getSelectionModel().getSelectedItem().getUsage()); | ||||
|             Tab onglet; | ||||
|             try { | ||||
|                 onglet = new Tab(Donnees.getUsageSelectione().getNom(),FXMLLoader.load(getClass().getResource("/fr/univ_amu/iut/detailResultats/detail.fxml"))); | ||||
|                 onglet = new Tab(Donnees.getUsageSelectione().getNom(),FXMLLoader.load(getClass().getResource("/fr/univ_amu/iut/ui/detailResultats/detail.fxml"))); | ||||
|                 onglets.getTabs().add(onglet); | ||||
|             } catch (IOException e) { | ||||
|                 e.printStackTrace(); | ||||
| @ -6,7 +6,7 @@ | ||||
| <?import javafx.scene.control.TableView?> | ||||
| <?import javafx.scene.layout.AnchorPane?> | ||||
| 
 | ||||
| <TabPane fx:id="onglets" xmlns="http://javafx.com/javafx/18" xmlns:fx="http://javafx.com/fxml/1" fx:controller="fr.univ_amu.iut.fResultat.Controller"> | ||||
| <TabPane fx:id="onglets" xmlns="http://javafx.com/javafx/18" xmlns:fx="http://javafx.com/fxml/1" fx:controller="fr.univ_amu.iut.ui.fenetreResultats.Controller"> | ||||
|    <tabs> | ||||
|       <Tab text="Resultats"> | ||||
|          <content> | ||||
| @ -1,6 +1,4 @@ | ||||
| package fr.univ_amu.iut.fResultat; | ||||
| 
 | ||||
| import java.util.List; | ||||
| package fr.univ_amu.iut.ui.fenetreResultats; | ||||
| 
 | ||||
| import fr.univ_amu.iut.model.Usage; | ||||
| 
 | ||||
| @ -6,7 +6,7 @@ | ||||
| <?import javafx.scene.text.Font?> | ||||
| <?import javafx.scene.text.Text?> | ||||
| 
 | ||||
| <AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="321.0" prefWidth="504.0" style="-fx-background-color: #f5f0e1#f5f0e1;" xmlns="http://javafx.com/javafx/18" xmlns:fx="http://javafx.com/fxml/1" fx:controller="fr.univ_amu.iut.loginPrompt.Controller"> | ||||
| <AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="321.0" prefWidth="504.0" style="-fx-background-color: #f5f0e1#f5f0e1;" xmlns="http://javafx.com/javafx/18" xmlns:fx="http://javafx.com/fxml/1" fx:controller="fr.univ_amu.iut.ui.loginPrompt.Controller"> | ||||
|    <children> | ||||
|       <Text layoutX="171.0" layoutY="125.0" strokeType="OUTSIDE" strokeWidth="0.0" text="Code d'accès" textAlignment="CENTER" wrappingWidth="171.82891845703125"> | ||||
|          <font> | ||||
| @ -1,6 +1,7 @@ | ||||
| 
 | ||||
| package fr.univ_amu.iut.loginPrompt; | ||||
| package fr.univ_amu.iut.ui.loginPrompt; | ||||
| 
 | ||||
| import fr.univ_amu.iut.secret.SecretProvider; | ||||
| import javafx.event.ActionEvent; | ||||
| import javafx.event.EventHandler; | ||||
| import javafx.fxml.FXML; | ||||
| @ -24,11 +25,12 @@ public class Controller implements Initializable{ | ||||
|     public void initialize(URL url, ResourceBundle resourceBundle) { | ||||
|          | ||||
|         EventHandler<ActionEvent> handleLogin = event ->{ | ||||
|             // TODO Use SecretProvider | ||||
|             System.out.println(password.getText()); | ||||
|             if(SecretProvider.getInstance().isSecretValid(password.getText())){ | ||||
|                 System.out.println("Mot de passe OK !"); | ||||
|             }else{ | ||||
|                 System.out.println("Mot de passe invalide"); | ||||
|             } | ||||
|         }; | ||||
|         log.setOnAction(handleLogin); | ||||
|          | ||||
|     } | ||||
| 
 | ||||
| } | ||||
| @ -1,7 +1,7 @@ | ||||
| package fr.univ_amu.iut; | ||||
| 
 | ||||
| import fr.univ_amu.iut.fResultat.TableEntry; | ||||
| import fr.univ_amu.iut.fp.Controller; | ||||
| import fr.univ_amu.iut.ui.fenetrePrincipale.Controller; | ||||
| import fr.univ_amu.iut.ui.fenetreResultats.TableEntry; | ||||
| import fr.univ_amu.iut.model.Discipline; | ||||
| import fr.univ_amu.iut.model.Niveau; | ||||
| import fr.univ_amu.iut.model.Thematique; | ||||
| @ -9,10 +9,8 @@ import javafx.scene.Node; | ||||
| import javafx.scene.Scene; | ||||
| import javafx.scene.control.Button; | ||||
| import javafx.scene.control.TableView; | ||||
| import javafx.scene.layout.Background; | ||||
| import javafx.scene.layout.Pane; | ||||
| import javafx.stage.Stage; | ||||
| import javafx.stage.Window; | ||||
| import org.junit.jupiter.api.BeforeEach; | ||||
| import org.junit.jupiter.api.Test; | ||||
| import org.junit.jupiter.api.extension.ExtendWith; | ||||
| @ -21,8 +19,6 @@ import org.testfx.framework.junit5.ApplicationExtension; | ||||
| import org.testfx.framework.junit5.ApplicationTest; | ||||
| import org.testfx.framework.junit5.Start; | ||||
| 
 | ||||
| import java.util.Iterator; | ||||
| 
 | ||||
| import static org.assertj.core.api.Assertions.assertThat; | ||||
| 
 | ||||
| @ExtendWith(ApplicationExtension.class) | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user