diff --git a/.gitattributes b/.gitattributes
deleted file mode 100644
index dfe0770..0000000
--- a/.gitattributes
+++ /dev/null
@@ -1,2 +0,0 @@
-# Auto detect text files and perform LF normalization
-* text=auto
diff --git a/Dynamic-Developers/Lib/TrayNotification-5393c3a54f.jar b/Dynamic-Developers/Lib/TrayNotification-5393c3a54f.jar
deleted file mode 100644
index 8b0a564..0000000
Binary files a/Dynamic-Developers/Lib/TrayNotification-5393c3a54f.jar and /dev/null differ
diff --git a/Dynamic-Developers/Lib/TrayTester.jar b/Dynamic-Developers/Lib/TrayTester.jar
deleted file mode 100644
index 98353ef..0000000
Binary files a/Dynamic-Developers/Lib/TrayTester.jar and /dev/null differ
diff --git a/Dynamic-Developers/Lib/itext-1.3.1.jar b/Dynamic-Developers/Lib/itext-1.3.1.jar
deleted file mode 100644
index 420214f..0000000
Binary files a/Dynamic-Developers/Lib/itext-1.3.1.jar and /dev/null differ
diff --git a/Dynamic-Developers/Lib/itextpdf-5.5.9.jar b/Dynamic-Developers/Lib/itextpdf-5.5.9.jar
deleted file mode 100644
index e622bdf..0000000
Binary files a/Dynamic-Developers/Lib/itextpdf-5.5.9.jar and /dev/null differ
diff --git a/Dynamic-Developers/Lib/poi-1.8.0-dev-20020919.jar b/Dynamic-Developers/Lib/poi-1.8.0-dev-20020919.jar
deleted file mode 100644
index 4fa58e3..0000000
Binary files a/Dynamic-Developers/Lib/poi-1.8.0-dev-20020919.jar and /dev/null differ
diff --git a/Dynamic-Developers/Lib/poi-5.2.0.jar b/Dynamic-Developers/Lib/poi-5.2.0.jar
deleted file mode 100644
index 58bbab0..0000000
Binary files a/Dynamic-Developers/Lib/poi-5.2.0.jar and /dev/null differ
diff --git a/Dynamic-Developers/Lib/poi-ooxml-3.9.jar b/Dynamic-Developers/Lib/poi-ooxml-3.9.jar
deleted file mode 100644
index 8792d46..0000000
Binary files a/Dynamic-Developers/Lib/poi-ooxml-3.9.jar and /dev/null differ
diff --git a/Dynamic-Developers/Voyage.csv b/Dynamic-Developers/Voyage.csv
deleted file mode 100644
index e69de29..0000000
diff --git a/Dynamic-Developers/build/built-jar.properties b/Dynamic-Developers/build/built-jar.properties
deleted file mode 100644
index b78ec06..0000000
--- a/Dynamic-Developers/build/built-jar.properties
+++ /dev/null
@@ -1,4 +0,0 @@
-#Tue, 19 Apr 2022 01:23:21 +0100
-
-
-C\:\\Users\\ASUS\\OneDrive\\Documents\\NetBeansProjects\\Dynamic-Developers=
diff --git a/Dynamic-Developers/build/classes/Entity/ReserverVoyage.class b/Dynamic-Developers/build/classes/Entity/ReserverVoyage.class
deleted file mode 100644
index 83f1f09..0000000
Binary files a/Dynamic-Developers/build/classes/Entity/ReserverVoyage.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Entity/voyage.class b/Dynamic-Developers/build/classes/Entity/voyage.class
deleted file mode 100644
index 9b2e1fa..0000000
Binary files a/Dynamic-Developers/build/classes/Entity/voyage.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/Home$1.class b/Dynamic-Developers/build/classes/Gui/Home$1.class
deleted file mode 100644
index 0644680..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/Home$1.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/Home.class b/Dynamic-Developers/build/classes/Gui/Home.class
deleted file mode 100644
index c76cdbc..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/Home.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/Media_Voyage.fxml b/Dynamic-Developers/build/classes/Gui/Media_Voyage.fxml
deleted file mode 100644
index dc184eb..0000000
--- a/Dynamic-Developers/build/classes/Gui/Media_Voyage.fxml
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/build/classes/Gui/Media_VoyageController$1.class b/Dynamic-Developers/build/classes/Gui/Media_VoyageController$1.class
deleted file mode 100644
index 45ac2e1..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/Media_VoyageController$1.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/Media_VoyageController.class b/Dynamic-Developers/build/classes/Gui/Media_VoyageController.class
deleted file mode 100644
index afb97cf..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/Media_VoyageController.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/MenuDynamicDevelopers.fxml b/Dynamic-Developers/build/classes/Gui/MenuDynamicDevelopers.fxml
deleted file mode 100644
index 0689e97..0000000
--- a/Dynamic-Developers/build/classes/Gui/MenuDynamicDevelopers.fxml
+++ /dev/null
@@ -1,47 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/build/classes/Gui/MenuDynamicDevelopersController.class b/Dynamic-Developers/build/classes/Gui/MenuDynamicDevelopersController.class
deleted file mode 100644
index eb10e81..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/MenuDynamicDevelopersController.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/ReserverVoyageController.class b/Dynamic-Developers/build/classes/Gui/ReserverVoyageController.class
deleted file mode 100644
index fe62974..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/ReserverVoyageController.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/Reservevoyage.fxml b/Dynamic-Developers/build/classes/Gui/Reservevoyage.fxml
deleted file mode 100644
index 82d0fc6..0000000
--- a/Dynamic-Developers/build/classes/Gui/Reservevoyage.fxml
+++ /dev/null
@@ -1,63 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/build/classes/Gui/ReservevoyageController.class b/Dynamic-Developers/build/classes/Gui/ReservevoyageController.class
deleted file mode 100644
index 50a7b72..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/ReservevoyageController.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/Style.css b/Dynamic-Developers/build/classes/Gui/Style.css
deleted file mode 100644
index 0d07719..0000000
--- a/Dynamic-Developers/build/classes/Gui/Style.css
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * Empty Stylesheet file.
- */
-
-.menuItem:hover{
- -fx-border-color: #660099;
- -fx-border-width: 0px 0px 3px 0px;
-}
-
-.sidebarItem:hover{
- -fx-background-color: #146886;
- -fx-border-color: WHITE;
- -fx-border-width: 0px 0px 0px 3px;
-}
-
-.search-box{
- -fx-background-color:#FFFFFF;
- -fx-background-radius: 100;
-}
-
-.transparent{
- -fx-background-color: rgba(0,0,0,0);
-}
-
-.search-button{
- -fx-background-color: #828282;
- -fx-background-radius: 30;
-}
-
-.right-bar{
- -fx-background-color: #D3D3D3;
-}
-
-.shadow{
- -fx-effect: dropShadow(three-pass-box,rgba(0,0,0,0.1), 10.0 , 0.0 , 0.0 ,10.0);
-}
-
-.chosen-fruit-card{
- -fx-background-color: #F16C31;
- -fx-background-radius: 30;
-}
-
-.comboBox{
- -fx-background-color: rgba(255,255,255,0.3);
- -fx-background-radius: 30;
-}
-
-.add-btn{
- -fx-background-color: #FFFFFF;
- -fx-background-radius: 100;
-}
-
-.free-delivery-card{
- -fx-background-color: #D3D3D3;
- -fx-background-radius: 30;
-}
-
-.shopping-online-card{
- -fx-background-color: #BAEAC3;
- -fx-background-radius: 30;
-}
-
-.fruit-item{
- -fx-background-color: #FFFFFF;
- -fx-background-radius: 30;
-}
-
-.transparent{
- -fx-background-color: rgba(0,0,0,0);
-}
diff --git a/Dynamic-Developers/build/classes/Gui/Voyage.fxml b/Dynamic-Developers/build/classes/Gui/Voyage.fxml
deleted file mode 100644
index 8325dd7..0000000
--- a/Dynamic-Developers/build/classes/Gui/Voyage.fxml
+++ /dev/null
@@ -1,97 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/build/classes/Gui/VoyageController$1.class b/Dynamic-Developers/build/classes/Gui/VoyageController$1.class
deleted file mode 100644
index 6e62d4f..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/VoyageController$1.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/VoyageController$2.class b/Dynamic-Developers/build/classes/Gui/VoyageController$2.class
deleted file mode 100644
index 6bb4fab..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/VoyageController$2.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/VoyageController$3.class b/Dynamic-Developers/build/classes/Gui/VoyageController$3.class
deleted file mode 100644
index 57b6d2a..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/VoyageController$3.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/VoyageController$4.class b/Dynamic-Developers/build/classes/Gui/VoyageController$4.class
deleted file mode 100644
index 3b28d11..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/VoyageController$4.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/VoyageController.class b/Dynamic-Developers/build/classes/Gui/VoyageController.class
deleted file mode 100644
index cdaa669..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/VoyageController.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/VoyageStat.fxml b/Dynamic-Developers/build/classes/Gui/VoyageStat.fxml
deleted file mode 100644
index 0d73d77..0000000
--- a/Dynamic-Developers/build/classes/Gui/VoyageStat.fxml
+++ /dev/null
@@ -1,17 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/build/classes/Gui/VoyageStatController.class b/Dynamic-Developers/build/classes/Gui/VoyageStatController.class
deleted file mode 100644
index 0cc3ec8..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/VoyageStatController.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/VoyageStatPrix.fxml b/Dynamic-Developers/build/classes/Gui/VoyageStatPrix.fxml
deleted file mode 100644
index d7ff6c8..0000000
--- a/Dynamic-Developers/build/classes/Gui/VoyageStatPrix.fxml
+++ /dev/null
@@ -1,18 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/build/classes/Gui/VoyageStatPrixController.class b/Dynamic-Developers/build/classes/Gui/VoyageStatPrixController.class
deleted file mode 100644
index 41c3e4e..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/VoyageStatPrixController.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/VoyageStatValabilite.fxml b/Dynamic-Developers/build/classes/Gui/VoyageStatValabilite.fxml
deleted file mode 100644
index 9c48e13..0000000
--- a/Dynamic-Developers/build/classes/Gui/VoyageStatValabilite.fxml
+++ /dev/null
@@ -1,17 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/build/classes/Gui/VoyageStatValabiliteController.class b/Dynamic-Developers/build/classes/Gui/VoyageStatValabiliteController.class
deleted file mode 100644
index c980afd..0000000
Binary files a/Dynamic-Developers/build/classes/Gui/VoyageStatValabiliteController.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Gui/googleMaps.html b/Dynamic-Developers/build/classes/Gui/googleMaps.html
deleted file mode 100644
index b2d71fd..0000000
--- a/Dynamic-Developers/build/classes/Gui/googleMaps.html
+++ /dev/null
@@ -1,73 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/Dynamic-Developers/build/classes/Img/bg.jpg b/Dynamic-Developers/build/classes/Img/bg.jpg
deleted file mode 100644
index d866db0..0000000
Binary files a/Dynamic-Developers/build/classes/Img/bg.jpg and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Service/IServise.class b/Dynamic-Developers/build/classes/Service/IServise.class
deleted file mode 100644
index 9045535..0000000
Binary files a/Dynamic-Developers/build/classes/Service/IServise.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Service/IServiseReserVoy.class b/Dynamic-Developers/build/classes/Service/IServiseReserVoy.class
deleted file mode 100644
index d5e8a01..0000000
Binary files a/Dynamic-Developers/build/classes/Service/IServiseReserVoy.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Service/Scontrole_Voyage.class b/Dynamic-Developers/build/classes/Service/Scontrole_Voyage.class
deleted file mode 100644
index 9c060d7..0000000
Binary files a/Dynamic-Developers/build/classes/Service/Scontrole_Voyage.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Service/ServiceVoyage.class b/Dynamic-Developers/build/classes/Service/ServiceVoyage.class
deleted file mode 100644
index 9a747fe..0000000
Binary files a/Dynamic-Developers/build/classes/Service/ServiceVoyage.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Service/ServiseReserVoy.class b/Dynamic-Developers/build/classes/Service/ServiseReserVoy.class
deleted file mode 100644
index 3c02db9..0000000
Binary files a/Dynamic-Developers/build/classes/Service/ServiseReserVoy.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/Util/MyDB.class b/Dynamic-Developers/build/classes/Util/MyDB.class
deleted file mode 100644
index 552a25a..0000000
Binary files a/Dynamic-Developers/build/classes/Util/MyDB.class and /dev/null differ
diff --git a/Dynamic-Developers/build/classes/dynamic/developers/DynamicDevelopers.class b/Dynamic-Developers/build/classes/dynamic/developers/DynamicDevelopers.class
deleted file mode 100644
index 2926078..0000000
Binary files a/Dynamic-Developers/build/classes/dynamic/developers/DynamicDevelopers.class and /dev/null differ
diff --git a/Dynamic-Developers/dist/Dynamic-Developers.jar b/Dynamic-Developers/dist/Dynamic-Developers.jar
deleted file mode 100644
index 2407ef7..0000000
Binary files a/Dynamic-Developers/dist/Dynamic-Developers.jar and /dev/null differ
diff --git a/Dynamic-Developers/dist/README.TXT b/Dynamic-Developers/dist/README.TXT
deleted file mode 100644
index 310ef0b..0000000
--- a/Dynamic-Developers/dist/README.TXT
+++ /dev/null
@@ -1,32 +0,0 @@
-========================
-BUILD OUTPUT DESCRIPTION
-========================
-
-When you build an Java application project that has a main class, the IDE
-automatically copies all of the JAR
-files on the projects classpath to your projects dist/lib folder. The IDE
-also adds each of the JAR files to the Class-Path element in the application
-JAR files manifest file (MANIFEST.MF).
-
-To run the project from the command line, go to the dist folder and
-type the following:
-
-java -jar "Dynamic-Developers.jar"
-
-To distribute this project, zip up the dist folder (including the lib folder)
-and distribute the ZIP file.
-
-Notes:
-
-* If two JAR files on the project classpath have the same name, only the first
-JAR file is copied to the lib folder.
-* Only JAR files are copied to the lib folder.
-If the classpath contains other types of files or folders, these files (folders)
-are not copied.
-* If a library on the projects classpath also has a Class-Path element
-specified in the manifest,the content of the Class-Path element has to be on
-the projects runtime path.
-* To set a main class in a standard Java project, right-click the project node
-in the Projects window and choose Properties. Then click Run and enter the
-class name in the Main Class field. Alternatively, you can manually type the
-class name in the manifest Main-Class element.
diff --git a/Dynamic-Developers/nbproject/private/private.properties b/Dynamic-Developers/nbproject/private/private.properties
deleted file mode 100644
index d6d76f6..0000000
--- a/Dynamic-Developers/nbproject/private/private.properties
+++ /dev/null
@@ -1,2 +0,0 @@
-compile.on.save=true
-user.properties.file=C:\\Users\\ASUS\\AppData\\Roaming\\NetBeans\\8.2\\build.properties
diff --git a/Dynamic-Developers/nbproject/private/private.xml b/Dynamic-Developers/nbproject/private/private.xml
deleted file mode 100644
index 4072570..0000000
--- a/Dynamic-Developers/nbproject/private/private.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-
-
-
-
-
- file:/C:/Users/ASUS/OneDrive/Documents/NetBeansProjects/Dynamic-Developers/src/Gui/MenuDynamicDevelopersController.java
- file:/C:/Users/ASUS/OneDrive/Documents/NetBeansProjects/Dynamic-Developers/src/Gui/ReservevoyageController.java
- file:/C:/Users/ASUS/OneDrive/Documents/NetBeansProjects/Dynamic-Developers/src/Service/ServiseReserVoy.java
- file:/C:/Users/ASUS/OneDrive/Documents/NetBeansProjects/Dynamic-Developers/src/Service/ServiceVoyage.java
- file:/C:/Users/ASUS/OneDrive/Documents/NetBeansProjects/Dynamic-Developers/src/Gui/VoyageController.java
-
-
-
diff --git a/Dynamic-Developers/nbproject/project.properties b/Dynamic-Developers/nbproject/project.properties
deleted file mode 100644
index c22b1eb..0000000
--- a/Dynamic-Developers/nbproject/project.properties
+++ /dev/null
@@ -1,89 +0,0 @@
-annotation.processing.enabled=true
-annotation.processing.enabled.in.editor=false
-annotation.processing.processor.options=
-annotation.processing.processors.list=
-annotation.processing.run.all.processors=true
-annotation.processing.source.output=${build.generated.sources.dir}/ap-source-output
-build.classes.dir=${build.dir}/classes
-build.classes.excludes=**/*.java,**/*.form
-# This directory is removed when the project is cleaned:
-build.dir=build
-build.generated.dir=${build.dir}/generated
-build.generated.sources.dir=${build.dir}/generated-sources
-# Only compile against the classpath explicitly listed here:
-build.sysclasspath=ignore
-build.test.classes.dir=${build.dir}/test/classes
-build.test.results.dir=${build.dir}/test/results
-# Uncomment to specify the preferred debugger connection transport:
-#debug.transport=dt_socket
-debug.classpath=\
- ${run.classpath}
-debug.test.classpath=\
- ${run.test.classpath}
-# Files in build.classes.dir which should be excluded from distribution jar
-dist.archive.excludes=
-# This directory is removed when the project is cleaned:
-dist.dir=dist
-dist.jar=${dist.dir}/Dynamic-Developers.jar
-dist.javadoc.dir=${dist.dir}/javadoc
-excludes=
-file.reference.itext-1.3.1.jar=Lib\\itext-1.3.1.jar
-file.reference.itextpdf-5.5.9.jar=Lib\\itextpdf-5.5.9.jar
-file.reference.poi-1.8.0-dev-20020919.jar=Lib\\poi-1.8.0-dev-20020919.jar
-file.reference.poi-5.2.0.jar=Lib\\poi-5.2.0.jar
-file.reference.poi-ooxml-3.9.jar=Lib\\poi-ooxml-3.9.jar
-file.reference.TrayNotification-5393c3a54f.jar=Lib\\TrayNotification-5393c3a54f.jar
-file.reference.TrayTester.jar=Lib\\TrayTester.jar
-includes=**
-jar.compress=false
-javac.classpath=\
- ${libs.MySQLDriver.classpath}:\
- ${file.reference.itext-1.3.1.jar}:\
- ${file.reference.itextpdf-5.5.9.jar}:\
- ${file.reference.poi-1.8.0-dev-20020919.jar}:\
- ${file.reference.poi-5.2.0.jar}:\
- ${file.reference.poi-ooxml-3.9.jar}:\
- ${file.reference.TrayNotification-5393c3a54f.jar}:\
- ${file.reference.TrayTester.jar}
-# Space-separated list of extra javac options
-javac.compilerargs=
-javac.deprecation=false
-javac.external.vm=true
-javac.processorpath=\
- ${javac.classpath}
-javac.source=1.8
-javac.target=1.8
-javac.test.classpath=\
- ${javac.classpath}:\
- ${build.classes.dir}
-javac.test.processorpath=\
- ${javac.test.classpath}
-javadoc.additionalparam=
-javadoc.author=false
-javadoc.encoding=${source.encoding}
-javadoc.noindex=false
-javadoc.nonavbar=false
-javadoc.notree=false
-javadoc.private=false
-javadoc.splitindex=true
-javadoc.use=true
-javadoc.version=false
-javadoc.windowtitle=
-main.class=Gui.Home
-manifest.file=manifest.mf
-meta.inf.dir=${src.dir}/META-INF
-mkdist.disabled=false
-platform.active=default_platform
-run.classpath=\
- ${javac.classpath}:\
- ${build.classes.dir}
-# Space-separated list of JVM arguments used when running the project.
-# You may also define separate properties like run-sys-prop.name=value instead of -Dname=value.
-# To set system properties for unit tests define test-sys-prop.name=value:
-run.jvmargs=
-run.test.classpath=\
- ${javac.test.classpath}:\
- ${build.test.classes.dir}
-source.encoding=UTF-8
-src.dir=src
-test.src.dir=test
diff --git a/Dynamic-Developers/nbproject/project.xml b/Dynamic-Developers/nbproject/project.xml
deleted file mode 100644
index 4d3e63b..0000000
--- a/Dynamic-Developers/nbproject/project.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-
-
- org.netbeans.modules.java.j2seproject
-
-
- Dynamic-Developers
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/src/Entity/ReserverVoyage.java b/Dynamic-Developers/src/Entity/ReserverVoyage.java
deleted file mode 100644
index 4ee7083..0000000
--- a/Dynamic-Developers/src/Entity/ReserverVoyage.java
+++ /dev/null
@@ -1,118 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Entity;
-
-import java.sql.Date;
-
-/**
- *
- * @author ASUS
- */
-public class ReserverVoyage {
- int Client,id;
- int voyage_id ;
- String Nom_voyage,travel_Class;
- Date date_reservation;
- int Age;
-
- public ReserverVoyage(int id, String Nom_voyage, Date date_reservation, String travel_Class, int Age) {
- this.id = id;
- this.Nom_voyage = Nom_voyage;
- this.date_reservation = date_reservation;
- this.travel_Class = travel_Class;
- this.Age = Age;
- }
-
- public ReserverVoyage(int voyage_id, String travel_Class, Date date_reservation, int Age) {
- this.voyage_id = voyage_id;
- this.travel_Class = travel_Class;
- this.date_reservation = date_reservation;
- this.Age = Age;
- }
-
-
-
- public ReserverVoyage(String Nom_voyage, String Travel_Class,Date date_reservation, int Age) {
- // this.Client = Client;
- this.Nom_voyage = Nom_voyage;
- this.travel_Class = Travel_Class;
- this.date_reservation = date_reservation;
- this.Age = Age;
- }
-
- public ReserverVoyage(int id, int Client, int voyage_id, String Travel_Class,Date date_reservation, int Age) {
- this.Client = Client;
- this.id = id;
- this.voyage_id = voyage_id;
- this.travel_Class = Travel_Class;
- this.date_reservation = date_reservation;
- this.Age = Age;
- }
-
- public ReserverVoyage() {
- }
-
- @Override
- public String toString() {
- return "ReserverVoyage{" + "Client=" + Client + ", id=" + id + ", Nom_voyage=" + Nom_voyage + ", date_reservation=" + date_reservation + ", Travel_Class=" + travel_Class + ", Age=" + Age + '}';
- }
-
- public int getVoyage_id() {
- return voyage_id;
- }
-
- public void setVoyage_id(int voyage_id) {
- this.voyage_id = voyage_id;
- }
-
- public Date getDate_reservation() {
- return date_reservation;
- }
-
- public void setDate_reservation(Date date_reservation) {
- this.date_reservation = date_reservation;
- }
-
- public int getClient() {
- return Client;
- }
-
- public void setClient(int Client) {
- this.Client = Client;
- }
-
- public int getId() {
- return id;
- }
-
- public void setId(int id) {
- this.id = id;
- }
-
- public String getNom_voyage() {
- return Nom_voyage;
- }
-
- public void setNom_voyage(String Nom_voyage) {
- this.Nom_voyage = Nom_voyage;
- }
-
- public String getTravel_Class() {
- return travel_Class;
- }
-
- public void setTravel_Class(String travel_Class) {
- this.travel_Class = travel_Class;
- }
-
- public int getAge() {
- return Age;
- }
-
- public void setAge(int Age) {
- this.Age = Age;
- }
-}
diff --git a/Dynamic-Developers/src/Entity/voyage.java b/Dynamic-Developers/src/Entity/voyage.java
deleted file mode 100644
index f10425c..0000000
--- a/Dynamic-Developers/src/Entity/voyage.java
+++ /dev/null
@@ -1,119 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Entity;
-
-import java.sql.Date;
-
-
-/**
- *
- * @author ASUS
- */
-public class voyage {
- int ID;
- String destination,nom_voyage,duree_voyage,valabilite,image;
- Date date;
- float prix;
-
- public voyage(String destination, String nom_voyage, String duree_voyage,Date date, String valabilite, String image, float prix) {
- this.destination = destination;
- this.nom_voyage = nom_voyage;
- this.duree_voyage = duree_voyage;
- this.date = date;
- this.valabilite = valabilite;
- this.image = image;
- this.prix = prix;
- }
-
- public voyage(int ID, String destination, String nom_voyage, String duree_voyage,Date date, String valabilite, String image, float prix) {
- this.ID = ID;
- this.destination = destination;
- this.nom_voyage = nom_voyage;
- this.duree_voyage = duree_voyage;
- this.date = date;
- this.valabilite = valabilite;
- this.image = image;
- this.prix = prix;
- }
-
- public voyage() {
- }
-
-public static String pathfile;
- public static String filename="";
-
- @Override
- public String toString() {
- return "voyage{" + "ID=" + ID + ", destination=" + destination + ", nom_voyage=" + nom_voyage + ", duree_voyage=" + duree_voyage + ", valabilite=" + valabilite + ", image=" + image + ", date=" + date + ", prix=" + prix + '}';
- }
-
- public Date getDate() {
- return date;
- }
-
- public void setDate(Date date) {
- this.date = date;
- }
-
-
- public String getDestination() {
- return destination;
- }
-
- public void setDestination(String destination) {
- this.destination = destination;
- }
-
- public String getNom_voyage() {
- return nom_voyage;
- }
-
- public void setNom_voyage(String nom_voyage) {
- this.nom_voyage = nom_voyage;
- }
-
- public String getDuree_voyage() {
- return duree_voyage;
- }
-
- public void setDuree_voyage(String duree_voyage) {
- this.duree_voyage = duree_voyage;
- }
-
- public String getValabilite() {
- return valabilite;
- }
-
- public void setValabilite(String valabilite) {
- this.valabilite = valabilite;
- }
-
- public String getImage() {
- return image;
- }
-
- public void setImage(String image) {
- this.image = image;
- }
-
- public int getID() {
- return ID;
- }
-
- public void setID(int ID) {
- this.ID = ID;
- }
-
- public float getPrix() {
- return prix;
- }
-
- public void setPrix(float prix) {
- this.prix = prix;
- }
-
-
-}
diff --git a/Dynamic-Developers/src/Gui/Media_Voyage.fxml b/Dynamic-Developers/src/Gui/Media_Voyage.fxml
deleted file mode 100644
index dc184eb..0000000
--- a/Dynamic-Developers/src/Gui/Media_Voyage.fxml
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/src/Gui/Media_VoyageController.java b/Dynamic-Developers/src/Gui/Media_VoyageController.java
deleted file mode 100644
index 118c53e..0000000
--- a/Dynamic-Developers/src/Gui/Media_VoyageController.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Gui;
-
-import java.io.File;
-import java.io.IOException;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.ResourceBundle;
-import javafx.beans.InvalidationListener;
-import javafx.beans.Observable;
-import javafx.event.ActionEvent;
-import javafx.fxml.FXML;
-import javafx.fxml.FXMLLoader;
-import javafx.fxml.Initializable;
-import javafx.scene.Node;
-import javafx.scene.Parent;
-import javafx.scene.Scene;
-import javafx.scene.control.Button;
-import javafx.scene.control.Slider;
-import javafx.scene.input.MouseEvent;
-import javafx.scene.media.Media;
-import javafx.scene.media.MediaPlayer;
-import javafx.scene.media.MediaView;
-import javafx.scene.web.WebView;
-import javafx.stage.Stage;
-
-/**
- * FXML Controller class
- *
- * @author ASUS
- */
-public class Media_VoyageController implements Initializable {
-
- @FXML
- private MediaView mediaview;
- @FXML
- private Slider volume;
- @FXML
- private Button play;
- @FXML
- private Button pause;
- @FXML
- private Button stop;
- private MediaPlayer mediaplayer;
- private Media media;
- public static String videoName;
- @FXML
- private Button Go_Back;
-
- /**
- * Initializes the controller class.
- */
- @Override
- public void initialize(URL url, ResourceBundle rb) {
- // TODO
- try{
- String videoname = null;
- String path = new File("src/video/" + videoname + ".mp4").getAbsolutePath();
- File mediaFile = new File("C:\\Users\\ASUS\\Downloads\\Ciel et Nuages Zoom Virtuel Arrière-plan.mp4");
- Media media = new Media(mediaFile.toURI().toURL().toString());
- mediaplayer = new MediaPlayer(media);
- mediaview.setMediaPlayer(mediaplayer);
- volume.setValue(mediaplayer.getVolume() * 50);
-
- volume.valueProperty().addListener(new InvalidationListener() {
-
-
- @Override
- public void invalidated(Observable observable) {
- mediaplayer.setVolume(volume.getValue() / 100);
-
- }
-
- });
- } catch (MalformedURLException ex) {
- System.out.println(ex.getMessage());
- }
- }
-
- @FXML
- private void click(MouseEvent event) {
- }
-
- @FXML
- private void play(ActionEvent event) {
- mediaplayer.play();
- }
-
- @FXML
- private void pause(ActionEvent event) {
- mediaplayer.pause();
- }
-
- @FXML
- private void stop(ActionEvent event) {
- mediaplayer.seek(mediaplayer.getStartTime());
- mediaplayer.stop();
- }
-
- @FXML
- private void Go_Back_Home(ActionEvent event) throws IOException {
- Parent root = FXMLLoader.load(getClass().getResource("Voyage.fxml"));
- Scene scene = new Scene(root);
- Stage stage = (Stage) ((Node) event.getSource()).getScene().getWindow();
- stage.setScene(scene);
- stage.show();
- }
-
-}
diff --git a/Dynamic-Developers/src/Gui/MenuDynamicDevelopers.fxml b/Dynamic-Developers/src/Gui/MenuDynamicDevelopers.fxml
deleted file mode 100644
index 0689e97..0000000
--- a/Dynamic-Developers/src/Gui/MenuDynamicDevelopers.fxml
+++ /dev/null
@@ -1,47 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/src/Gui/MenuDynamicDevelopersController.java b/Dynamic-Developers/src/Gui/MenuDynamicDevelopersController.java
deleted file mode 100644
index 6440217..0000000
--- a/Dynamic-Developers/src/Gui/MenuDynamicDevelopersController.java
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Gui;
-
-import java.io.IOException;
-import java.net.URL;
-import java.util.ResourceBundle;
-import javafx.event.ActionEvent;
-import javafx.fxml.FXML;
-import javafx.fxml.FXMLLoader;
-import javafx.fxml.Initializable;
-import javafx.scene.Node;
-import javafx.scene.Parent;
-import javafx.scene.Scene;
-import javafx.scene.control.Button;
-import javafx.scene.image.ImageView;
-import javafx.stage.Stage;
-
-/**
- * FXML Controller class
- *
- * @author ASUS
- */
-public class MenuDynamicDevelopersController implements Initializable {
-
- @FXML
- private ImageView ImageP;
- @FXML
- private Button Voyage;
- @FXML
- private Button ReserverVoyage;
- @FXML
- private Button Restaurant;
- @FXML
- private Button Excursion;
- @FXML
- private Button ReserverRestaurant;
- @FXML
- private Button ReserverExcursion;
-
- /**
- * Initializes the controller class.
- */
- @Override
- public void initialize(URL url, ResourceBundle rb) {
- // TODO
- }
-
- @FXML
- private void Voyage(ActionEvent event) throws IOException {
- try {
-
- Parent root = FXMLLoader.load(getClass().getResource("/Gui/Voyage.fxml"));
- Scene scene = new Scene(root);
- Stage stage = (Stage) ((Node) event.getSource()).getScene().getWindow();
- stage.setScene(scene);
- stage.show();
- } catch (IOException ex) {
- System.err.println(ex.getMessage());
- }
- }
-
- @FXML
- private void ReserverVoyage(ActionEvent event) {
- try {
-
- Parent root = FXMLLoader.load(getClass().getResource("/Gui/Reservevoyage.fxml"));
- Scene scene = new Scene(root);
- Stage stage = (Stage) ((Node) event.getSource()).getScene().getWindow();
- stage.setScene(scene);
- stage.show();
- } catch (IOException ex) {
- System.err.println(ex.getMessage());
- }
- }
-
- @FXML
- private void Excursion(ActionEvent event) {
- }
-
- @FXML
- private void ReserverRestaurant(ActionEvent event) {
- }
-
- @FXML
- private void ReserverExcursion(ActionEvent event) {
- }
-
- @FXML
- private void Restaurant(ActionEvent event) {
- }
- }
-
-
diff --git a/Dynamic-Developers/src/Gui/ReserverVoyageController.java b/Dynamic-Developers/src/Gui/ReserverVoyageController.java
deleted file mode 100644
index 0a9d264..0000000
--- a/Dynamic-Developers/src/Gui/ReserverVoyageController.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Gui;
-
-import Entity.ReserverVoyage;
-import Entity.voyage;
-import Service.Scontrole_Voyage;
-import Service.ServiceVoyage;
-import java.net.URL;
-import java.sql.Date;
-import java.util.ResourceBundle;
-import javafx.event.ActionEvent;
-import javafx.fxml.FXML;
-import javafx.fxml.Initializable;
-import javafx.scene.control.Alert;
-import javafx.scene.control.Button;
-import javafx.scene.control.ComboBox;
-import javafx.scene.control.TableColumn;
-import javafx.scene.control.TableView;
-import javafx.scene.control.TextField;
-import javafx.scene.image.ImageView;
-
-/**
- * FXML Controller class
- *
- * @author ASUS
- */
-public class ReserverVoyageController implements Initializable {
-
- @FXML
- private ImageView ImageP;
- @FXML
- private TableView Tabelreservation;
- @FXML
- private TableColumn Voyage;
- @FXML
- private TableColumn Date;
- @FXML
- private TableColumn Age;
- @FXML
- private Button Add;
- @FXML
- private Button Modifier;
- @FXML
- private Button Supprimer;
- @FXML
- private TextField age;
- @FXML
- private ComboBox> Trravel_class;
-
- /**
- * Initializes the controller class.
- */
- @Override
- public void initialize(URL url, ResourceBundle rb) {
- // TODO
- }
-
- @FXML
- private void Add(ActionEvent event) {
- /* String Destinationv = Destination.getText();
- String Nom_Voyagev = Nom_Voyage.getText();
- String Duree_Voyagev = Duree_Voyage.getText();
- Date Datevoy= Date.valueOf(Datev.getValue());
- // String Valabilitev = Valabilite.getText();
- String Valabilitev = (String)combox.getValue();
-
- String agev=age.getText();
- System.out.println(Datevoy);
- Scontrole_Voyage sc= new Scontrole_Voyage();
- ServiceVoyage ps = new ServiceVoyage();
-
- voyage v = new voyage(Destinationv,Nom_Voyagev,Duree_Voyagev,Datevoy,Valabilitev,URLImage.getText(),Float.parseFloat(Prixv));
-
- System.out.println(sc.isNumeric(Prixv));
-
- if( Destinationv.isEmpty()){
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("champs vides");
- alert.showAndWait();
- }else if (! sc.isNumeric(Prix.getText())){
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("Prixv doit étre un nombre");
- alert.showAndWait();
- }
- else {
- ps.AjouterVoyage(v);
- refresh();
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("Voyage ajouter");
- alert.showAndWait();
- }*/
- }
-
- @FXML
- private void Modifier(ActionEvent event) {
- }
-
- @FXML
- private void Supprimer(ActionEvent event) {
- }
-
-}
diff --git a/Dynamic-Developers/src/Gui/Reservevoyage.fxml b/Dynamic-Developers/src/Gui/Reservevoyage.fxml
deleted file mode 100644
index 82d0fc6..0000000
--- a/Dynamic-Developers/src/Gui/Reservevoyage.fxml
+++ /dev/null
@@ -1,63 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/src/Gui/ReservevoyageController.java b/Dynamic-Developers/src/Gui/ReservevoyageController.java
deleted file mode 100644
index d1aa63b..0000000
--- a/Dynamic-Developers/src/Gui/ReservevoyageController.java
+++ /dev/null
@@ -1,296 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Gui;
-
-import Entity.ReserverVoyage;
-import Entity.voyage;
-import Service.Scontrole_Voyage;
-import Service.ServiceVoyage;
-import java.lang.AutoCloseable;
-
-import Service.ServiseReserVoy;
-import Util.MyDB;
-import java.io.File;
-import java.io.IOException;
-import java.net.URL;
-import java.sql.Connection;
-import java.sql.Date;
-import java.sql.PreparedStatement;
-import java.sql.ResultSet;
-import java.sql.SQLException;
-import java.util.ResourceBundle;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-import javafx.collections.FXCollections;
-import javafx.collections.ObservableList;
-import javafx.event.ActionEvent;
-import javafx.event.EventHandler;
-import javafx.fxml.FXML;
-import javafx.fxml.FXMLLoader;
-import javafx.fxml.Initializable;
-import javafx.geometry.Pos;
-import javafx.scene.Node;
-import javafx.scene.Parent;
-import javafx.scene.Scene;
-import javafx.scene.control.Alert;
-import javafx.scene.control.Button;
-import javafx.scene.control.ButtonType;
-import javafx.scene.control.ComboBox;
-import javafx.scene.control.DatePicker;
-import javafx.scene.control.TableColumn;
-import javafx.scene.control.TableView;
-import javafx.scene.control.TextField;
-import javafx.scene.control.cell.PropertyValueFactory;
-import javafx.scene.image.Image;
-import javafx.scene.image.ImageView;
-import javafx.scene.input.KeyEvent;
-import javafx.scene.input.MouseEvent;
-import javafx.stage.Stage;
-
-/**
- * FXML Controller class
- *
- * @author ASUS
- */
-public class ReservevoyageController implements Initializable {
-
- ObservableList List = FXCollections.observableArrayList();
-
- @FXML
- private ImageView ImageP;
- @FXML
- private TableView TableVoyage;
- @FXML
- private Button Supprimerreservation;
- @FXML
- private Button Actualiser;
- @FXML
- private Button Add;
- @FXML
- private TextField Age;
- @FXML
- private DatePicker Datev;
- @FXML
- private Button Modreservation;
- @FXML
- private ComboBox Travel_ComboBox;
- @FXML
- private TextField Recherche;
- @FXML
- private ComboBox VoyageCombox;
- @FXML
- private Button Clear;
- String query = null;
- Connection connection = null ;
- Connection cnx=MyDB.getInsatnce().getConnection();
- PreparedStatement preparedStatement = null ;
- ResultSet resultSet = null ;
- @FXML
- private TableColumn Dest;
- @FXML
- private TableColumn date;
- @FXML
- private TableColumn Rage;
- @FXML
- private TableColumn VID;
- @FXML
- private TableColumn Tra_class;
- @FXML
- private Button Menu;
- @FXML
- private Button Menu1;
- @FXML
- private Button Menu11;
- /**
- * Initializes the controller class.
- */
- @Override
- public void initialize(URL url, ResourceBundle rb) {
- // TODO
- ObservableList list = FXCollections.observableArrayList("first class","economic Class","business class");
- Travel_ComboBox.setItems(list);
- loadvoy();
- refresh();
- }
-
- private void refresh() {
- try {
- List.clear();
-
- String query ="select reservation_voyage.id,voyage.nom_voyage ,reservation_voyage.travel_class,reservation_voyage.date_reservation, reservation_voyage.age from reservation_voyage INNER JOIN voyage on reservation_voyage.voyage_id =voyage.id ";
- preparedStatement = connection.prepareStatement(query);
- resultSet = preparedStatement.executeQuery();
- while (resultSet.next()){
- List.add(new ReserverVoyage(
- resultSet.getInt("id"),
- resultSet.getString("nom_voyage"),
- resultSet.getDate("date_reservation"),
- resultSet.getString("travel_class"),
- resultSet.getInt("age")
- ));
- TableVoyage.setItems(List);
- }
- } catch (SQLException ex) {
- System.err.println("SQLException: " + ex.getMessage());
- System.err.println("SQLState: " + ex.getSQLState());
- System.err.println("VendorError: " + ex.getErrorCode());
- }
- }
-
- private void loadvoy() {
-
- ServiseReserVoy v=new ServiseReserVoy();
- connection= MyDB.getInsatnce().getConnection();
- refresh();
- VID.setCellValueFactory(new PropertyValueFactory<>("id"));
- Dest.setCellValueFactory(new PropertyValueFactory<>("nom_voyage"));
- date.setCellValueFactory(new PropertyValueFactory<>("date_reservation"));
- Tra_class.setCellValueFactory(new PropertyValueFactory<>("travel_Class"));
- Rage.setCellValueFactory(new PropertyValueFactory<>("age"));
- VoyageCombox.setItems(FXCollections.observableArrayList(v.getAll()));
- System.out.println(Tra_class.getText());
-
- }
- @FXML
- private void SupprimerVoyage(ActionEvent event) {
- if (!TableVoyage.getSelectionModel().isEmpty()) {
- Alert alert = new Alert(Alert.AlertType.CONFIRMATION, "Etes vous sur de vouloir supprimer la reservation du " + TableVoyage.getSelectionModel().getSelectedItem().getNom_voyage()+ " ?", ButtonType.YES, ButtonType.NO);
-alert.showAndWait();
-
-if (alert.getResult() == ButtonType.YES) {
- ServiseReserVoy r=new ServiseReserVoy();
- r.SupprimerReserverVoyage(TableVoyage.getSelectionModel().getSelectedItem().getId());
- };
- refresh();
- }
- }
-
- @FXML
- private void Liste_Voyage(MouseEvent event) {
- try {
- ReserverVoyage Res = TableVoyage.getSelectionModel().getSelectedItem();
- Dest.setText(Res.getNom_voyage());
- Age.setText(String.valueOf(Res.getAge()));
- String c = Res.getNom_voyage();
- VoyageCombox.setValue(c);
- String B = Res.getTravel_Class();
- Travel_ComboBox.setValue(B);
- } catch (Exception e) {
- System.out.println(e.getMessage());
-
- }
- }
- @FXML
- private void Add(ActionEvent event) {
- try {
- connection= MyDB.getInsatnce().getConnection();
- String Dest = (String)VoyageCombox.getValue();
- String Tra = (String)Travel_ComboBox.getValue();
- java.sql.Date date = java.sql.Date.valueOf(Datev.getValue());
- String Ag =Age.getText();
- ServiseReserVoy rec = new ServiseReserVoy();
- int IdVoy= rec.chercherVoy(Dest);
-
- Scontrole_Voyage sc= new Scontrole_Voyage();
-// int Age =Integer.valueOf(Rage.getText());
-if( Tra.isEmpty()){
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("Travel class vides");
- alert.showAndWait();
-
-}else
- if( Dest.isEmpty()){
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("Travel class vides");
- alert.showAndWait();
-} else if (! sc.isNumeric(Age.getText())){
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("Age doit étre un nombre");
- alert.showAndWait();
-}
-else {
- int A=Integer.parseInt(Ag);
- ReserverVoyage re = new ReserverVoyage(IdVoy,Tra,date,A);
- System.out.println(re.toString());
- rec.AjouterReserverVoyage(re);
- refresh();
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("Reservation ajouter");
- alert.showAndWait();
-}
- } catch (SQLException ex) {
- System.err.println(ex.getMessage()); }
-}
-
- @FXML
- private void ModVoy(ActionEvent event) throws SQLException {
- Scontrole_Voyage sc= new Scontrole_Voyage();
-
- ReserverVoyage voy=new ReserverVoyage();
- ServiseReserVoy rec = new ServiseReserVoy();
- voy=TableVoyage.getSelectionModel().getSelectedItem();
- voy.setId(TableVoyage.getSelectionModel().getSelectedItem().getId());
- String Dest = (String)VoyageCombox.getValue();
- String Tra = (String)Travel_ComboBox.getValue();
- voy.setNom_voyage(Dest);
- voy.setTravel_Class(Tra);
- java.sql.Date date = java.sql.Date.valueOf(Datev.getValue());
- voy.setDate_reservation(date);
- String Ag =Age.getText();
- int A=Integer.parseInt(Ag);
- int IdVoy=rec.chercherVoy(Dest);
- voy.setAge(A);
-
-if( Tra.isEmpty()){
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("Travel class vides");
- alert.showAndWait();
-
-}else
- if( Dest.isEmpty()){
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("Travel class vides");
- alert.showAndWait();
-} else if (! sc.isNumeric(Age.getText())){
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("Age doit étre un nombre");
- alert.showAndWait();
-}
-else {
- ReserverVoyage re = new ReserverVoyage(IdVoy,Tra,date,A);
- System.out.println(re.toString());
- rec.ModifierReserverVoyage(voy);
- refresh();
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("Reservation ajouter");
- alert.showAndWait();
-}
-}
-
-
- @FXML
- private void Recherche(KeyEvent event) {
-
- }
-
- @FXML
- private void Clear(ActionEvent event) {
- }
- @FXML
- private void Actualiser(ActionEvent event) {
- loadvoy();
- refresh();
- }
-
- @FXML
- private void Menu(ActionEvent event) throws IOException {
- Parent root = FXMLLoader.load(getClass().getResource("MenuDynamicDevelopers.fxml"));
- Scene scene = new Scene(root);
- Stage stage = (Stage) ((Node) event.getSource()).getScene().getWindow();
- stage.setScene(scene);
- stage.show();
- }
-}
diff --git a/Dynamic-Developers/src/Gui/Style.css b/Dynamic-Developers/src/Gui/Style.css
deleted file mode 100644
index 0d07719..0000000
--- a/Dynamic-Developers/src/Gui/Style.css
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * Empty Stylesheet file.
- */
-
-.menuItem:hover{
- -fx-border-color: #660099;
- -fx-border-width: 0px 0px 3px 0px;
-}
-
-.sidebarItem:hover{
- -fx-background-color: #146886;
- -fx-border-color: WHITE;
- -fx-border-width: 0px 0px 0px 3px;
-}
-
-.search-box{
- -fx-background-color:#FFFFFF;
- -fx-background-radius: 100;
-}
-
-.transparent{
- -fx-background-color: rgba(0,0,0,0);
-}
-
-.search-button{
- -fx-background-color: #828282;
- -fx-background-radius: 30;
-}
-
-.right-bar{
- -fx-background-color: #D3D3D3;
-}
-
-.shadow{
- -fx-effect: dropShadow(three-pass-box,rgba(0,0,0,0.1), 10.0 , 0.0 , 0.0 ,10.0);
-}
-
-.chosen-fruit-card{
- -fx-background-color: #F16C31;
- -fx-background-radius: 30;
-}
-
-.comboBox{
- -fx-background-color: rgba(255,255,255,0.3);
- -fx-background-radius: 30;
-}
-
-.add-btn{
- -fx-background-color: #FFFFFF;
- -fx-background-radius: 100;
-}
-
-.free-delivery-card{
- -fx-background-color: #D3D3D3;
- -fx-background-radius: 30;
-}
-
-.shopping-online-card{
- -fx-background-color: #BAEAC3;
- -fx-background-radius: 30;
-}
-
-.fruit-item{
- -fx-background-color: #FFFFFF;
- -fx-background-radius: 30;
-}
-
-.transparent{
- -fx-background-color: rgba(0,0,0,0);
-}
diff --git a/Dynamic-Developers/src/Gui/Voyage.fxml b/Dynamic-Developers/src/Gui/Voyage.fxml
deleted file mode 100644
index 8325dd7..0000000
--- a/Dynamic-Developers/src/Gui/Voyage.fxml
+++ /dev/null
@@ -1,97 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/src/Gui/VoyageController.java b/Dynamic-Developers/src/Gui/VoyageController.java
deleted file mode 100644
index 55a55a0..0000000
--- a/Dynamic-Developers/src/Gui/VoyageController.java
+++ /dev/null
@@ -1,682 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Gui;
-
-import Entity.voyage;
-import static Entity.voyage.filename;
-import Service.Scontrole_Voyage;
-import Service.ServiceVoyage;
-import Util.MyDB;
-import com.itextpdf.text.Chunk;
-import com.itextpdf.text.Document;
-import com.itextpdf.text.Element;
-import com.itextpdf.text.Font;
-import com.itextpdf.text.Paragraph;
-import com.itextpdf.text.pdf.PdfPTable;
-import com.itextpdf.text.pdf.PdfWriter;
-import java.io.BufferedInputStream;
-import java.io.BufferedOutputStream;
-import java.io.BufferedWriter;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.OutputStream;
-import java.net.URL;
-import java.sql.Connection;
-import java.sql.Date;
-import java.sql.PreparedStatement;
-import java.sql.ResultSet;
-import java.sql.SQLException;
-import java.sql.Statement;
-import java.util.ResourceBundle;
-import javafx.beans.property.ReadOnlyObjectWrapper;
-import javafx.beans.value.ObservableValue;
-import javafx.collections.ObservableList;
-import javafx.event.ActionEvent;
-import javafx.event.EventHandler;
-import javafx.fxml.FXML;
-import javafx.fxml.Initializable;
-import javafx.scene.control.Button;
-import javafx.scene.control.TableColumn;
-import javafx.scene.control.TableView;
-import javafx.scene.control.TextField;
-import javafx.scene.control.cell.PropertyValueFactory;
-import javafx.scene.image.ImageView;
-import javafx.scene.input.MouseEvent;
-import javafx.util.Callback;
-import java.time.format.DateTimeFormatter;
-import java.util.Random;
-import javafx.collections.FXCollections;
-import javafx.fxml.FXMLLoader;
-import javafx.scene.Node;
-import javafx.scene.Parent;
-import javafx.scene.Scene;
-import javafx.scene.control.Alert;
-import javafx.scene.control.ComboBox;
-import javafx.scene.control.DatePicker;
-import javafx.scene.image.Image;
-import javafx.scene.input.KeyEvent;
-import javafx.stage.FileChooser;
-import javafx.stage.Stage;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.FileOutputStream;
-import java.io.FileWriter;
-import java.io.Writer;
-import static java.nio.file.Files.list;
-import static java.rmi.Naming.list;
-import static java.util.Collections.list;
-import javafx.stage.StageStyle;
-import org.apache.poi.hssf.usermodel.HSSFWorkbook;
-import org.apache.poi.sl.usermodel.Sheet;
-import org.apache.poi.ss.usermodel.Row;
-import org.apache.poi.ss.usermodel.Workbook;
-import org.apache.poi.ss.usermodel.WorkbookFactory;
-import java.util.List;
-import java.util.Optional;
-import javafx.scene.control.ButtonType;
-import javafx.scene.paint.Color;
-import javafx.scene.web.WebEngine;
-import javafx.scene.web.WebView;
-import javafx.util.Duration;
-import tray.animations.AnimationType;
-import tray.notification.NotificationType;
-import tray.notification.TrayNotification;
-/**
- * FXML Controller class
- *
- * @author ASUS
- */
-public class VoyageController implements Initializable {
-
- @FXML
- private ImageView ImageP;
- private TextField Voyage;
- @FXML
- private TableColumn VDest;
- @FXML
- private TableColumn VNom;
- @FXML
- private TableColumn VDuree;
- @FXML
- private TableColumn Vdate;
- @FXML
- private TableColumn VValibilite;
- @FXML
- private TableColumn Vimage;
- @FXML
- private TableColumn Vprix;
- @FXML
- private TableView TableVoyage;
- @FXML
- private Button SupprimerVoyage;
- @FXML
- private Button Actualiser;
- @FXML
- private TableColumn VID;
- @FXML
- private Button Bientot_disponible;
- @FXML
- private Button Disponible;
- @FXML
- private Button Non_Disponible;
-
- public static String idxx;
-
- voyage ss=new voyage();
-
- private Statement ste;
- private voyage v;
- String query = null;
- Connection connection = null ;
- Connection cnx=MyDB.getInsatnce().getConnection();
- PreparedStatement preparedStatement = null ;
- ResultSet resultSet = null ;
- voyage VOY = null ;
-
-ObservableList List = FXCollections.observableArrayList();
- @FXML
- private ImageView Image;
- @FXML
- private TextField Destination;
- @FXML
- private TextField Duree_Voyage;
- @FXML
- private TextField Nom_Voyage;
- @FXML
- private TextField Prix;
- @FXML
- private DatePicker Datev;
- @FXML
- private Button AddImage;
- @FXML
- private TextField URLImage;
- @FXML
- private Button Add;
- @FXML
- private Button ModVoy;
- @FXML
- private ComboBox combox;
- @FXML
- private TextField Recherche;
- @FXML
- private Button PDF;
- @FXML
- private Button stat;
- ObservableList list;
- @FXML
- private Button Map;
- @FXML
- private Button Notif;
- @FXML
- private Button Media;
- @FXML
- private Button stat1;
- @FXML
- private Button stat2;
- @FXML
- private Button reset;
- @FXML
- private Button Menu;
- /**
- * Initializes the controller class.
- */
- @Override
- public void initialize(URL url, ResourceBundle rb) {
- // TODO
- ObservableList list = FXCollections.observableArrayList("Disponible","Non Disponible","Bientot Disponible");
- combox.setItems(list);
- loadvoy();
- refresh();
-
-};
-
- @FXML
- private void Liste_Voyage(javafx.scene.input.MouseEvent event) {
-
- try {
- voyage voy = TableVoyage.getSelectionModel().getSelectedItem();
- Destination.setText(voy.getDestination());
- Nom_Voyage.setText(voy.getNom_voyage());
- Duree_Voyage.setText(voy.getDuree_voyage());
- // java.sql.Date date = java.sql.Date.valueOf(Datev.getValue());
- // Datev.set(voy.getDate());
- String c = voy.getValabilite();
- combox.setValue(c);
- Prix.setText(String.valueOf(voy.getPrix()));
- String path = voy.getImage();
- File file=new File(path);
- URLImage.setText(path);
- Image img = new Image(file.toURI().toString());
- Image.setImage(img);
- } catch (Exception e) {
- System.out.println(e.getMessage());
-
- }
- }
- public void delete()
- {
- ServiceVoyage SV = new ServiceVoyage();
- SV.SupprimerVoyage(TableVoyage.getSelectionModel().getSelectedItem().getID());
- System.out.println(TableVoyage.getSelectionModel().getSelectedItem().getID());
- }
- @FXML
- private void SupprimerVoyage(ActionEvent event) {
- delete();
- TableVoyage.getItems().removeAll(TableVoyage.getSelectionModel().getSelectedItem());
- System.out.println(TableVoyage);
- TableVoyage.refresh();
- }
-
- @FXML
- private void Actualiser(ActionEvent event) {
- loadvoy();
- refresh();
- }
-
- @FXML
- private void Bientot_disponible(ActionEvent event) {
- try {
- List.clear();
-
- query = "select * from voyage WHERE valabilite = 'Bientot Disponible'";
- preparedStatement = connection.prepareStatement(query);
- resultSet = preparedStatement.executeQuery();
- while (resultSet.next()){
- List.add(new voyage(
- resultSet.getInt("id"),
- resultSet.getString("destination"),
- resultSet.getString("nom_voyage"),
- resultSet.getString("duree_voyage"),
- resultSet.getDate("date"),
- resultSet.getString("valabilite"),
- resultSet.getString("image"),
- resultSet.getFloat("prix")
- ));
- TableVoyage.setItems(List);
- }
- } catch (SQLException ex) {
- System.out.println(ex.getMessage());
- }
- }
-
- @FXML
- private void Disponible(ActionEvent event) {
- try {
- List.clear();
-
- query = "select * from voyage WHERE valabilite = 'Disponible'";
- preparedStatement = connection.prepareStatement(query);
- resultSet = preparedStatement.executeQuery();
- while (resultSet.next()){
- List.add(new voyage(
- resultSet.getInt("id"),
- resultSet.getString("destination"),
- resultSet.getString("nom_voyage"),
- resultSet.getString("duree_voyage"),
- resultSet.getDate("date"),
- resultSet.getString("valabilite"),
- resultSet.getString("image"),
- resultSet.getFloat("prix")
- ));
- TableVoyage.setItems(List);
- }
- } catch (SQLException ex) {
- System.out.println(ex.getMessage());
- }
- }
-
- @FXML
- private void Non_Disponible(ActionEvent event) {
- try {
- List.clear();
-
- query = "select * from voyage WHERE valabilite = 'Non Disponible'";
- preparedStatement = connection.prepareStatement(query);
- resultSet = preparedStatement.executeQuery();
- while (resultSet.next()){
- List.add(new voyage(
- resultSet.getInt("id"),
- resultSet.getString("destination"),
- resultSet.getString("nom_voyage"),
- resultSet.getString("duree_voyage"),
- resultSet.getDate("date"),
- resultSet.getString("valabilite"),
- resultSet.getString("image"),
- resultSet.getFloat("prix")
- ));
- TableVoyage.setItems(List);
- }
- } catch (SQLException ex) {
- System.out.println(ex.getMessage());
- }
- }
-
-
- private void refresh() {
- try {
- List.clear();
-
- query = "select * from voyage";
- preparedStatement = connection.prepareStatement(query);
- resultSet = preparedStatement.executeQuery();
- while (resultSet.next()){
- List.add(new voyage(
- resultSet.getInt("id"),
- resultSet.getString("destination"),
- resultSet.getString("nom_voyage"),
- resultSet.getString("duree_voyage"),
- resultSet.getDate("date"),
- resultSet.getString("valabilite"),
- resultSet.getString("image"),
- resultSet.getFloat("prix")
- ));
- TableVoyage.setItems(List);
- }
- } catch (SQLException ex) {
- System.out.println(ex.getMessage());
- }
-
- }
- private void clear() {
-
- Destination.setText(null);
- Nom_Voyage.setText(null);
- Duree_Voyage.setText(null);
- Datev.setValue(null);
- combox.setValue(null);
- URLImage.setText(null);
- Prix.setText(null);
-
- }
- private void loadvoy() {
- voyage v=new voyage();
- connection= MyDB.getInsatnce().getConnection();
- VID.setCellValueFactory(new PropertyValueFactory<>("id"));
- VDest.setCellValueFactory(new PropertyValueFactory<>("destination"));
- VNom.setCellValueFactory(new PropertyValueFactory<>("nom_voyage"));
- VDuree.setCellValueFactory(new PropertyValueFactory<>("duree_voyage"));
- Vdate.setCellValueFactory(new PropertyValueFactory<>("date"));
- VValibilite.setCellValueFactory(new PropertyValueFactory<>("valabilite"));
- Vimage.setCellValueFactory(new PropertyValueFactory<>("image"));
- Vprix.setCellValueFactory(new PropertyValueFactory<>("prix"));
- }
-
- @FXML
- private void AddImage(ActionEvent event) throws FileNotFoundException, IOException {
- Random rand = new Random();
- int x = rand.nextInt(1000);
- FileChooser fileChooser = new FileChooser();
- fileChooser.setTitle("Upload File Path");
- fileChooser.getExtensionFilters().addAll(
- new FileChooser.ExtensionFilter("Image Files", "*.png", "*.jpg", "*.gif", "*.jpeg"));
- File file = fileChooser.showOpenDialog(null);
- String DBPath = "C:\\\\xampp\\\\htdocs\\\\Version-Integre\\\\public\\\\uploads\\\\" + x + ".jpg";
- if (file != null) {
- FileInputStream Fsource = new FileInputStream(file.getAbsolutePath());
- FileOutputStream Fdestination = new FileOutputStream(DBPath);
- BufferedInputStream bin = new BufferedInputStream(Fsource);
- BufferedOutputStream bou = new BufferedOutputStream(Fdestination);
- System.out.println(file.getAbsoluteFile());
- String path=file.getAbsolutePath();
- Image img = new Image(file.toURI().toString());
- Image.setImage(img);
- URLImage.setText(DBPath);
- int b = 0;
- while (b != -1) {
- b = bin.read();
- bou.write(b);
- }
- bin.close();
- bou.close();
-
- } else {
- System.out.println("error");
-
- }
- }
-
- @FXML
- private void Add(ActionEvent event) {
-
- String Destinationv = Destination.getText();
- String Nom_Voyagev = Nom_Voyage.getText();
- String Duree_Voyagev = Duree_Voyage.getText();
- //Date Datevoy= Date.valueOf(Datev.getValue());
- String Valabilitev = (String)combox.getValue();
- java.sql.Date date = java.sql.Date.valueOf(Datev.getValue());
- String Prixv=Prix.getText();
- System.out.println(date);
- Scontrole_Voyage sc= new Scontrole_Voyage();
- ServiceVoyage ps = new ServiceVoyage();
-
-
-
- if( Destinationv.isEmpty()){
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("champs vides");
- alert.setTitle("Prolem");
- alert.setHeaderText(null);
- alert.showAndWait();
- } else if (! sc.isNumeric(Prixv)){
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("Age doit étre un nombre");
- alert.showAndWait();
- }
- else {
- voyage v = new voyage(Destinationv,Nom_Voyagev,Duree_Voyagev,date,Valabilitev,URLImage.getText(),Float.parseFloat(Prixv));
- ps.AjouterVoyage(v);
- refresh();
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setTitle("succes");
- alert.setHeaderText(null);
- alert.setContentText("Voyage ajouter");
- alert.showAndWait();
- }}
-
- @FXML
- private void ModVoy(ActionEvent event) {
- Scontrole_Voyage sc= new Scontrole_Voyage();
-
- voyage voy=new voyage();
- ServiceVoyage sv = new ServiceVoyage();
- voy=TableVoyage.getSelectionModel().getSelectedItem();
- voy.setID(TableVoyage.getSelectionModel().getSelectedItem().getID());
- voy.setDestination(Destination.getText());
- voy.setNom_voyage(Nom_Voyage.getText());
- voy.setDuree_voyage(Duree_Voyage.getText());
- java.sql.Date date = java.sql.Date.valueOf(Datev.getValue());
- voy.setDate(date);
- String Valabilite = (String)combox.getValue();
- voy.setValabilite(Valabilite);
- voy.setImage(URLImage.getText());
-if (! sc.isNumeric(Prix.getText())){
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setContentText("Age doit étre un nombre");
- alert.showAndWait();
- }
- else {
- voy.setPrix(Float.parseFloat(Prix.getText()));
- sv.ModifierVoyage(voy);
- loadvoy();
- refresh();
- Alert alert =new Alert(Alert.AlertType.CONFIRMATION);
- alert.setTitle("succes");
- alert.setHeaderText(null);
- alert.setContentText("Voyage Modifier Avec succ");
- alert.showAndWait();
- }
-
- }
-
- @FXML
- private void Recherche(KeyEvent event) {
-
- }
- private void populateTable(ObservableList branlist){
- TableVoyage.setItems(branlist);
-
- }
-
- @FXML
- private void PDF(MouseEvent event) throws SQLException {
- ServiceVoyage sv = new ServiceVoyage();
- ObservableList list = sv.getvoyageList();
- try {
- OutputStream file = new FileOutputStream(new File("C:\\Users\\ASUS\\OneDrive\\Documents\\NetBeansProjects\\Dynamic-Developers\\Voyage.pdf"));
- Document document = new Document();
- PdfWriter.getInstance(document, file);
- document.open();
- Font font = new Font(Font.FontFamily.HELVETICA, 24, Font.BOLD);
- Paragraph pdfTitle = new Paragraph("Liste des Voyage", font);
- pdfTitle.setAlignment(Element.ALIGN_CENTER);
-
- document.add(pdfTitle);
- document.add(new Chunk("\n"));
- PdfPTable table = new PdfPTable(7);
- table.setHeaderRows(1);
- table.addCell("Destination");
- table.addCell("Nom_Voyage");
- table.addCell("Duree_Voyage");
- table.addCell("date");
- table.addCell("Valabilite");
- table.addCell("Image");
- table.addCell("Prix");
- list.forEach((_item) -> {
- table.addCell(_item.getDestination());
- table.addCell(_item.getNom_voyage());
- table.addCell(_item.getDuree_voyage());
- table.addCell(String.valueOf(_item.getDate()));
- table.addCell(_item.getValabilite());
- table.addCell(_item.getImage());
- table.addCell(String.valueOf(_item.getPrix()));
- });
- document.add(table);
- Alert alert = new Alert(Alert.AlertType.INFORMATION);
- alert.setTitle("Success");
- alert.setContentText("Success!");
- document.close();
- file.close();
- } catch (Exception e) {
- System.out.println(e.getMessage());
-Alert alert = new Alert(Alert.AlertType.ERROR);
- alert.setTitle("Error");
- alert.setContentText("Cannot export data!");
- alert.show(); }
- }
-
- @FXML
- private void OnStatClicked(ActionEvent event) {
- try {
-
- Parent parent = FXMLLoader.load(getClass().getResource("/Gui/VoyageStatValabilite.fxml"));
- Scene scene = new Scene(parent);
-
- Stage stage = new Stage();
- //stage.getIcons().add(new Image("/images/logo.png"));
- stage.setScene(scene);
- stage.initStyle(StageStyle.UTILITY);
- stage.show();
- } catch (IOException ex) {
- System.out.println(ex.getMessage());
- }
- }
-
- @FXML
- private void Excel(ActionEvent event) throws IOException {
- Writer writer = null;
-
- try {
- //badel path fichier excel
- File file = new File("C:\\Users\\ASUS\\OneDrive\\Documents\\NetBeansProjects\\Dynamic-Developers\\Voyage.csv");
- writer = new BufferedWriter(new FileWriter(file));
- for (voyage ev : list) {
-
- String text = ev.getDestination()+"," +ev.getNom_voyage()+ "," + ev.getDuree_voyage()+ ","+ev.getDate()+","+ev.getValabilite()+","+ev.getImage()+","+ev.getPrix()+ "\n";
- System.out.println(text);
- writer.write(text);
- }
- } catch (Exception ex) {
- ex.printStackTrace();
- }
- finally {
-
- writer.flush();
- writer.close();
- Alert alert= new Alert(Alert.AlertType.INFORMATION);
- alert.setTitle("excel");
- alert.setHeaderText(null);
- alert.setContentText("!!!excel exported!!!");
- alert.showAndWait();
- }
- }
-
- @FXML
- private void Map(ActionEvent event) {
- Stage stage = new Stage ();
-
- final WebView webView = new WebView();
- final WebEngine webEngine = webView.getEngine();
- webEngine.load(getClass().getResource("/Gui/googleMaps.html").toString());
-
- // create scene
- // stage.getIcons().add(new Image("/Assets/logo.png"));
- stage.setTitle("localisation");
- Scene scene = new Scene(webView,1000,700, Color.web("#666970"));
- stage.setScene(scene);
- // show stage
- stage.show();
-
- }
-
- private void notiff()
- {
- ServiceVoyage sv = new ServiceVoyage();
- voyage v = new voyage();
- String Destinationv = Destination.getText();
- int y=sv.calculnb((Destination.getText()));
- TrayNotification tray = new TrayNotification();
- AnimationType type = AnimationType.POPUP;
- tray.setAnimationType(type);
- tray.setTitle("attention");
- tray.setMessage("il existe "+y+ " voyages a "+Destinationv+"");
-tray.setNotificationType(NotificationType.INFORMATION);
-tray.showAndDismiss(Duration.millis(2000));
- }
- @FXML
- private void notif(MouseEvent event) {
- notiff();
- }
-
- @FXML
- private void Media_Video(ActionEvent event) {
- if(TableVoyage.getSelectionModel().isEmpty()) {
- Alert alert = new Alert(Alert.AlertType.INFORMATION);
-
- alert.setTitle("Warnning");
- alert.setHeaderText("SELECT YOUR Voyage");
- Optional result1 = alert.showAndWait();}
- else{
- try {
- Parent root;
-
- root = FXMLLoader.load(getClass().getResource("Media_Voyage.fxml"));
-
- Media.getScene().setRoot(root);
- } catch (IOException ex) {
- System.out.println(ex.getMessage());
- }
-
- }
- }
-
- @FXML
- private void OnStat(ActionEvent event) {
- try {
- Parent parent = FXMLLoader.load(getClass().getResource("/Gui/VoyageStatPrix.fxml"));
- Scene scene = new Scene(parent);
- Stage stage = new Stage();
- //stage.getIcons().add(new Image("/images/logo.png"));
- stage.setScene(scene);
- stage.initStyle(StageStyle.UTILITY);
- stage.show();
- } catch (IOException ex) {
- System.out.println(ex.getMessage());
- }
- }
-
- @FXML
- private void OnStatClickedDestination(ActionEvent event) {
- try {
- Parent parent = FXMLLoader.load(getClass().getResource("/Gui/VoyageStat.fxml"));
- Scene scene = new Scene(parent);
- Stage stage = new Stage();
- //stage.getIcons().add(new Image("/images/logo.png"));
- stage.setScene(scene);
- stage.initStyle(StageStyle.UTILITY);
- stage.show();
- } catch (IOException ex) {
- System.out.println(ex.getMessage());}
- }
-
- @FXML
- private void reset(ActionEvent event) {
- clear();
-
- }
-
- @FXML
- private void Menu(ActionEvent event) throws IOException {
- Parent root = FXMLLoader.load(getClass().getResource("MenuDynamicDevelopers.fxml"));
- Scene scene = new Scene(root);
- Stage stage = (Stage) ((Node) event.getSource()).getScene().getWindow();
- stage.setScene(scene);
- stage.show();
- }
-}
diff --git a/Dynamic-Developers/src/Gui/VoyageStat.fxml b/Dynamic-Developers/src/Gui/VoyageStat.fxml
deleted file mode 100644
index 0d73d77..0000000
--- a/Dynamic-Developers/src/Gui/VoyageStat.fxml
+++ /dev/null
@@ -1,17 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/src/Gui/VoyageStatController.java b/Dynamic-Developers/src/Gui/VoyageStatController.java
deleted file mode 100644
index 53aaa3f..0000000
--- a/Dynamic-Developers/src/Gui/VoyageStatController.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Gui;
-
-import Util.MyDB;
-import java.net.URL;
-import java.sql.Connection;
-import java.sql.PreparedStatement;
-import java.sql.ResultSet;
-import java.sql.SQLException;
-import java.sql.Statement;
-import java.util.ResourceBundle;
-import java.util.logging.Level;
-import javafx.collections.FXCollections;
-import javafx.collections.ObservableList;
-import javafx.fxml.FXML;
-import javafx.fxml.Initializable;
-import javafx.geometry.Side;
-import javafx.scene.chart.PieChart;
-
-/**
- * FXML Controller class
- *
- * @author ASUS
- */
-public class VoyageStatController implements Initializable {
-
- @FXML
- private PieChart voy_stat;
- private Statement st;
- private ResultSet rs;
- private Connection cnx;
- ObservableListdata=FXCollections.observableArrayList();
-int n;
- /**
- * Initializes the controller class.
- */
- @Override
- public void initialize(URL url, ResourceBundle rb) {
- // TODO
- cnx = MyDB.getInsatnce().getConnection();
- stat();
- }
-
- private void stat() {
- try{
- // String query ="select COUNT(*),reservation_voyage.travel_class from voyage INNER JOIN reservation_voyage on reservation_voyage.voyage_id =voyage.id GROUP BY travel_class;";
- //String query ="select COUNT(*),`prix` from voyage GROUP BY `destination`;";
- String query ="select COUNT(*),`destination` from voyage GROUP BY `destination`;";
-
- PreparedStatement PreparedStatement = cnx.prepareStatement(query);
- rs = PreparedStatement.executeQuery();
- while (rs.next()){
- data.add(new PieChart.Data(rs.getString("destination"),rs.getInt("COUNT(*)")));
- }
-
- } catch (SQLException ex) {
- System.out.println(ex.getMessage());
- }
-
- voy_stat.setTitle("**Statistiques Des destination courant **");
- voy_stat.setLegendSide(Side.LEFT);
- voy_stat.setData(data);
- }
- public void setResid(int n) {
- this.n=n;
- }
-}
diff --git a/Dynamic-Developers/src/Gui/VoyageStatPrix.fxml b/Dynamic-Developers/src/Gui/VoyageStatPrix.fxml
deleted file mode 100644
index d7ff6c8..0000000
--- a/Dynamic-Developers/src/Gui/VoyageStatPrix.fxml
+++ /dev/null
@@ -1,18 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/src/Gui/VoyageStatPrixController.java b/Dynamic-Developers/src/Gui/VoyageStatPrixController.java
deleted file mode 100644
index a3f71e5..0000000
--- a/Dynamic-Developers/src/Gui/VoyageStatPrixController.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Gui;
-
-import Util.MyDB;
-import java.net.URL;
-import java.sql.Connection;
-import java.sql.PreparedStatement;
-import java.sql.ResultSet;
-import java.sql.SQLException;
-import java.sql.Statement;
-import java.util.ResourceBundle;
-import javafx.collections.FXCollections;
-import javafx.collections.ObservableList;
-import javafx.fxml.FXML;
-import javafx.fxml.Initializable;
-import javafx.geometry.Side;
-import javafx.scene.chart.PieChart;
-import javafx.scene.image.ImageView;
-
-/**
- * FXML Controller class
- *
- * @author ASUS
- */
-public class VoyageStatPrixController implements Initializable {
-
- @FXML
- private ImageView ImageP;
- @FXML
- private PieChart voy_stat;
-
- private Statement st;
- private ResultSet rs;
- private Connection cnx;
- ObservableListdata=FXCollections.observableArrayList();
-
- /**
- * Initializes the controller class.
- */
- @Override
- public void initialize(URL url, ResourceBundle rb) {
- cnx = MyDB.getInsatnce().getConnection();
- stat();
- }
- private void stat() {
- try{
- // String query ="select COUNT(*),reservation_voyage.travel_class from voyage INNER JOIN reservation_voyage on reservation_voyage.voyage_id =voyage.id GROUP BY travel_class;";
- String query ="select SUM(prix),`destination` from voyage GROUP BY `prix`;";
- //String query ="select COUNT(*),prix from voyage GROUP BY valabilite;";
-
- PreparedStatement PreparedStatement = cnx.prepareStatement(query);
- rs = PreparedStatement.executeQuery();
- while (rs.next()){
- data.add(new PieChart.Data(rs.getString("destination"),rs.getInt("SUM(prix)")));
- }
-
- } catch (SQLException ex) {
- System.out.println(ex.getMessage());
- }
-
- voy_stat.setTitle("**Statistiques des Prix Par Destination**");
- voy_stat.setLegendSide(Side.LEFT);
- voy_stat.setData(data);
- }
-
-}
diff --git a/Dynamic-Developers/src/Gui/VoyageStatValabilite.fxml b/Dynamic-Developers/src/Gui/VoyageStatValabilite.fxml
deleted file mode 100644
index 9c48e13..0000000
--- a/Dynamic-Developers/src/Gui/VoyageStatValabilite.fxml
+++ /dev/null
@@ -1,17 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Dynamic-Developers/src/Gui/VoyageStatValabiliteController.java b/Dynamic-Developers/src/Gui/VoyageStatValabiliteController.java
deleted file mode 100644
index 5c656bd..0000000
--- a/Dynamic-Developers/src/Gui/VoyageStatValabiliteController.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Gui;
-
-import Util.MyDB;
-import java.net.URL;
-import java.sql.Connection;
-import java.sql.PreparedStatement;
-import java.sql.ResultSet;
-import java.sql.SQLException;
-import java.sql.Statement;
-import java.util.ResourceBundle;
-import javafx.collections.FXCollections;
-import javafx.collections.ObservableList;
-import javafx.fxml.FXML;
-import javafx.fxml.Initializable;
-import javafx.geometry.Side;
-import javafx.scene.chart.PieChart;
-import javafx.scene.image.ImageView;
-
-/**
- * FXML Controller class
- *
- * @author ASUS
- */
-public class VoyageStatValabiliteController implements Initializable {
-
- @FXML
- private ImageView ImageP;
- @FXML
- private PieChart voy_stat;
- private Statement st;
- private ResultSet rs;
- private Connection cnx;
- ObservableListdata=FXCollections.observableArrayList();
- /**
- * Initializes the controller class.
- */
- @Override
- public void initialize(URL url, ResourceBundle rb) {
- cnx = MyDB.getInsatnce().getConnection();
- stat();
- }
- private void stat() {
- try{
- // String query ="select COUNT(*),reservation_voyage.travel_class from voyage INNER JOIN reservation_voyage on reservation_voyage.voyage_id =voyage.id GROUP BY travel_class;";
- //String query ="select COUNT(*),`prix` from voyage GROUP BY `destination`;";
- String query ="select COUNT(*),`valabilite` from voyage GROUP BY `valabilite`;";
-
- PreparedStatement PreparedStatement = cnx.prepareStatement(query);
- rs = PreparedStatement.executeQuery();
- while (rs.next()){
- data.add(new PieChart.Data(rs.getString("valabilite"),rs.getInt("COUNT(*)")));
- }
-
- } catch (SQLException ex) {
- System.out.println(ex.getMessage());
- }
-
- voy_stat.setTitle("**Statistiques Des destination par valabilite **");
- voy_stat.setLegendSide(Side.LEFT);
- voy_stat.setData(data);
- }
-
-}
diff --git a/Dynamic-Developers/src/Gui/googleMaps.html b/Dynamic-Developers/src/Gui/googleMaps.html
deleted file mode 100644
index b2d71fd..0000000
--- a/Dynamic-Developers/src/Gui/googleMaps.html
+++ /dev/null
@@ -1,73 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/Dynamic-Developers/src/Img/bg.jpg b/Dynamic-Developers/src/Img/bg.jpg
deleted file mode 100644
index d866db0..0000000
Binary files a/Dynamic-Developers/src/Img/bg.jpg and /dev/null differ
diff --git a/Dynamic-Developers/src/Service/IServise.java b/Dynamic-Developers/src/Service/IServise.java
deleted file mode 100644
index 9c3aa57..0000000
--- a/Dynamic-Developers/src/Service/IServise.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Service;
-
-import java.util.List;
-
-/**
- *
- * @author ASUS
- */
-public interface IServise {
- public void AjouterVoyage(V v);
- public void ModifierVoyage(V v);
- public void SupprimerVoyage(int ID);
- public ListRecupererVoyage();
- public ListRecupererVoyagetrieDestination(); //exemple trie
- public ListRechercheVoyage(String Dest);
- public ListRecupererVoyageDisponible();
- public ListRecupererVoyageNonDisponible();
- public ListRecupererVoyageBientotdisponible();
- public ListlisteVoyage();
-
-
-
-
-}
\ No newline at end of file
diff --git a/Dynamic-Developers/src/Service/IServiseReserVoy.java b/Dynamic-Developers/src/Service/IServiseReserVoy.java
deleted file mode 100644
index 23ddbdf..0000000
--- a/Dynamic-Developers/src/Service/IServiseReserVoy.java
+++ /dev/null
@@ -1,20 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Service;
-
-import java.util.List;
-
-/**
- *
- * @author ASUS
- */
-public interface IServiseReserVoy {
- public void AjouterReserverVoyage(R r) ;
- public void ModifierReserverVoyage(R r);
- public void SupprimerReserverVoyage(int ID);
- public ListRecupererReserverVoyage();
-
-}
diff --git a/Dynamic-Developers/src/Service/Scontrole_Voyage.java b/Dynamic-Developers/src/Service/Scontrole_Voyage.java
deleted file mode 100644
index 410ed5b..0000000
--- a/Dynamic-Developers/src/Service/Scontrole_Voyage.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Service;
-
-import Entity.voyage;
-
-
-/**
- *
- * @author chaim
- */
-public class Scontrole_Voyage {
-
- public static boolean Controlechar(String v) {
- String str = (v).toLowerCase();
- if (str.length() == 0)
- return false;
- char[] charArray = str.toCharArray();
-
- for (int i = 0; i < charArray.length; i++) {
- char ch = charArray[i];
- if (!((ch >= 'a' && ch <= 'z') || (String.valueOf(ch)).equals(" "))) {
- return false;
- }
- }
- return true;
- }
-
-public boolean isNumeric(String text) {
- if (text == null || text.trim().equals("")) {
- return false;
- }
- for (int iCount = 0; iCount < text.length(); iCount++) {
- if (!Character.isDigit(text.charAt(iCount))) {
- return false;
- }
- }
- return true;
- }
-
-}
diff --git a/Dynamic-Developers/src/Service/ServiceVoyage.java b/Dynamic-Developers/src/Service/ServiceVoyage.java
deleted file mode 100644
index d8bbe0b..0000000
--- a/Dynamic-Developers/src/Service/ServiceVoyage.java
+++ /dev/null
@@ -1,546 +0,0 @@
- /*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Service;
-
-import Entity.voyage;
-import Util.MyDB;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.sql.Connection;
-import java.sql.PreparedStatement;
-import java.sql.ResultSet;
-import java.sql.ResultSetMetaData;
-import java.sql.SQLException;
-import java.sql.Statement;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-import javafx.collections.FXCollections;
-import javafx.collections.ObservableList;
-import org.apache.poi.hssf.usermodel.HSSFWorkbook;
-import org.apache.poi.ss.usermodel.Row;
-import org.apache.poi.ss.usermodel.Sheet;
-import org.apache.poi.ss.usermodel.Workbook;
-import org.apache.poi.ss.usermodel.WorkbookFactory;
-import org.apache.poi.ss.usermodel.Cell;
-
-/**
- *
- * @author ASUS
- */
-public class ServiceVoyage implements IServise{
-
- Connection cnx;
-
- public ServiceVoyage() {
- cnx=MyDB.getInsatnce().getConnection();
- }
-
- @Override
- public void AjouterVoyage(voyage v) {
- try {
- String req = "insert into voyage(id,clien_id,destination,nom_voyage,duree_voyage,date,valabilite,image,prix)"
- +"values("+v.getID()+","+1+",'"+v.getDestination()+"','"+v.getNom_voyage()+"','"+v.getDuree_voyage()+"','"+v.getDate()+"',"
- +"'"+v.getValabilite()+"','"+v.getImage()+"',"+v.getPrix()+")";
- Statement st = cnx.createStatement();
- st.executeUpdate(req);
- System.out.println("Voyage ajouter avec succ");
- } catch (SQLException ex) {
- System.out.println(ex.getMessage()); } }
-
- @Override
- public void ModifierVoyage(voyage v) {
- try {
-
-// String req ="UPDATE `voyage` SET `clien_id`='19',`destination`='ag',`nom_voyage`='18',`duree_voyage`='15',`date`='0000-00-00',`valabilite`='12',`image`='12',`prix`='12' WHERE id=33;";
-
- String req ="UPDATE voyage SET clien_id=1,destination=?,nom_voyage=?,duree_voyage=?,date=?,valabilite=?,image=?,prix=? WHERE id=?;";
- PreparedStatement ps= cnx.prepareStatement(req); //req dynamic plus securiser
-
- ps.setString(1,v.getDestination());
- ps.setString(2,v.getNom_voyage());
- ps.setString(3,v.getDuree_voyage());
- ps.setDate(4,v.getDate());
- ps.setString(5,v.getValabilite());
- ps.setString(6,v.getImage());
- ps.setInt(7,(int)v.getPrix());
- ps.setInt(8,v.getID());
-
- ps.executeUpdate();
- System.out.println("voyage Modifer avec succ");
-
- } catch (SQLException ex) {
- Logger.getLogger(ServiceVoyage.class.getName()).log(Level.SEVERE, null, ex);
- }
- }
-
- @Override
- public void SupprimerVoyage(int ID) {
- try
- {
- Statement st = cnx.createStatement();
- String req = "DELETE FROM voyage WHERE id = "+ID+"";
- st.executeUpdate(req);
- System.out.println("L'Voyage avec l'id = "+ID+" a été supprimer avec succès...");
- } catch (SQLException ex) {
- System.out.println(ex.getMessage());
- }
- }
-
- @Override
- public List RecupererVoyage() {
- List voyage = new ArrayList<>();
- try {
- String req ="select * from voyage";
- Statement st = cnx.createStatement();
- ResultSet rs = st.executeQuery(req);
- while(rs.next())
- {
- voyage v = new voyage();
- v.setID(rs.getInt("id"));
- v.setDestination(rs.getString("destination"));
- v.setNom_voyage(rs.getString("nom_voyage"));
- v.setDuree_voyage(rs.getString("duree_voyage"));
- v.setDate(rs.getDate("date"));
- v.setValabilite(rs.getString("valabilite"));
- v.setImage(rs.getString("image"));
- v.setPrix(rs.getInt("prix"));
-
- voyage.add(v);
- }
- } catch (SQLException ex) {
- System.err.println(ex.getMessage()); }
-
-return voyage; }
-
-
-@Override
- public List RecupererVoyagetrieDestination() {
- List voyage = new ArrayList<>();
- try {
- String req ="select * from voyage order by Destination";
- Statement st = cnx.createStatement(); //req statique
- ResultSet rs = st.executeQuery(req);
- while(rs.next())
- {
- voyage v = new voyage();
- v.setID(rs.getInt("id"));
- v.setDestination(rs.getString("destination"));
- v.setNom_voyage(rs.getString("nom_voyage"));
- v.setDuree_voyage(rs.getString("duree_voyage"));
- v.setValabilite(rs.getString("valabilite"));
- v.setImage(rs.getString("image"));
- v.setPrix(rs.getInt("prix"));
-
- voyage.add(v);
- }
- } catch (SQLException ex) {
- System.err.println(ex.getMessage()); }
-
-return voyage; }
-
- @Override
- public List RechercheVoyage(String dest) {
- List voyage = new ArrayList<>();
- try {
- String req ="select * from voyage WHERE destination = '"+dest+"'";
- Statement st = cnx.createStatement();
- ResultSet rs = st.executeQuery(req);
- while(rs.next())
- {
- voyage v = new voyage();
- v.setID(rs.getInt("id"));
- v.setDestination(rs.getString("destination"));
- v.setNom_voyage(rs.getString("nom_voyage"));
- v.setDuree_voyage(rs.getString("duree_voyage"));
- v.setValabilite(rs.getString("valabilite"));
- v.setImage(rs.getString("image"));
- v.setPrix(rs.getInt("prix"));
-
- voyage.add(v);
- }
- } catch (SQLException ex) {
- System.err.println(ex.getMessage()); }
-
-return voyage; }
-
- @Override
- public List RecupererVoyageDisponible() {
-List voyage = new ArrayList<>();
- try {
- String req ="select * from voyage WHERE valabilite = 'Disponible'";
- Statement st = cnx.createStatement();
- ResultSet rs = st.executeQuery(req);
- while(rs.next())
- {
- voyage v = new voyage();
- v.setID(rs.getInt("id"));
- v.setDestination(rs.getString("destination"));
- v.setNom_voyage(rs.getString("nom_voyage"));
- v.setDuree_voyage(rs.getString("duree_voyage"));
- v.setValabilite(rs.getString("valabilite"));
- v.setImage(rs.getString("image"));
- v.setPrix(rs.getInt("prix"));
-
- voyage.add(v);
- }
- } catch (SQLException ex) {
- System.err.println(ex.getMessage()); }
-
-return voyage; }
-
- @Override
- public List RecupererVoyageNonDisponible() {
-List voyage = new ArrayList<>();
- try {
- String req ="select * from voyage WHERE valabilite = 'Non Disponible'";
- Statement st = cnx.createStatement();
- ResultSet rs = st.executeQuery(req);
- while(rs.next())
- {
- voyage v = new voyage();
- v.setID(rs.getInt("id"));
- v.setDestination(rs.getString("destination"));
- v.setNom_voyage(rs.getString("nom_voyage"));
- v.setDuree_voyage(rs.getString("duree_voyage"));
- v.setValabilite(rs.getString("valabilite"));
- v.setImage(rs.getString("image"));
- v.setPrix(rs.getInt("prix"));
-
- voyage.add(v);
- }
- } catch (SQLException ex) {
- System.err.println(ex.getMessage()); }
-
-return voyage;
- }
-
- @Override
- public List RecupererVoyageBientotdisponible() {
-List voyage = new ArrayList<>();
- try {
- String req ="select * from voyage WHERE valabilite = 'Bientot Disponible'";
- Statement st = cnx.createStatement();
- ResultSet rs = st.executeQuery(req);
- while(rs.next())
- {
- voyage v = new voyage();
- v.setID(rs.getInt("id"));
- v.setDestination(rs.getString("destination"));
- v.setNom_voyage(rs.getString("nom_voyage"));
- v.setDuree_voyage(rs.getString("duree_voyage"));
- v.setValabilite(rs.getString("valabilite"));
- v.setImage(rs.getString("image"));
- v.setPrix(rs.getInt("prix"));
-
- voyage.add(v);
- }
- } catch (SQLException ex) {
- System.err.println(ex.getMessage()); }
-
-return voyage;
- }
- public List listeVoyage()
- {
- String sql = "select id,destination, nom_voyage, duree_voyage,date,valabilite,image,prix from voyage";
-
- List list = new ArrayList<>();
- try {
- PreparedStatement ps=cnx.prepareStatement(sql);
- ResultSet rs=ps.executeQuery();
-
- while (rs.next())
- {
- list.add(new voyage(rs.getInt("id"),rs.getString("destination"),rs.getString("nom_voyage"),rs.getString("duree_voyage"),rs.getDate("date"),rs.getString("valabilite"),rs.getString("image"),rs.getFloat("prix")));
- }
-
- }
- catch (SQLException ex) {
- System.out.println(ex.getMessage());
- }
- return list;
- }
-
- //--------------------------------- getvoyageList() ------------------------------------------------------//
- public ObservableList getvoyageList() throws SQLException
- {
- ObservableList voyagelist = FXCollections.observableArrayList();
-
- Statement ps=cnx.createStatement();
- String sql = "select id,destination, nom_voyage, duree_voyage,date,valabilite,image,prix from voyage";
- ResultSet rs;
- rs = ps.executeQuery(sql);
- voyage voyage;
- while (rs.next()) {
- voyage= new voyage(rs.getInt("id"),rs.getString("destination"),rs.getString("nom_voyage"),rs.getString("duree_voyage"),rs.getDate("date"),rs.getString("valabilite"),rs.getString("image"),rs.getFloat("prix"));
- //System.out.println(events);
- voyagelist.add(voyage);
-
- }
- return voyagelist;
- }
- public ObservableList getvoyageNon_Disponible() throws SQLException
- {
- ObservableList voyagelist = FXCollections.observableArrayList();
-
- Statement ps=cnx.createStatement();
- String sql = "select id,destination, nom_voyage, duree_voyage,date,valabilite,image,prix from voyage WHERE valabilite = 'Non Disponible'";
- ResultSet rs;
- rs = ps.executeQuery(sql);
- voyage voyage;
- while (rs.next()) {
- voyage= new voyage(rs.getInt("id"),rs.getString("destination"),rs.getString("nom_voyage"),rs.getString("duree_voyage"),rs.getDate("date"),rs.getString("valabilite"),rs.getString("image"),rs.getFloat("prix"));
- //System.out.println(events);
- voyagelist.add(voyage);
-
- }
- return voyagelist;
- }
- public ObservableList getvoyageDisponible() throws SQLException
- {
- ObservableList voyagelist = FXCollections.observableArrayList();
-
- Statement ps=cnx.createStatement();
- String sql = "select id,destination, nom_voyage, duree_voyage,date,valabilite,image,prix from voyage WHERE valabilite = 'Disponible'";
- ResultSet rs;
- rs = ps.executeQuery(sql);
- voyage voyage;
- while (rs.next()) {
- voyage= new voyage(rs.getInt("id"),rs.getString("destination"),rs.getString("nom_voyage"),rs.getString("duree_voyage"),rs.getDate("date"),rs.getString("valabilite"),rs.getString("image"),rs.getFloat("prix"));
- //System.out.println(events);
- voyagelist.add(voyage);
-
- }
- return voyagelist;
- } public ObservableList getvoyageBientot_Disponible() throws SQLException
- {
- ObservableList voyagelist = FXCollections.observableArrayList();
-
- Statement ps=cnx.createStatement();
- String sql = "select id,destination, nom_voyage, duree_voyage,date,valabilite,image,prix from voyage WHERE valabilite = 'Bientot Disponible'";
- ResultSet rs;
- rs = ps.executeQuery(sql);
- voyage voyage;
- while (rs.next()) {
- voyage= new voyage(rs.getInt("id"),rs.getString("destination"),rs.getString("nom_voyage"),rs.getString("duree_voyage"),rs.getDate("date"),rs.getString("valabilite"),rs.getString("image"),rs.getFloat("prix"));
- //System.out.println(events);
- voyagelist.add(voyage);
-
- }
- return voyagelist;
- }
- //---------------------------------------- Display Destination by ID --------------------------------------------------------------//
- public String getDestinationID(int idxx)
- {
- try{
- PreparedStatement ps= cnx.prepareStatement("select * from voyage where id=?");
- ps.setInt(1, idxx);
- ResultSet rs = ps.executeQuery();
- rs.beforeFirst();
-
- if (rs.next()) {
- return rs.getString("Destination");
- }
-
- } catch (SQLException ex) {
- Logger.getLogger(voyage.class.getName()).log(Level.SEVERE, null, ex);
- }
- return "";
- }
- public String getnomID(int idxx)
- {
- try{
- PreparedStatement ps= cnx.prepareStatement("select * from voyage where id=?");
- ps.setInt(1, idxx);
- ResultSet rs = ps.executeQuery();
- rs.beforeFirst();
-
- if (rs.next()) {
- return rs.getString("nom_voyage");
- }
-
- } catch (SQLException ex) {
- Logger.getLogger(voyage.class.getName()).log(Level.SEVERE, null, ex);
- }
- return "";
- }
- public String getduree_voyageID(int idxx)
- {
- try{
- PreparedStatement ps= cnx.prepareStatement("select * from voyage where id=?");
- ps.setInt(1, idxx);
- ResultSet rs = ps.executeQuery();
- rs.beforeFirst();
-
- if (rs.next()) {
- return rs.getString("duree_voyage");
- }
-
- } catch (SQLException ex) {
- Logger.getLogger(voyage.class.getName()).log(Level.SEVERE, null, ex);
- }
- return "";
- }
- public String getvalabiliteID(int idxx)
- {
- try{
- PreparedStatement ps= cnx.prepareStatement("select * from voyage where id=?");
- ps.setInt(1, idxx);
- ResultSet rs = ps.executeQuery();
- rs.beforeFirst();
-
- if (rs.next()) {
- return rs.getString("valabilite");
- }
-
- } catch (SQLException ex) {
- Logger.getLogger(voyage.class.getName()).log(Level.SEVERE, null, ex);
- }
- return "";
- }
-
- public float getprixID(int idxx)
- {
- try{
- PreparedStatement ps= cnx.prepareStatement("select * from voyage where id=?");
- ps.setInt(1, idxx);
- ResultSet rs = ps.executeQuery();
- rs.beforeFirst();
-
- if (rs.next()) {
- return rs.getFloat("prix");
- }
-
- } catch (SQLException ex) {
- Logger.getLogger(voyage.class.getName()).log(Level.SEVERE, null, ex);
- }
- return 0;
- }
- public void modifier(voyage v ,int id) {
- try {
-
-PreparedStatement ps= cnx.prepareStatement("UPDATE voyage SET clien_id=19,destination=?,nom_voyage=?,duree_voyage=?,date=?,valabilite=?,image=?,prix=? WHERE id=?");
- ps.setString(1,v.getDestination());
- ps.setString(2,v.getNom_voyage());
- ps.setString(3,v.getDuree_voyage());
- ps.setDate(4,v.getDate());
- ps.setString(5,v.getValabilite());
- ps.setString(6,v.getImage());
- ps.setInt(7,(int)v.getPrix());
- ps.setInt(8,id);
-
- ps.executeUpdate();
- System.out.println("voyage Modifer avec succ");
-
- } catch (SQLException ex) {
- Logger.getLogger(ServiceVoyage.class.getName()).log(Level.SEVERE, null, ex);
- }
-
- }
- public ObservableList chercherTitreplat(String chaine){
- String sql="SELECT * FROM voyage WHERE (destination LIKE ? or nom_voyage LIKE ? or duree_voyage LIKE ? or valabilite LIKE ? or prix = ? )";
-
- Connection cnx= MyDB.getInsatnce().getConnection();
- String ch=""+chaine+"%";
- System.out.println(sql);
- ObservableList myList= FXCollections.observableArrayList();
- try {
-
- Statement ste= cnx.createStatement();
- // PreparedStatement pst = myCNX.getCnx().prepareStatement(requete6);
- PreparedStatement stee =cnx.prepareStatement(sql);
- stee.setString(1, ch);
- stee.setString(2, ch);
- stee.setString(3, ch);
- stee.setString(4, ch);
- stee.setString(5, ch);
- System.out.println(stee);
-
- ResultSet rs = stee.executeQuery();
- while (rs.next()){
- voyage v = new voyage ();
- v.setDestination(rs.getString(3));
- v.setNom_voyage(rs.getString(4));
- v.setDuree_voyage(rs.getString(5));
- v.setDate(rs.getDate(6));
- v.setValabilite(rs.getString(7));
- v.setImage(rs.getString(8));
- v.setPrix(rs.getFloat(9));
-
- myList.add(v);
- System.out.println("titre trouvé! ");
- }
- } catch (SQLException ex) {
- System.out.println(ex.getMessage());
- }
- return myList;
- }
- //---------------------------------------- Excel -----------------------------------------------------------//
-
- public void getDefendants( String db) throws Exception {
-
- @SuppressWarnings("unused")
- Workbook rbook = WorkbookFactory.create(new FileInputStream("C:\\Users\\ASUS\\OneDrive\\Documents\\NetBeansProjects\\Dynamic-Developers\\test2.xls") );
- @SuppressWarnings("resource")
- Workbook writeWorkbook = (Workbook) new HSSFWorkbook();
- Sheet desSheet = writeWorkbook.createSheet("new sheet");
-
- Statement stmt = null;
- ResultSet rs = null;
- try{
- String query ="SELECT * FROM voyage"+db;
-
- stmt = cnx.createStatement();
- rs = stmt.executeQuery(query);
- ResultSetMetaData rsmd = rs.getMetaData();
- int columnsNumber = rsmd.getColumnCount();
-
- Row desRow1 = desSheet.createRow(0);
- for(int col=0 ;col < columnsNumber;col++) {
- Cell newpath = desRow1.createCell(col);
- newpath.setCellValue(rsmd.getColumnLabel(col+1));
- }
- while(rs.next()) {
- System.out.println("Row number" + rs.getRow() );
- Row desRow = desSheet.createRow(rs.getRow());
- for(int col=0 ;col < columnsNumber;col++) {
- Cell newpath = desRow.createCell(col);
- newpath.setCellValue(rs.getString(col+1));
- }
- FileOutputStream fileOut = new FileOutputStream("C:\\Users\\ASUS\\OneDrive\\Documents\\NetBeansProjects\\Dynamic-Developers\\test2.xls");
- writeWorkbook.write(fileOut);
- fileOut.close();
- }
- }
- catch (SQLException e) {
- System.out.println("Failed to get data from database");
- }
- }
-
- //--------------------------- NB Voyage ---------------------------------------------//
- public int calculnb(String destination) {
-
- PreparedStatement pre;
- int count = 19;
- try {
- Statement stmt = cnx.createStatement();
-
- String query = "SELECT COUNT(*) FROM voyage WHERE destination='"+destination+"'";
-
- ResultSet rs = stmt.executeQuery(query);
-
- rs.next();
- count = rs.getInt(1);
- return count;
- } catch (SQLException ex) {
- System.out.println(ex);
- }
- return 0;
-
- }
-
-}
\ No newline at end of file
diff --git a/Dynamic-Developers/src/Service/ServiseReserVoy.java b/Dynamic-Developers/src/Service/ServiseReserVoy.java
deleted file mode 100644
index 8b2d441..0000000
--- a/Dynamic-Developers/src/Service/ServiseReserVoy.java
+++ /dev/null
@@ -1,174 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Service;
-
-import Entity.ReserverVoyage;
-import Entity.voyage;
-import Util.MyDB;
-import java.sql.Connection;
-import java.sql.PreparedStatement;
-import java.sql.ResultSet;
-import java.sql.SQLException;
-import java.sql.Statement;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-
-/**
- *
- * @author ASUS
- */
-public class ServiseReserVoy implements IServiseReserVoy {
-
-
- Connection cnx;
-
- public ServiseReserVoy() {
- cnx=MyDB.getInsatnce().getConnection();
- }
-
-
- @Override
- public void AjouterReserverVoyage(ReserverVoyage r) {
- try {
- String req = "insert into reservation_voyage(id,client_id,voyage_id,date_reservation,travel_class, age)"
- +"values("+r.getId()+","+1+","+r.getVoyage_id()+",'"+r.getDate_reservation()+"','"+r.getTravel_Class()+"',"+r.getAge()+")";
- Statement st = cnx.createStatement();
- st.executeUpdate(req);
- System.out.println("Voyage ajouter avec succ");
- } catch (SQLException ex) {
- System.out.println(ex.getMessage()); } }
-
-
-@Override
- public void ModifierReserverVoyage(ReserverVoyage r) {
-try {
-
-// String req ="UPDATE `voyage` SET `clien_id`='19',`destination`='ag',`nom_voyage`='18',`duree_voyage`='15',`date`='0000-00-00',`valabilite`='12',`image`='12',`prix`='12' WHERE id=33;";
-
- String req ="UPDATE reservation_voyage SET date_reservation=?,travel_class=?,age=? WHERE id=?";
- PreparedStatement ps= cnx.prepareStatement(req); //req dynamic plus securiser
-
- // ps.setString(1,);
- ps.setDate(1,r.getDate_reservation());
- ps.setString(2,r.getTravel_Class());
- ps.setInt(3,(int)r.getAge());
- ps.setInt(4,r.getId());
- ps.executeUpdate();
- System.out.println("reservation_voyage Modifer avec succ");
-
- } catch (SQLException ex) {
- Logger.getLogger(ServiceVoyage.class.getName()).log(Level.SEVERE, null, ex);
- } }
-
- @Override
- public void SupprimerReserverVoyage(int ID) {
- try
- {
- Statement st = cnx.createStatement();
- String req = "DELETE FROM reservation_voyage WHERE id = "+ID+"";
- st.executeUpdate(req);
- System.out.println("La reservation_voyage avec l'id = "+ID+" a été supprimer avec succès...");
- } catch (SQLException ex) {
- System.out.println(ex.getMessage());
- }
- }
-
- /* @Override
- public List RecupererReserverVoyage() {
- List ReserverVoy = new ArrayList<>();
- try {
- String req ="select * from reservation_voyage";
- Statement st = cnx.createStatement();
- ResultSet rs = st.executeQuery(req);
- while(rs.next())
- {
- ReserverVoyage r = new ReserverVoyage();
- r.setId(rs.getInt("id"));
- r.setClient(rs.getInt("client_id"));
- // r.setVoyage(rs.getInt("voyage_id"));
- // r.setDate_reservation(rs.getString("date_reservation"));
- r.setTravel_Class(rs.getString("travel_class"));
- r.setAge(rs.getInt("age"));
-
- String req1 ="select * from voyage where id= "+rs.getInt("voyage_id")+"";
- Statement st1 = cnx.createStatement();
- ResultSet rs1 = st1.executeQuery(req1);
- while(rs1.next())
- {
- voyage v = new voyage();
- v.setID(rs1.getInt("id"));
- v.setDestination(rs1.getString("destination"));
- v.setNom_voyage(rs1.getString("nom_voyage"));
- v.setDuree_voyage(rs1.getString("duree_voyage"));
- v.setValabilite(rs1.getString("valabilite"));
- v.setImage(rs1.getString("image"));
- v.setPrix(rs1.getInt("prix"));
- r.setVoyage(v);
-
- }
-
- ReserverVoy.add(r);
- }
- } catch (SQLException ex) {
- System.err.println(ex.getMessage()); }
-
-return ReserverVoy; }
- */
-@Override
- public List RecupererReserverVoyage() {
- List ReserverVoyage = new ArrayList<>();
- // String sql ="select * from platt";
- String sql ="select reservation_voyage.id,voyage.nom_voyage ,reservation_voyage.date_reservation, reservation_voyage.travel_class, reservation_voyage.age from reservation_voyage INNER JOIN voyage where reservation_voyage.id=voyage.id ";
- try {
- Statement ste= cnx.createStatement();
- ResultSet rs =ste.executeQuery(sql);
- while(rs.next()){
- ReserverVoyage r = new ReserverVoyage();
- r.setId(rs.getInt("id"));
- r.setNom_voyage(rs.getString("nom_voyage"));
- //r.setDate_reservation(rs.getString("date_reservation"));
- r.setTravel_Class(rs.getString("travel_class"));
- r.setAge(rs.getInt("age"));
-
- ReserverVoyage.add(r);
- }
- } catch (SQLException ex) {
- System.out.println(ex.getMessage());
- }
- return ReserverVoyage;
-
- }
-
- public List getAll() {
- List list = new ArrayList();
- try {
- String requetee = "SELECT nom_voyage FROM voyage";
- PreparedStatement pst = cnx.prepareStatement(requetee);
- ResultSet rs = pst.executeQuery();
- System.out.println(rs.toString());
-
- while (rs.next()) {
- list.add(rs.getString("nom_voyage"));
- }
-
- return list;
- } catch (SQLException ex) {
- System.out.println(ex.getMessage());
- }
- return list;
- }
-
- public int chercherVoy(String Nom) throws SQLException{
- int id=0;
- String requetee = "SELECT id FROM voyage where nom_voyage='"+Nom+"';";
- PreparedStatement pst = cnx.prepareStatement(requetee);
- ResultSet rs = pst.executeQuery();
- while(rs.next())
- {id= rs.getInt("id");
- }return id;}
-}
diff --git a/Dynamic-Developers/src/Util/MyDB.java b/Dynamic-Developers/src/Util/MyDB.java
deleted file mode 100644
index 9a5a743..0000000
--- a/Dynamic-Developers/src/Util/MyDB.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Util;
-
-import java.sql.Connection;
-import java.sql.DriverManager;
-import java.sql.SQLException;
-
-/**
- *
- * @author ASUS
- */
-public class MyDB {
- final String url="jdbc:mysql://localhost:3306/pidev_travel_me";
-
- final String Username ="root";
-
- final String Password ="";
-
- private Connection connection;
-
- private static MyDB insatnce; //2- Declare une variable static de type class
-
- private MyDB() { // 1-Singleton Constructeur Private
- try {
- connection = DriverManager.getConnection(url,Username,Password);
- System.out.println("Connection etablie avec Succ");
- } catch (SQLException ex) {
- System.out.println(ex.getMessage()); }
- }
-
- public static MyDB getInsatnce() { // 3-Implemetation la getter de la variable static
- if(insatnce==null)
- {
- insatnce= new MyDB();
- }
- return insatnce;
- }
-
- public Connection getConnection() {
- return connection;
- }
-}
diff --git a/Dynamic-Developers/src/dynamic/developers/DynamicDevelopers.java b/Dynamic-Developers/src/dynamic/developers/DynamicDevelopers.java
deleted file mode 100644
index c080dd4..0000000
--- a/Dynamic-Developers/src/dynamic/developers/DynamicDevelopers.java
+++ /dev/null
@@ -1,99 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package dynamic.developers;
-
-import Entity.ReserverVoyage;
-import Entity.voyage;
-import Service.Scontrole_Voyage;
-import Service.ServiceVoyage;
-import Service.ServiseReserVoy;
-import Util.MyDB;
-import java.sql.Date;
-import java.util.ArrayList;
-import java.util.Calendar;
-import java.util.List;
-import java.text.DateFormat;
-import java.text.ParseException;
-import java.text.SimpleDateFormat;
-import java.util.Comparator;
-import java.util.stream.Collectors;
-/**
- *
- * @author ASUS
- */
-public class DynamicDevelopers {
-
- /**
- * @param args the command line arguments
- */
- public static void main(String[] args) {
- // public DynamicDevelopers() {
-
- // MyDB db = MyDB.getInsatnce();
- //Ajouter
- Date Datevoy=Date.valueOf("2022-10-10");
-
- voyage v = new voyage("AF","FGHANESTEN","25 Jour 24 nuit",Datevoy,"Non Disponible","Image",15);
- // ReserverVoyage r = new ReserverVoyage(2,1,v,"economic Class",null,15);
- ServiceVoyage ps = new ServiceVoyage();
- // ps.AjouterVoyage(v);
-
- //ps.ModifierVoyage(v);
-
- //ps.SupprimerVoyage(35);
-
- //Affichage
- List Listvoyage = new ArrayList<>();
-
- List Listreservationvoyage = new ArrayList<>();
-
- Listvoyage=ps.RecupererVoyage();
-
- /* Listvoyage.sort(new Comparator() {
- @Override
- public int compare(voyage o1, voyage o2) {
- return o2.getNom_voyage().compareTo(o1.getNom_voyage());
- }
- }); */
- /* List Listtrievoyage = new ArrayList<>();
-
- Listtrievoyage = Listvoyage.stream().sorted(new Comparator() {
- @Override
- public int compare(voyage o1, voyage o2) {
- return o2.getNom_voyage().compareTo(o1.getNom_voyage());
- }
- }).collect(Collectors.toList());
-
- */
- //Listvoyage=ps.RecupererVoyagetrieDestination();
-
- // Listvoyage=ps.RechercheVoyage("CA");
-
- // Listvoyage=ps.RecupererVoyageDisponible();
-
- // Listvoyage=ps.RecupererVoyageBientotdisponible();
-
- // Listvoyage=ps.RecupererVoyageNonDisponible();
-
- ServiseReserVoy pss = new ServiseReserVoy();
-
- //pss.SupprimerReserverVoyage(1);
-
- //pss.AjouterReserverVoyage(r);
-
- //pss.ModifierReserverVoyage(r);
-
-
- Listreservationvoyage=pss.RecupererReserverVoyage();
- Scontrole_Voyage sc= new Scontrole_Voyage();
-
- //System.out.println(Listvoyage);
- System.out.println(sc.isNumeric("a"));
-
- }
-}
-
-
diff --git a/Exemple Crud en java/3a29.sql b/Exemple Crud en java/3a29.sql
deleted file mode 100644
index f59d965..0000000
--- a/Exemple Crud en java/3a29.sql
+++ /dev/null
@@ -1,67 +0,0 @@
--- phpMyAdmin SQL Dump
--- version 5.1.1
--- https://www.phpmyadmin.net/
---
--- Host: 127.0.0.1
--- Generation Time: Apr 04, 2022 at 02:13 PM
--- Server version: 10.4.21-MariaDB
--- PHP Version: 7.4.23
-
-SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
-START TRANSACTION;
-SET time_zone = "+00:00";
-
-
-/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
-/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
-/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
-/*!40101 SET NAMES utf8mb4 */;
-
---
--- Database: `3a29`
---
-
--- --------------------------------------------------------
-
---
--- Table structure for table `personne`
---
-
-CREATE TABLE `personne` (
- `Id` int(11) NOT NULL,
- `Age` int(11) NOT NULL,
- `Nom` varchar(50) NOT NULL,
- `Prenom` varchar(50) NOT NULL
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
-
---
--- Dumping data for table `personne`
---
-
-INSERT INTO `personne` (`Id`, `Age`, `Nom`, `Prenom`) VALUES
-(1, 18, 'Aziz', 'BenIsmail');
-
---
--- Indexes for dumped tables
---
-
---
--- Indexes for table `personne`
---
-ALTER TABLE `personne`
- ADD PRIMARY KEY (`Id`);
-
---
--- AUTO_INCREMENT for dumped tables
---
-
---
--- AUTO_INCREMENT for table `personne`
---
-ALTER TABLE `personne`
- MODIFY `Id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;
-COMMIT;
-
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
diff --git a/Exemple Crud en java/ConnexionBaseDeDonnee(2).pdf b/Exemple Crud en java/ConnexionBaseDeDonnee(2).pdf
deleted file mode 100644
index d10cd12..0000000
Binary files a/Exemple Crud en java/ConnexionBaseDeDonnee(2).pdf and /dev/null differ
diff --git a/Exemple Crud en java/JavaApplication1/build.xml b/Exemple Crud en java/JavaApplication1/build.xml
deleted file mode 100644
index 9a33201..0000000
--- a/Exemple Crud en java/JavaApplication1/build.xml
+++ /dev/null
@@ -1,73 +0,0 @@
-
-
-
-
-
-
-
-
-
-
- Builds, tests, and runs the project JavaApplication1.
-
-
-
diff --git a/Exemple Crud en java/JavaApplication1/build/classes/.netbeans_automatic_build b/Exemple Crud en java/JavaApplication1/build/classes/.netbeans_automatic_build
deleted file mode 100644
index e69de29..0000000
diff --git a/Exemple Crud en java/JavaApplication1/build/classes/.netbeans_update_resources b/Exemple Crud en java/JavaApplication1/build/classes/.netbeans_update_resources
deleted file mode 100644
index e69de29..0000000
diff --git a/Exemple Crud en java/JavaApplication1/build/classes/Entity/Personne.class b/Exemple Crud en java/JavaApplication1/build/classes/Entity/Personne.class
deleted file mode 100644
index 5e0a9a1..0000000
Binary files a/Exemple Crud en java/JavaApplication1/build/classes/Entity/Personne.class and /dev/null differ
diff --git a/Exemple Crud en java/JavaApplication1/build/classes/GUI/Home$1.class b/Exemple Crud en java/JavaApplication1/build/classes/GUI/Home$1.class
deleted file mode 100644
index 33952d5..0000000
Binary files a/Exemple Crud en java/JavaApplication1/build/classes/GUI/Home$1.class and /dev/null differ
diff --git a/Exemple Crud en java/JavaApplication1/build/classes/GUI/Home.class b/Exemple Crud en java/JavaApplication1/build/classes/GUI/Home.class
deleted file mode 100644
index 3fe668e..0000000
Binary files a/Exemple Crud en java/JavaApplication1/build/classes/GUI/Home.class and /dev/null differ
diff --git a/Exemple Crud en java/JavaApplication1/build/classes/GUI/InscriptionForm.fxml b/Exemple Crud en java/JavaApplication1/build/classes/GUI/InscriptionForm.fxml
deleted file mode 100644
index e1529b6..0000000
--- a/Exemple Crud en java/JavaApplication1/build/classes/GUI/InscriptionForm.fxml
+++ /dev/null
@@ -1,21 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Exemple Crud en java/JavaApplication1/build/classes/GUI/InscriptionFormController.class b/Exemple Crud en java/JavaApplication1/build/classes/GUI/InscriptionFormController.class
deleted file mode 100644
index 989b167..0000000
Binary files a/Exemple Crud en java/JavaApplication1/build/classes/GUI/InscriptionFormController.class and /dev/null differ
diff --git a/Exemple Crud en java/JavaApplication1/build/classes/GUI/PersonneDetail.fxml b/Exemple Crud en java/JavaApplication1/build/classes/GUI/PersonneDetail.fxml
deleted file mode 100644
index a15718f..0000000
--- a/Exemple Crud en java/JavaApplication1/build/classes/GUI/PersonneDetail.fxml
+++ /dev/null
@@ -1,22 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Exemple Crud en java/JavaApplication1/build/classes/GUI/PersonneDetailController.class b/Exemple Crud en java/JavaApplication1/build/classes/GUI/PersonneDetailController.class
deleted file mode 100644
index 9731515..0000000
Binary files a/Exemple Crud en java/JavaApplication1/build/classes/GUI/PersonneDetailController.class and /dev/null differ
diff --git a/Exemple Crud en java/JavaApplication1/build/classes/Service/IService.class b/Exemple Crud en java/JavaApplication1/build/classes/Service/IService.class
deleted file mode 100644
index d1840ff..0000000
Binary files a/Exemple Crud en java/JavaApplication1/build/classes/Service/IService.class and /dev/null differ
diff --git a/Exemple Crud en java/JavaApplication1/build/classes/Service/PersonneServise.class b/Exemple Crud en java/JavaApplication1/build/classes/Service/PersonneServise.class
deleted file mode 100644
index ddccb3b..0000000
Binary files a/Exemple Crud en java/JavaApplication1/build/classes/Service/PersonneServise.class and /dev/null differ
diff --git a/Exemple Crud en java/JavaApplication1/build/classes/Util/MYDB.class b/Exemple Crud en java/JavaApplication1/build/classes/Util/MYDB.class
deleted file mode 100644
index 2475ef8..0000000
Binary files a/Exemple Crud en java/JavaApplication1/build/classes/Util/MYDB.class and /dev/null differ
diff --git a/Exemple Crud en java/JavaApplication1/build/classes/test/Main.class b/Exemple Crud en java/JavaApplication1/build/classes/test/Main.class
deleted file mode 100644
index f5994cf..0000000
Binary files a/Exemple Crud en java/JavaApplication1/build/classes/test/Main.class and /dev/null differ
diff --git a/Exemple Crud en java/JavaApplication1/manifest.mf b/Exemple Crud en java/JavaApplication1/manifest.mf
deleted file mode 100644
index 328e8e5..0000000
--- a/Exemple Crud en java/JavaApplication1/manifest.mf
+++ /dev/null
@@ -1,3 +0,0 @@
-Manifest-Version: 1.0
-X-COMMENT: Main-Class will be added automatically by build
-
diff --git a/Exemple Crud en java/JavaApplication1/nbproject/build-impl.xml b/Exemple Crud en java/JavaApplication1/nbproject/build-impl.xml
deleted file mode 100644
index c158f28..0000000
--- a/Exemple Crud en java/JavaApplication1/nbproject/build-impl.xml
+++ /dev/null
@@ -1,1420 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Must set src.dir
- Must set test.src.dir
- Must set build.dir
- Must set dist.dir
- Must set build.classes.dir
- Must set dist.javadoc.dir
- Must set build.test.classes.dir
- Must set build.test.results.dir
- Must set build.classes.excludes
- Must set dist.jar
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Must set javac.includes
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- No tests executed.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Must set JVM to use for profiling in profiler.info.jvm
- Must set profiler agent JVM arguments in profiler.info.jvmargs.agent
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Must select some files in the IDE or set javac.includes
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- To run this application from the command line without Ant, try:
-
- java -jar "${dist.jar.resolved}"
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Must select one file in the IDE or set run.class
-
-
-
- Must select one file in the IDE or set run.class
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Must select one file in the IDE or set debug.class
-
-
-
-
- Must select one file in the IDE or set debug.class
-
-
-
-
- Must set fix.includes
-
-
-
-
-
-
-
-
-
- This target only works when run from inside the NetBeans IDE.
-
-
-
-
-
-
-
-
- Must select one file in the IDE or set profile.class
- This target only works when run from inside the NetBeans IDE.
-
-
-
-
-
-
-
-
- This target only works when run from inside the NetBeans IDE.
-
-
-
-
-
-
-
-
-
-
-
-
- This target only works when run from inside the NetBeans IDE.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Must select one file in the IDE or set run.class
-
-
-
-
-
- Must select some files in the IDE or set test.includes
-
-
-
-
- Must select one file in the IDE or set run.class
-
-
-
-
- Must select one file in the IDE or set applet.url
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Must select some files in the IDE or set javac.includes
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Some tests failed; see details above.
-
-
-
-
-
-
-
-
- Must select some files in the IDE or set test.includes
-
-
-
- Some tests failed; see details above.
-
-
-
- Must select some files in the IDE or set test.class
- Must select some method in the IDE or set test.method
-
-
-
- Some tests failed; see details above.
-
-
-
-
- Must select one file in the IDE or set test.class
-
-
-
- Must select one file in the IDE or set test.class
- Must select some method in the IDE or set test.method
-
-
-
-
-
-
-
-
-
-
-
-
-
- Must select one file in the IDE or set applet.url
-
-
-
-
-
-
-
-
- Must select one file in the IDE or set applet.url
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Exemple Crud en java/JavaApplication1/nbproject/genfiles.properties b/Exemple Crud en java/JavaApplication1/nbproject/genfiles.properties
deleted file mode 100644
index f6e6d1e..0000000
--- a/Exemple Crud en java/JavaApplication1/nbproject/genfiles.properties
+++ /dev/null
@@ -1,8 +0,0 @@
-build.xml.data.CRC32=3569ad16
-build.xml.script.CRC32=360ae6d5
-build.xml.stylesheet.CRC32=8064a381@1.80.1.48
-# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
-# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
-nbproject/build-impl.xml.data.CRC32=3569ad16
-nbproject/build-impl.xml.script.CRC32=3e9f3573
-nbproject/build-impl.xml.stylesheet.CRC32=830a3534@1.80.1.48
diff --git a/Exemple Crud en java/JavaApplication1/nbproject/private/private.properties b/Exemple Crud en java/JavaApplication1/nbproject/private/private.properties
deleted file mode 100644
index d6d76f6..0000000
--- a/Exemple Crud en java/JavaApplication1/nbproject/private/private.properties
+++ /dev/null
@@ -1,2 +0,0 @@
-compile.on.save=true
-user.properties.file=C:\\Users\\ASUS\\AppData\\Roaming\\NetBeans\\8.2\\build.properties
diff --git a/Exemple Crud en java/JavaApplication1/nbproject/private/private.xml b/Exemple Crud en java/JavaApplication1/nbproject/private/private.xml
deleted file mode 100644
index 6807a2b..0000000
--- a/Exemple Crud en java/JavaApplication1/nbproject/private/private.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
-
-
-
diff --git a/Exemple Crud en java/JavaApplication1/src/Entity/Personne.java b/Exemple Crud en java/JavaApplication1/src/Entity/Personne.java
deleted file mode 100644
index 685a325..0000000
--- a/Exemple Crud en java/JavaApplication1/src/Entity/Personne.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Entity;
-
-/**
- *
- * @author ASUS
- */
-public class Personne {
- private int Id,Age;
- private String Nom,Prenom;
-
- public Personne(int Age, String Nom, String Prenom) {
- this.Age = Age;
- this.Nom = Nom;
- this.Prenom = Prenom;
- }
-
- public Personne(int Id, int Age, String Nom, String Prenom) {
- this.Id = Id;
- this.Age = Age;
- this.Nom = Nom;
- this.Prenom = Prenom;
- }
-
- public Personne() {
- }
-
- public int getId() {
- return Id;
- }
-
- public void setId(int Id) {
- this.Id = Id;
- }
-
- public int getAge() {
- return Age;
- }
-
- public void setAge(int Age) {
- this.Age = Age;
- }
-
- public String getNom() {
- return Nom;
- }
-
- public void setNom(String Nom) {
- this.Nom = Nom;
- }
-
- public String getPrenom() {
- return Prenom;
- }
-
- public void setPrenom(String Prenom) {
- this.Prenom = Prenom;
- }
-
- @Override
- public String toString() {
- return "Personne{" + "Id=" + Id + ", Age=" + Age + ", Nom=" + Nom + ", Prenom=" + Prenom + '}';
- }
-
-}
diff --git a/Exemple Crud en java/JavaApplication1/src/GUI/Home.java b/Exemple Crud en java/JavaApplication1/src/GUI/Home.java
deleted file mode 100644
index 57fc7c8..0000000
--- a/Exemple Crud en java/JavaApplication1/src/GUI/Home.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package GUI;
-
-import java.io.IOException;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-import javafx.application.Application;
-import javafx.event.ActionEvent;
-import javafx.event.EventHandler;
-import javafx.fxml.FXMLLoader;
-import javafx.scene.Parent;
-import javafx.scene.Scene;
-import javafx.scene.control.Button;
-import javafx.scene.layout.StackPane;
-import javafx.stage.Stage;
-
-/**
- *
- * @author ASUS
- */
-public class Home extends Application {
-
- @Override
- public void start(Stage primaryStage) {
-
- try {
- Parent root =FXMLLoader.load(getClass().getResource("InscriptionForm.fxml"));
- Scene scene = new Scene(root);
-
- primaryStage.setTitle("Hello World!");
- primaryStage.setScene(scene);
- primaryStage.show();
- } catch (IOException ex) {
- System.err.println(ex.getMessage());
- }
- }
-
- /**
- * @param args the command line arguments
- */
- public static void main(String[] args) {
- launch(args);
- }
-
-}
diff --git a/Exemple Crud en java/JavaApplication1/src/GUI/InscriptionForm.fxml b/Exemple Crud en java/JavaApplication1/src/GUI/InscriptionForm.fxml
deleted file mode 100644
index e1529b6..0000000
--- a/Exemple Crud en java/JavaApplication1/src/GUI/InscriptionForm.fxml
+++ /dev/null
@@ -1,21 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Exemple Crud en java/JavaApplication1/src/GUI/InscriptionFormController.java b/Exemple Crud en java/JavaApplication1/src/GUI/InscriptionFormController.java
deleted file mode 100644
index a1ed448..0000000
--- a/Exemple Crud en java/JavaApplication1/src/GUI/InscriptionFormController.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package GUI;
-
-import Entity.Personne;
-import Service.PersonneServise;
-import java.io.IOException;
-import java.net.URL;
-import java.util.ResourceBundle;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-import javafx.event.ActionEvent;
-import javafx.fxml.FXML;
-import javafx.fxml.FXMLLoader;
-import javafx.fxml.Initializable;
-import javafx.scene.Parent;
-import javafx.scene.control.Button;
-import javafx.scene.control.TextField;
-
-/**
- * FXML Controller class
- *
- * @author ASUS
- */
-public class InscriptionFormController implements Initializable {
-
- @FXML
- private TextField IDP;
- @FXML
- private TextField NomP;
- @FXML
- private TextField PrenomP;
- @FXML
- private TextField AgeP;
- @FXML
- private Button Save;
-
- /**
- * Initializes the controller class.
- */
- @Override
- public void initialize(URL url, ResourceBundle rb) {
- // TODO
- }
-
- @FXML
- private void SaveP(ActionEvent event) {
- try {
- String id=IDP.getText();
- String Nom=NomP.getText();
- String Prenom=PrenomP.getText();
- String Age=AgeP.getText();
- Personne p = new Personne(Integer.parseInt(id),Integer.parseInt(Age),Nom,Prenom);
-
- PersonneServise ps = new PersonneServise();
-
- ps.Ajouter(p);
-
- //Redirection
- FXMLLoader loader = new FXMLLoader(getClass().getResource("PersonneDetail.fxml"));
- Parent root = loader.load();
- PersonneDetailController pc = loader.getController();
- pc.setResid(id);
- pc.setResnom(Nom);
- pc.setResprenom(Prenom);
- pc.setResage(Age);
-
- IDP.getScene().setRoot(root);
-
- } catch (IOException ex) {
- System.out.println(ex.getMessage()); }
-
- }
-
-
-}
diff --git a/Exemple Crud en java/JavaApplication1/src/GUI/PersonneDetail.fxml b/Exemple Crud en java/JavaApplication1/src/GUI/PersonneDetail.fxml
deleted file mode 100644
index a15718f..0000000
--- a/Exemple Crud en java/JavaApplication1/src/GUI/PersonneDetail.fxml
+++ /dev/null
@@ -1,22 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/Exemple Crud en java/JavaApplication1/src/GUI/PersonneDetailController.java b/Exemple Crud en java/JavaApplication1/src/GUI/PersonneDetailController.java
deleted file mode 100644
index c6d6860..0000000
--- a/Exemple Crud en java/JavaApplication1/src/GUI/PersonneDetailController.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package GUI;
-
-import java.net.URL;
-import java.sql.Date;
-import java.util.ResourceBundle;
-import javafx.fxml.FXML;
-import javafx.fxml.Initializable;
-import javafx.scene.control.DatePicker;
-import javafx.scene.control.TextField;
-import javafx.scene.image.Image;
-import javafx.scene.image.ImageView;
-
-/**
- * FXML Controller class
- *
- * @author ASUS
- */
-public class PersonneDetailController implements Initializable {
-
- @FXML
- private TextField resid;
- @FXML
- private TextField resnom;
- @FXML
- private TextField resprenom;
- @FXML
- private TextField resage;
- @FXML
- private DatePicker picker;
- @FXML
- private ImageView ImageP;
-
- /**
- * Initializes the controller class.
- */
- @Override
- public void initialize(URL url, ResourceBundle rb) {
- // TODO
- //Date.valueOf(picker.getValue());
-
- //ImageP.setImage(new Image("C:/Users/ASUS/Downloads/2.png"));
- }
-
- public void setResid(String valeur) {
- this.resid.setText(valeur);
- }
-
- public void setResnom(String valeur) {
- this.resnom.setText(valeur);
- }
-
- public void setResprenom(String valeur) {
- this.resprenom.setText(valeur);
- }
-
- public void setResage(String valeur) {
- this.resage.setText(valeur);
- }
-
-}
diff --git a/Exemple Crud en java/JavaApplication1/src/Service/IService.java b/Exemple Crud en java/JavaApplication1/src/Service/IService.java
deleted file mode 100644
index 9a88f02..0000000
--- a/Exemple Crud en java/JavaApplication1/src/Service/IService.java
+++ /dev/null
@@ -1,19 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Service;
-
-import java.util.List;
-
-/**
- *
- * @author ASUS
- */
-public interface IService {
- public void Ajouter(T t) ;
- public void Modifier(T t);
- public void Supprimer(int ID);
- public ListRecuperer();
-}
diff --git a/Exemple Crud en java/JavaApplication1/src/Service/PersonneServise.java b/Exemple Crud en java/JavaApplication1/src/Service/PersonneServise.java
deleted file mode 100644
index b038638..0000000
--- a/Exemple Crud en java/JavaApplication1/src/Service/PersonneServise.java
+++ /dev/null
@@ -1,91 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Service;
-
-import Entity.Personne;
-import Util.MYDB;
-import java.sql.Connection;
-import java.sql.PreparedStatement;
-import java.sql.ResultSet;
-import java.sql.SQLException;
-import java.sql.Statement;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-
-/**
- *
- * @author ASUS
- */
-public class PersonneServise implements IService{
-
- Connection cnx;
-
- public PersonneServise() {
- cnx=MYDB.getInsatnce().getConnection();
- }
-
- @Override
- public void Ajouter(Personne p) {
- try {
- String req = "insert into Personne(id,nom,Prenom,age)"
- +"values("+p.getId()+",'"+p.getNom()+"','"+p.getPrenom()+"',"
- +""+p.getAge()+")";
- Statement st = cnx.createStatement();
- st.executeUpdate(req);
- System.out.println("Personne ajouter avec succ");
- } catch (SQLException ex) {
- System.out.println(ex.getMessage()); }
- }
-
- @Override
- public void Modifier(Personne p) {
- try {
- String req ="UPDATE personne SET Age=?,Nom=?,Prenom=? WHERE Id=?";
- PreparedStatement ps= cnx.prepareStatement(req);
-
- ps.setInt(1, p.getAge());
- ps.setString(2, p.getNom() );
- ps.setString(3, p.getPrenom());
- ps.setInt(4, p.getId());
-
- ps.executeUpdate();
- System.out.println("Personne Modifer avec succ");
-
- } catch (SQLException ex) {
- Logger.getLogger(PersonneServise.class.getName()).log(Level.SEVERE, null, ex);
- }
- }
-
- @Override
- public void Supprimer(int ID) {
- }
-
- @Override
- public List Recuperer() {
- List personnes = new ArrayList<>();
- try {
- String req ="select * from personne";
- Statement st = cnx.createStatement();
- ResultSet rs = st.executeQuery(req);
- while(rs.next())
- {
- Personne p = new Personne();
- p.setId(rs.getInt(1));
- p.setAge(rs.getInt("age"));
- p.setNom(rs.getString(3));
- p.setPrenom(rs.getString(4));
- personnes.add(p);
- }
- } catch (SQLException ex) {
- System.err.println(ex.getMessage()); }
-
-return personnes;
- }
-
-
-}
diff --git a/Exemple Crud en java/JavaApplication1/src/Util/MYDB.java b/Exemple Crud en java/JavaApplication1/src/Util/MYDB.java
deleted file mode 100644
index 674978d..0000000
--- a/Exemple Crud en java/JavaApplication1/src/Util/MYDB.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package Util;
-
-import java.sql.Connection;
-import java.sql.DriverManager;
-import java.sql.SQLException;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-
-/**
- *
- * @author ASUS
- */
-public class MYDB {
-
- final String url="jdbc:mysql://localhost:3306/3A29";
-
- final String Username ="root";
-
- final String Password ="";
-
- private Connection connection;
-
- private static MYDB insatnce; //2- Declare une variable static de type class
-
- private MYDB() { // 1-Singleton Constructeur Private
- try {
- connection = DriverManager.getConnection(url,Username,Password);
- System.out.println("Connection etablie avec Succ");
- } catch (SQLException ex) {
- System.out.println(ex.getMessage()); }
- }
-
- public static MYDB getInsatnce() { // 3-Implemetation la getter de la variable static
- if(insatnce==null)
- {
- insatnce= new MYDB();
- }
- return insatnce;
- }
-
- public Connection getConnection() {
- return connection;
- }
-
-}
diff --git a/Exemple Crud en java/JavaApplication1/src/test/Main.java b/Exemple Crud en java/JavaApplication1/src/test/Main.java
deleted file mode 100644
index de539a0..0000000
--- a/Exemple Crud en java/JavaApplication1/src/test/Main.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-package test;
-
-import Entity.Personne;
-import Service.PersonneServise;
-import Util.MYDB;
-
-/**
- *
- * @author ASUS
- */
-public class Main {
- public static void main(String[] args) {
- /*MYDB db = MYDB.getInsatnce();
- System.out.println(db);*/
-
-//Ajouter un Personne
-
- Personne p = new Personne(22,"Ben Isamil","Mohamed");
- PersonneServise ps = new PersonneServise();
- ps.Ajouter(p);
-
-//Modifier un Personne
-
- /* Personne p = new Personne(1,19,"Aziz","BenIsmail");
- PersonneServise ps = new PersonneServise();
- ps.Modifier(p);*/
-
-//Afficher
- // PersonneServise ps = new PersonneServise();
- System.out.println(ps.Recuperer());
- }
-}
diff --git a/Dynamic-Developers/build.xml b/ghofrane/dynamic_developpers/build.xml
similarity index 93%
rename from Dynamic-Developers/build.xml
rename to ghofrane/dynamic_developpers/build.xml
index cd2f41a..5f83bba 100644
--- a/Dynamic-Developers/build.xml
+++ b/ghofrane/dynamic_developpers/build.xml
@@ -7,8 +7,8 @@
-
- Builds, tests, and runs the project Dynamic-Developers.
+
+ Builds, tests, and runs the project dynamic_developpers.
-
+
@@ -450,7 +450,7 @@ is divided into following sections:
-
+
@@ -601,7 +601,7 @@ is divided into following sections:
-
+
@@ -893,7 +893,7 @@ is divided into following sections:
-
+
@@ -1378,7 +1378,7 @@ is divided into following sections:
-
+
diff --git a/Dynamic-Developers/nbproject/genfiles.properties b/ghofrane/dynamic_developpers/nbproject/genfiles.properties
similarity index 67%
rename from Dynamic-Developers/nbproject/genfiles.properties
rename to ghofrane/dynamic_developpers/nbproject/genfiles.properties
index 14d25d2..0c867af 100644
--- a/Dynamic-Developers/nbproject/genfiles.properties
+++ b/ghofrane/dynamic_developpers/nbproject/genfiles.properties
@@ -1,8 +1,8 @@
-build.xml.data.CRC32=a35623c0
-build.xml.script.CRC32=61f79969
+build.xml.data.CRC32=b11976bd
+build.xml.script.CRC32=a44441f7
build.xml.stylesheet.CRC32=8064a381@1.80.1.48
# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
-nbproject/build-impl.xml.data.CRC32=a35623c0
-nbproject/build-impl.xml.script.CRC32=a4a36d97
+nbproject/build-impl.xml.data.CRC32=b11976bd
+nbproject/build-impl.xml.script.CRC32=ad6a9507
nbproject/build-impl.xml.stylesheet.CRC32=830a3534@1.80.1.48
diff --git a/ghofrane/dynamic_developpers/nbproject/private/private.properties b/ghofrane/dynamic_developpers/nbproject/private/private.properties
new file mode 100644
index 0000000..91660d5
--- /dev/null
+++ b/ghofrane/dynamic_developpers/nbproject/private/private.properties
@@ -0,0 +1,2 @@
+compile.on.save=true
+user.properties.file=C:\\Users\\HP\\AppData\\Roaming\\NetBeans\\8.2\\build.properties
diff --git a/Exemple Crud en java/JavaApplication1/nbproject/project.properties b/ghofrane/dynamic_developpers/nbproject/project.properties
similarity index 78%
rename from Exemple Crud en java/JavaApplication1/nbproject/project.properties
rename to ghofrane/dynamic_developpers/nbproject/project.properties
index 47a74b0..d19f6a9 100644
--- a/Exemple Crud en java/JavaApplication1/nbproject/project.properties
+++ b/ghofrane/dynamic_developpers/nbproject/project.properties
@@ -24,13 +24,18 @@ debug.test.classpath=\
dist.archive.excludes=
# This directory is removed when the project is cleaned:
dist.dir=dist
-dist.jar=${dist.dir}/JavaApplication1.jar
+dist.jar=${dist.dir}/dynamic_developpers.jar
dist.javadoc.dir=${dist.dir}/javadoc
excludes=
+file.reference.mysql-connector-java-5.1.23-bin.jar=C:\\Users\\ASUS\\Downloads\\mysql-connector-java-5.1.23-bin.jar
+file.reference.mysql-connector-java-5.1.23-bin.jar-1=C:\\Users\\ASUS\\Desktop\\mysql-connector-java-5.1.23-bin.jar
+file.reference.mysql-connector-java-5.1.23-bin.jar-2=C:\\Users\\HP\\Desktop\\ghofrane\\mysql-connector-java-5.1.23-bin.jar
includes=**
jar.compress=false
javac.classpath=\
- ${libs.MySQLDriver.classpath}
+ ${file.reference.mysql-connector-java-5.1.23-bin.jar}:\
+ ${file.reference.mysql-connector-java-5.1.23-bin.jar-1}:\
+ ${file.reference.mysql-connector-java-5.1.23-bin.jar-2}
# Space-separated list of extra javac options
javac.compilerargs=
javac.deprecation=false
@@ -55,7 +60,7 @@ javadoc.splitindex=true
javadoc.use=true
javadoc.version=false
javadoc.windowtitle=
-main.class=test.Main
+main.class=edu.connexion3a29.gui.NewFXMain
manifest.file=manifest.mf
meta.inf.dir=${src.dir}/META-INF
mkdist.disabled=false
diff --git a/Exemple Crud en java/JavaApplication1/nbproject/project.xml b/ghofrane/dynamic_developpers/nbproject/project.xml
similarity index 91%
rename from Exemple Crud en java/JavaApplication1/nbproject/project.xml
rename to ghofrane/dynamic_developpers/nbproject/project.xml
index b466dd5..091951b 100644
--- a/Exemple Crud en java/JavaApplication1/nbproject/project.xml
+++ b/ghofrane/dynamic_developpers/nbproject/project.xml
@@ -3,7 +3,7 @@
org.netbeans.modules.java.j2seproject
- JavaApplication1
+ dynamic_developpers
diff --git a/ghofrane/dynamic_developpers/src/edu/connexion3a29/entities/Restaurant.java b/ghofrane/dynamic_developpers/src/edu/connexion3a29/entities/Restaurant.java
new file mode 100644
index 0000000..f697f26
--- /dev/null
+++ b/ghofrane/dynamic_developpers/src/edu/connexion3a29/entities/Restaurant.java
@@ -0,0 +1,83 @@
+/*
+ * To change this license header, choose License Headers in Project Properties.
+ * To change this template file, choose Tools | Templates
+ * and open the template in the editor.
+ */
+package edu.connexion3a29.entities;
+
+/**
+ *
+ * @author ASUS
+ */
+public class Restaurant {
+ private int id;
+ private String Nom_Restaurant;
+ private String Adresse_Restaurant;
+ private int Num_Tel_Restaurant ;
+ private String Description_Restaurant;
+
+ public Restaurant(){}
+
+ public Restaurant(int id, String Nom_Restaurant, String Adresse_Restaurant, int Num_Tel_Restaurant, String Description_Restaurant) {
+ this.id = id;
+ this.Nom_Restaurant = Nom_Restaurant;
+ this.Adresse_Restaurant = Adresse_Restaurant;
+ this.Num_Tel_Restaurant = Num_Tel_Restaurant;
+ this.Description_Restaurant = Description_Restaurant;
+ }
+
+ public Restaurant(String Nom_Restaurant, String Adresse_Restaurant, int Num_Tel_Restaurant, String Description_Restaurant) {
+ this.Nom_Restaurant = Nom_Restaurant;
+ this.Adresse_Restaurant = Adresse_Restaurant;
+ this.Num_Tel_Restaurant = Num_Tel_Restaurant;
+ this.Description_Restaurant = Description_Restaurant;
+ }
+
+ public int getId() {
+ return id;
+ }
+
+ public void setId(int id) {
+ this.id = id;
+ }
+
+ public String getNom_Restaurant() {
+ return Nom_Restaurant;
+ }
+
+ public void setNom_Restaurant(String Nom_Restaurant) {
+ this.Nom_Restaurant = Nom_Restaurant;
+ }
+
+ public String getAdresse_Restaurant() {
+ return Adresse_Restaurant;
+ }
+
+ public void setAdresse_Restaurant(String Adresse_Restaurant) {
+ this.Adresse_Restaurant = Adresse_Restaurant;
+ }
+
+ public int getNum_Tel_Restaurant() {
+ return Num_Tel_Restaurant;
+ }
+
+ public void setNum_Tel_Restaurant(int Num_Tel_Restaurant) {
+ this.Num_Tel_Restaurant = Num_Tel_Restaurant;
+ }
+
+ public String getDescription_Restaurant() {
+ return Description_Restaurant;
+ }
+
+ public void setDescription_Restaurant(String Description_Restaurant) {
+ this.Description_Restaurant = Description_Restaurant;
+ }
+
+ @Override
+ public String toString() {
+ return "Restaurant{" + "id=" + id + ", Nom_Restaurant=" + Nom_Restaurant + ", Adresse_Restaurant=" + Adresse_Restaurant + ", Num_Tel_Restaurant=" + Num_Tel_Restaurant + ", Description_Restaurant=" + Description_Restaurant + '}';
+ }
+
+
+
+}
diff --git a/ghofrane/dynamic_developpers/src/edu/connexion3a29/entities/RestaurantReservation.java b/ghofrane/dynamic_developpers/src/edu/connexion3a29/entities/RestaurantReservation.java
new file mode 100644
index 0000000..01c00a7
--- /dev/null
+++ b/ghofrane/dynamic_developpers/src/edu/connexion3a29/entities/RestaurantReservation.java
@@ -0,0 +1,86 @@
+/*
+ * To change this license header, choose License Headers in Project Properties.
+ * To change this template file, choose Tools | Templates
+ * and open the template in the editor.
+ */
+package edu.connexion3a29.entities;
+
+import java.sql.Date;
+
+/**
+ *
+ * @author ASUS
+ */
+public class RestaurantReservation {
+ private int Id;
+ private String Nom_Restaurant;
+
+ private String nom_Client;
+ private int Nbr_Personne;
+ private Date Date_Reservation;
+ public RestaurantReservation(){}
+
+ public RestaurantReservation(int Id, String Nom_Restaurant, String nom_Client, int Nbr_Personne, Date Date_Reservation) {
+ this.Id = Id;
+ this.Nom_Restaurant = Nom_Restaurant;
+ this.nom_Client = nom_Client;
+ this.Nbr_Personne = Nbr_Personne;
+ this.Date_Reservation = Date_Reservation;
+ }
+
+ public RestaurantReservation(String Nom_Restaurant, String nom_Client, int Nbr_Personne, Date Date_Reservation) {
+ this.Nom_Restaurant = Nom_Restaurant;
+ this.nom_Client = nom_Client;
+ this.Nbr_Personne = Nbr_Personne;
+ this.Date_Reservation = Date_Reservation;
+ }
+
+
+
+ public int getId() {
+ return Id;
+ }
+
+ public void setId(int Id) {
+ this.Id = Id;
+ }
+
+ public Date getDate_Reservation() {
+ return Date_Reservation;
+ }
+
+ public void setDate_Reservation(Date Date_Reservation) {
+ this.Date_Reservation = Date_Reservation;
+ }
+
+ public int getNbr_Personne() {
+ return Nbr_Personne;
+ }
+
+ public void setNbr_Personne(int Nbr_Personne) {
+ this.Nbr_Personne = Nbr_Personne;
+ }
+
+ public String getNom_Client() {
+ return nom_Client;
+ }
+
+ public void setNom_Client(String nom_Client) {
+ this.nom_Client = nom_Client;
+ }
+
+ public String getNom_Restaurant() {
+ return Nom_Restaurant;
+ }
+
+ public void setNom_Restaurant(String Nom_Restaurant) {
+ this.Nom_Restaurant = Nom_Restaurant;
+ }
+
+ @Override
+ public String toString() {
+ return "RestaurantReservation{" + "Id=" + Id + ", Date_Reservation=" + Date_Reservation + ", Nbr_Personne=" + Nbr_Personne + ", nom_Client=" + nom_Client + ", Nom_Restaurant=" + Nom_Restaurant + '}';
+ }
+
+
+}
diff --git a/Dynamic-Developers/src/Gui/Home.java b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/NewFXMain.java
similarity index 73%
rename from Dynamic-Developers/src/Gui/Home.java
rename to ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/NewFXMain.java
index de00900..e9831c7 100644
--- a/Dynamic-Developers/src/Gui/Home.java
+++ b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/NewFXMain.java
@@ -3,7 +3,7 @@
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
-package Gui;
+package edu.connexion3a29.gui;
import java.io.IOException;
import javafx.application.Application;
@@ -18,23 +18,22 @@
/**
*
- * @author ASUS
+ * @author HP
*/
-public class Home extends Application {
+public class NewFXMain extends Application {
-
@Override
public void start(Stage primaryStage) {
- try {
- Parent root =FXMLLoader.load(getClass().getResource("MenuDynamicDevelopers.fxml"));
+ try {
+ Parent root=
+ FXMLLoader.load(getClass().getResource("RestaurantReservation.fxml"));
Scene scene = new Scene(root);
- primaryStage.setTitle("Hello World!");
+ primaryStage.setTitle("Bienvenue 😃");
primaryStage.setScene(scene);
primaryStage.show();
} catch (IOException ex) {
- System.err.println(ex.getMessage());
- }
+ System.out.println(ex.getMessage());}
}
/**
diff --git a/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/Restaurant.fxml b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/Restaurant.fxml
new file mode 100644
index 0000000..9a90f3b
--- /dev/null
+++ b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/Restaurant.fxml
@@ -0,0 +1,63 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantC.fxml b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantC.fxml
new file mode 100644
index 0000000..4e9bcef
--- /dev/null
+++ b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantC.fxml
@@ -0,0 +1,26 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantController.java b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantController.java
new file mode 100644
index 0000000..7a0765b
--- /dev/null
+++ b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantController.java
@@ -0,0 +1,247 @@
+/*
+ * To change this license header, choose License Headers in Project Properties.
+ * To change this template file, choose Tools | Templates
+ * and open the template in the editor.
+ */
+package edu.connexion3a29.gui;
+
+import edu.connexion3a29.entities.Restaurant;
+import edu.connexion3a29.services.RestaurantCrud;
+import edu.connexion3a29.utils.MyConnection;
+import java.net.URL;
+import java.sql.Date;
+import java.sql.ResultSet;
+import java.sql.SQLException;
+import java.sql.Statement;
+import java.util.ResourceBundle;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+import javafx.collections.FXCollections;
+import javafx.collections.ObservableList;
+import javafx.event.ActionEvent;
+import javafx.fxml.FXML;
+import javafx.fxml.Initializable;
+import javafx.scene.control.Alert;
+import javafx.scene.control.Button;
+import javafx.scene.control.TableColumn;
+import javafx.scene.control.TableView;
+import javafx.scene.control.TextField;
+import javafx.scene.control.cell.PropertyValueFactory;
+import javafx.scene.input.MouseEvent;
+
+/**
+ * FXML Controller class
+ *
+ * @author HP
+ */
+public class RestaurantController implements Initializable {
+
+ @FXML
+ private TextField nom_res;
+ @FXML
+ private TextField adresse_res;
+ @FXML
+ private TextField numt_res;
+ @FXML
+ private TextField descp_res;
+ @FXML
+ private Button btn_aj_res;
+ @FXML
+ private Button btn_supp_res;
+ @FXML
+ private Button btn_mod_res;
+ @FXML
+ private Button btn_vi_res;
+ @FXML
+ private TableView table_res;
+ @FXML
+ private TableColumn nom_ress;
+ @FXML
+ private TableColumn adresse_ress;
+ @FXML
+ private TableColumn numt_ress;
+ @FXML
+ private TableColumn descp_ress;
+ public ObservableList data=FXCollections.observableArrayList();
+ int index=-1;
+ /**
+ * Initializes the controller class.
+ */
+ @Override
+ public void initialize(URL url, ResourceBundle rb) {
+ show();
+ // TODO
+ }
+ ObservableList Restaurant ;
+ MyConnection cnx = null;
+ Statement st = null;
+ RestaurantCrud rcd = new RestaurantCrud ();
+ public void updateTable_r(){
+ Restaurant= rcd.listerRestaurants();
+ table_res.getItems().setAll(Restaurant);
+ }
+ private boolean nom_resvalide(){
+ Pattern p = Pattern.compile("[a-zA-Z ]+");
+ Matcher m = p.matcher(nom_res.getText());
+ if(m.find() && m.group().equals(nom_res.getText())){
+ return true;
+ }else{
+ Alert alert = new Alert(Alert.AlertType.WARNING);
+ alert.setTitle("Type validé !");
+ alert.setHeaderText(null);
+ alert.setContentText("Veuillez entrer un type validé !");
+ alert.showAndWait();
+
+ return false;
+ }
+ }
+ private boolean adresse_resvalide(){
+ Pattern p = Pattern.compile("[a-zA-Z ]+");
+ Matcher m = p.matcher(adresse_res.getText());
+ if(m.find() && m.group().equals(adresse_res.getText())){
+ return true;
+ }else{
+ Alert alert = new Alert(Alert.AlertType.WARNING);
+ alert.setTitle("Type validé !");
+ alert.setHeaderText(null);
+ alert.setContentText("Veuillez entrer un type validé !");
+ alert.showAndWait();
+
+ return false;
+ }
+ }
+ private boolean descp_resvalide(){
+ Pattern p = Pattern.compile("[a-zA-Z ]+");
+ Matcher m = p.matcher(descp_res.getText());
+ if(m.find() && m.group().equals(descp_res.getText())){
+ return true;
+ }else{
+ Alert alert = new Alert(Alert.AlertType.WARNING);
+ alert.setTitle("Type validé !");
+ alert.setHeaderText(null);
+ alert.setContentText("Veuillez entrer un type validé !");
+ alert.showAndWait();
+
+ return false;
+ }
+ }
+ private boolean num_telvalide(){
+ Pattern p = Pattern.compile("[0-9]+");
+ Matcher m = p.matcher(numt_res.getText());
+ if(m.find() && m.group().equals(numt_res.getText())){
+ return true;
+ }else{
+ Alert alert = new Alert(Alert.AlertType.WARNING);
+ alert.setTitle("Type validé !");
+ alert.setHeaderText(null);
+ alert.setContentText("Veuillez entrer un type validé !");
+ alert.showAndWait();
+
+ return false;
+ }
+
+ }
+ @FXML
+ private void ajouter_res(ActionEvent event) {
+ RestaurantCrud rc = new RestaurantCrud();
+ if(nom_resvalide()&&descp_resvalide()&&num_telvalide()&&adresse_resvalide()){
+
+ String var1=nom_res.getText();
+ String var2=adresse_res.getText();
+ String var3=descp_res.getText();
+ String var4=numt_res.getText();
+ int var5=Integer.parseInt(var4);
+
+
+ Restaurant r =new Restaurant();
+
+ r.setNom_Restaurant(var1);
+ r.setAdresse_Restaurant(var2);
+ r.setNum_Tel_Restaurant(var5);
+ r.setDescription_Restaurant(var3);
+ rc.ajouter_restaurant(r);
+ updateTable_r();
+ nom_res.clear();
+ adresse_res.clear();
+ descp_res.clear();
+ numt_res.clear();
+
+ }
+ }
+
+ @FXML
+ private void supprimer_res(ActionEvent event) {
+ RestaurantCrud rcd = new RestaurantCrud ();
+ Restaurant R= new Restaurant();
+ R= table_res.getSelectionModel().getSelectedItem();
+ rcd.supprimer_restaurant(R);
+ updateTable_r();
+ }
+
+ @FXML
+ private void modifier_res(ActionEvent event) {
+ if(nom_resvalide()&&descp_resvalide()&&num_telvalide()&&adresse_resvalide()){
+ RestaurantCrud rc = new RestaurantCrud();
+ String var1=nom_res.getText();
+ String var2=adresse_res.getText();
+ String var3=descp_res.getText();
+ String var4=numt_res.getText();
+ int var5=Integer.parseInt(var4);
+ Restaurant r =new Restaurant();
+ r.setNom_Restaurant(var1);
+ r.setAdresse_Restaurant(var2);
+ r.setNum_Tel_Restaurant(var5);
+ r.setDescription_Restaurant(var3);
+ r=table_res.getSelectionModel().getSelectedItem();
+ rc.modifier_restaurant(r,var1,var2,var5,var3);
+ updateTable_r();
+ nom_res.clear();
+ adresse_res.clear();
+ descp_res.clear();
+ numt_res.clear();
+ }
+
+
+}
+
+ @FXML
+ private void vider_res(ActionEvent event) {
+ nom_res.clear();
+ adresse_res.clear();
+ descp_res.clear();
+ numt_res.clear();
+ }
+
+ @FXML
+ private void getSelected(MouseEvent event) {
+ index=table_res.getSelectionModel().getSelectedIndex();
+ if(index<=-1){
+ return ;
+ }
+ nom_res.setText(nom_ress.getCellData(index).toString());
+ adresse_res.setText(adresse_ress.getCellData(index).toString());
+ descp_res.setText(descp_ress.getCellData(index).toString());
+ numt_res.setText(numt_ress.getCellData(index).toString());
+
+ }
+
+
+ public void show(){
+ try {
+ String requete="SELECT * FROM restaurants";
+ Statement st = MyConnection.getinstance().getCnx().createStatement();
+ ResultSet rs= st.executeQuery(requete);
+ while(rs.next()){
+ data.add(new Restaurant(rs.getInt(1),rs.getString(2),rs.getString(3),rs.getInt(4),rs.getString(5)));
+ }
+ } catch (SQLException ex) {
+ System.out.println(ex.getMessage());
+ }
+
+ nom_ress.setCellValueFactory(new PropertyValueFactory("Nom_Restaurant"));
+ adresse_ress.setCellValueFactory(new PropertyValueFactory("Adresse_Restaurant"));
+ numt_ress.setCellValueFactory(new PropertyValueFactory("Num_Tel_Restaurant"));
+ descp_ress.setCellValueFactory(new PropertyValueFactory("Description_Restaurant"));
+ table_res.setItems(data);
+ }
+ }
diff --git a/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantReservation.fxml b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantReservation.fxml
new file mode 100644
index 0000000..b9e89ac
--- /dev/null
+++ b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantReservation.fxml
@@ -0,0 +1,64 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantReservationC.fxml b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantReservationC.fxml
new file mode 100644
index 0000000..18ac1b3
--- /dev/null
+++ b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantReservationC.fxml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantReservationController.java b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantReservationController.java
new file mode 100644
index 0000000..d7ddd73
--- /dev/null
+++ b/ghofrane/dynamic_developpers/src/edu/connexion3a29/gui/RestaurantReservationController.java
@@ -0,0 +1,232 @@
+/*
+ * To change this license header, choose License Headers in Project Properties.
+ * To change this template file, choose Tools | Templates
+ * and open the template in the editor.
+ */
+package edu.connexion3a29.gui;
+
+import edu.connexion3a29.entities.RestaurantReservation;
+import edu.connexion3a29.services.RestaurantReservationCrud;
+import edu.connexion3a29.utils.MyConnection;
+import java.net.URL;
+import java.sql.Date;
+import java.sql.ResultSet;
+import java.sql.SQLException;
+import java.sql.Statement;
+import java.util.ResourceBundle;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+import javafx.collections.FXCollections;
+import javafx.collections.ObservableList;
+import javafx.event.ActionEvent;
+import javafx.fxml.FXML;
+import javafx.fxml.Initializable;
+import javafx.scene.control.Alert;
+import javafx.scene.control.Button;
+import javafx.scene.control.DatePicker;
+import javafx.scene.control.TableColumn;
+import javafx.scene.control.TableView;
+import javafx.scene.control.TextField;
+import javafx.scene.control.cell.PropertyValueFactory;
+import javafx.scene.input.MouseEvent;
+
+/**
+ * FXML Controller class
+ *
+ * @author HP
+ */
+public class RestaurantReservationController implements Initializable {
+
+ @FXML
+ private TextField nom_res1;
+ @FXML
+ private TextField nom_c1;
+ @FXML
+ private TextField nbr_pers1;
+ @FXML
+ private DatePicker date_res1;
+ @FXML
+ private Button btn_aj_reser;
+ @FXML
+ private Button btn_supp_reser;
+ @FXML
+ private Button btn_mod_reser;
+ @FXML
+ private Button btn_vider_reser;
+ @FXML
+ private TableView table_reser;
+ @FXML
+ private TableColumn< RestaurantReservation, String> nom_ress1;
+ @FXML
+ private TableColumn< RestaurantReservation, String> nom_cc1;
+ @FXML
+ private TableColumn< RestaurantReservation, Integer> nbr_perss1;
+ @FXML
+ private TableColumn< RestaurantReservation, Date> date_ress1;
+ public ObservableList data=FXCollections.observableArrayList();
+ int index=-1;
+ /**
+ * Initializes the controller class.
+ */
+ @Override
+ public void initialize(URL url, ResourceBundle rb) {
+ show();
+ // TODO
+ }
+ ObservableList< RestaurantReservation> Restaurant ;
+ MyConnection cnx = null;
+ Statement st = null;
+ RestaurantReservationCrud rcd = new RestaurantReservationCrud ();
+ public void updateTable_r(){
+ Restaurant= rcd.listerRestaurantReservations();
+ table_reser.getItems().setAll(Restaurant);
+ }
+ private boolean nom_resvalide(){
+ Pattern p = Pattern.compile("[a-zA-Z ]+");
+ Matcher m = p.matcher(nom_res1.getText());
+ if(m.find() && m.group().equals(nom_res1.getText())){
+ return true;
+ }else{
+ Alert alert = new Alert(Alert.AlertType.WARNING);
+ alert.setTitle("Type validé !");
+ alert.setHeaderText(null);
+ alert.setContentText("Veuillez entrer un type validé !");
+ alert.showAndWait();
+
+ return false;
+ }
+ }
+ private boolean nom_cvalide(){
+ Pattern p = Pattern.compile("[a-zA-Z ]+");
+ Matcher m = p.matcher(nom_c1.getText());
+ if(m.find() && m.group().equals(nom_c1.getText())){
+ return true;
+ }else{
+ Alert alert = new Alert(Alert.AlertType.WARNING);
+ alert.setTitle("Type validé !");
+ alert.setHeaderText(null);
+ alert.setContentText("Veuillez entrer un type validé !");
+ alert.showAndWait();
+
+ return false;
+ }
+ }
+
+ private boolean nbr_persvalide(){
+ Pattern p = Pattern.compile("[0-9]+");
+ Matcher m = p.matcher(nbr_pers1.getText());
+ if(m.find() && m.group().equals(nbr_pers1.getText())){
+ return true;
+ }else{
+ Alert alert = new Alert(Alert.AlertType.WARNING);
+ alert.setTitle("Type validé !");
+ alert.setHeaderText(null);
+ alert.setContentText("Veuillez entrer un type validé !");
+ alert.showAndWait();
+
+ return false;
+ }
+
+ }
+
+ @FXML
+ private void ajouter_reser(ActionEvent event) {
+ RestaurantReservationCrud rc = new RestaurantReservationCrud();
+ if(nom_resvalide()&& nom_cvalide()&& nbr_persvalide()){
+
+ String var1=nom_res1.getText();
+ String var2=nom_c1.getText();
+ Date var3 = Date.valueOf(date_res1.getValue());
+ String var4=nbr_pers1.getText();
+ int var5=Integer.parseInt(var4);
+
+
+ RestaurantReservation r =new RestaurantReservation();
+
+ r.setNom_Restaurant(var1);
+ r.setNom_Client(var2);
+ r.setNbr_Personne(var5);
+ r.setDate_Reservation(var3);
+ rc.ajouter_restaurantreservation(r);
+ updateTable_r();
+ nom_res1.clear();
+ nom_c1.clear();
+ date_res1.setValue(null);
+ nbr_pers1.clear();
+ }
+ }
+
+ @FXML
+ private void supprimer_reser(ActionEvent event) {
+ RestaurantReservationCrud rcd = new RestaurantReservationCrud ();
+ RestaurantReservation R= new RestaurantReservation();
+ R= table_reser.getSelectionModel().getSelectedItem();
+ rcd.supprimer_RestaurantReservation(R);
+ updateTable_r();
+ }
+
+
+ @FXML
+ private void modifier_reser(ActionEvent event) {
+ if(nom_resvalide()&& nom_cvalide()&& nbr_persvalide()){
+ RestaurantReservationCrud rc = new RestaurantReservationCrud();
+ String var1=nom_res1.getText();
+ String var2=nom_c1.getText();
+ String var4=nbr_pers1.getText();
+ Date var3 = Date.valueOf(date_res1.getValue());
+ int var5=Integer.parseInt(var4);
+ RestaurantReservation r =new RestaurantReservation();
+ r.setNom_Restaurant(var1);
+ r.setNom_Client(var2);
+ r.setNbr_Personne(var5);
+ r.setDate_Reservation(var3);
+ r=table_reser.getSelectionModel().getSelectedItem();
+ rc.modifier_RestaurantReservation(r,var1,var2,var5,var3);
+ updateTable_r();
+ nom_res1.clear();
+ nom_c1.clear();
+ date_res1.setValue(null);
+ nbr_pers1.clear();
+ }
+ }
+
+ @FXML
+ private void vider_reser(ActionEvent event) {
+ nom_res1.clear();
+ nom_c1.clear();
+ date_res1.setValue(null);
+ nbr_pers1.clear();
+ }
+
+ @FXML
+ private void getSelected(MouseEvent event) {
+ index=table_reser.getSelectionModel().getSelectedIndex();
+ if(index<=-1){
+ return ;
+ }
+ nom_res1.setText(nom_ress1.getCellData(index).toString());
+ nom_c1.setText(nom_cc1.getCellData(index).toString());
+ nbr_pers1.setText(nbr_perss1.getCellData(index).toString());
+ date_res1.setValue(date_ress1.getCellData(index).toLocalDate());
+ }
+
+ public void show(){
+ try {
+ String requete="SELECT * FROM restaurantsreservations";
+ Statement st = MyConnection.getinstance().getCnx().createStatement();
+ ResultSet rs= st.executeQuery(requete);
+ while(rs.next()){
+ data.add(new RestaurantReservation(rs.getInt(1),rs.getString(2),rs.getString(3),rs.getInt(4),rs.getDate(5)));
+ }
+ } catch (SQLException ex) {
+ System.out.println(ex.getMessage());
+ }
+
+ nom_ress1.setCellValueFactory(new PropertyValueFactory("Nom_Restaurant"));
+ nom_cc1.setCellValueFactory(new PropertyValueFactory("nom_Client"));
+ nbr_perss1.setCellValueFactory(new PropertyValueFactory("Nbr_Personne"));
+ date_ress1.setCellValueFactory(new PropertyValueFactory("Date_Reservation"));
+ table_reser.setItems(data);
+ }
+
+}
diff --git a/ghofrane/dynamic_developpers/src/edu/connexion3a29/image/272149638_1118373955679460_5291939741314529835_n.png b/ghofrane/dynamic_developpers/src/edu/connexion3a29/image/272149638_1118373955679460_5291939741314529835_n.png
new file mode 100644
index 0000000..9c8b229
Binary files /dev/null and b/ghofrane/dynamic_developpers/src/edu/connexion3a29/image/272149638_1118373955679460_5291939741314529835_n.png differ
diff --git a/ghofrane/dynamic_developpers/src/edu/connexion3a29/services/RestaurantCrud.java b/ghofrane/dynamic_developpers/src/edu/connexion3a29/services/RestaurantCrud.java
new file mode 100644
index 0000000..c9210a5
--- /dev/null
+++ b/ghofrane/dynamic_developpers/src/edu/connexion3a29/services/RestaurantCrud.java
@@ -0,0 +1,121 @@
+/*
+ * To change this license header, choose License Headers in Project Properties.
+ * To change this template file, choose Tools | Templates
+ * and open the template in the editor.
+ */
+package edu.connexion3a29.services;
+
+import edu.connexion3a29.entities.Restaurant;
+import edu.connexion3a29.utils.MyConnection;
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+import java.sql.SQLException;
+import java.sql.Statement;
+import javafx.collections.FXCollections;
+import javafx.collections.ObservableList;
+
+/**
+ *
+ * @author ASUS
+ */
+public class RestaurantCrud {
+ public void ajouter_restaurant(Restaurant r) {
+ try {
+ String requete1 = "INSERT INTO restaurants(Nom_Restaurant,Adresse_Restaurant,Num_Tel_Restaurant,Description_Restaurant) VALUES(?,?,?,?)";
+ PreparedStatement pst = MyConnection.getinstance().getCnx().prepareStatement(requete1);
+ pst.setString(1, r.getNom_Restaurant());
+ pst.setString(2, r.getAdresse_Restaurant());
+ pst.setInt(3, r.getNum_Tel_Restaurant());
+ pst.setString(4, r.getDescription_Restaurant());
+ pst.executeUpdate();
+ System.out.println("Restaurant ajouté !");
+
+ } catch (SQLException ex) {
+ System.out.println(ex.getMessage());
+ }
+ }
+ public ObservableList listerRestaurants() {
+ ObservableList myList = FXCollections.observableArrayList();
+ try {
+
+ String requete2 = "Select * FROM restaurants";
+ Statement st = MyConnection.getinstance().getCnx().createStatement();
+ ResultSet rs = st.executeQuery(requete2);
+ while (rs.next()) {
+ Restaurant rec = new Restaurant();
+ rec.setId(rs.getInt(1));
+ rec.setNom_Restaurant(rs.getString("Nom_Restaurant"));
+ rec.setAdresse_Restaurant(rs.getString("Adresse_Restaurant"));
+ rec.setNum_Tel_Restaurant(rs.getInt("Num_Tel_Restaurant"));
+ rec.setDescription_Restaurant(rs.getString("Description_Restaurant"));
+ myList.add(rec);
+
+ }
+ } catch (SQLException ex) {
+ System.out.println(ex.getMessage());
+
+ }
+ return myList;
+ }
+ public void supprimer_restaurant(Restaurant R) {
+
+ try {
+ String requete3 = "DELETE FROM restaurants WHERE id=" + R.getId();
+ Statement st = MyConnection.getinstance().getCnx().createStatement();
+
+ st.executeUpdate(requete3);
+ System.out.println("Restaurant supprimé !");
+
+ } catch (SQLException ex) {
+ System.err.println(ex.getMessage());
+ }
+
+ }
+// public void supprimer_restaurant(int id) {
+//
+// try {
+// String requete3 = "DELETE FROM restaurants WHERE id=" + id;
+// Statement st = MyConnection.getinstance().getCnx().createStatement();
+//
+// st.executeUpdate(requete3);
+// System.out.println("Restaurant supprimé !");
+//
+// } catch (SQLException ex) {
+// System.err.println(ex.getMessage());
+// }
+//
+// }
+
+ public void modifier_restaurant(Restaurant r, String Nom_Restaurant, String Adresse_Restaurant,int Num_Tel_Restaurant ,String Description_Restaurant) {
+ try {
+ String requete4 = " UPDATE restaurants SET " + " Nom_Restaurant= ?, Adresse_Restaurant = ? , Num_Tel_Restaurant = ?,Description_Restaurant = ? WHERE id= " + r.getId();
+ PreparedStatement pst = MyConnection.getinstance().getCnx().prepareStatement(requete4);
+ pst.setString(1, Nom_Restaurant);
+ pst.setString(2, Adresse_Restaurant);
+ pst.setInt(3, Num_Tel_Restaurant);
+ pst.setString(4, Description_Restaurant);
+ pst.executeUpdate();
+ System.out.println("Restaurant modifié !");
+
+ } catch (SQLException ex) {
+ System.err.println(ex.getMessage());
+ }
+ }
+// }
+// public void modifier_restaurant(int id,String Nom_Restaurant, String Adresse_Restaurant,int Num_Tel_Restaurant ,String Description_Restaurant) {
+// try {
+// String requete4 = " UPDATE restaurants SET " + " Nom_Restaurant= ?, Adresse_Restaurant = ? , Num_Tel_Restaurant = ?,Description_Restaurant = ? WHERE id= "+ id;
+// PreparedStatement pst = MyConnection.getinstance().getCnx().prepareStatement(requete4);
+// pst.setString(1, Nom_Restaurant);
+// pst.setString(2, Adresse_Restaurant);
+// pst.setInt(3, Num_Tel_Restaurant);
+// pst.setString(4, Description_Restaurant);
+// pst.executeUpdate();
+// System.out.println("Restaurant modifié !");
+//
+// } catch (SQLException ex) {
+// System.err.println(ex.getMessage());
+// }
+// }
+
+}
diff --git a/ghofrane/dynamic_developpers/src/edu/connexion3a29/services/RestaurantReservationCrud.java b/ghofrane/dynamic_developpers/src/edu/connexion3a29/services/RestaurantReservationCrud.java
new file mode 100644
index 0000000..702c2d0
--- /dev/null
+++ b/ghofrane/dynamic_developpers/src/edu/connexion3a29/services/RestaurantReservationCrud.java
@@ -0,0 +1,122 @@
+/*
+ * To change this license header, choose License Headers in Project Properties.
+ * To change this template file, choose Tools | Templates
+ * and open the template in the editor.
+ */
+package edu.connexion3a29.services;
+
+import edu.connexion3a29.entities.RestaurantReservation;
+import edu.connexion3a29.utils.MyConnection;
+import java.sql.Date;
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+import java.sql.SQLException;
+import java.sql.Statement;
+import javafx.collections.FXCollections;
+import javafx.collections.ObservableList;
+
+/**
+ *
+ * @author ASUS
+ */
+public class RestaurantReservationCrud {
+ public void ajouter_restaurantreservation(RestaurantReservation r) {
+ try {
+ String requete1 = "INSERT INTO restaurantsreservations(Nom_Restaurant,nom_Client,Nbr_Personne,Date_Reservation) VALUES(?,?,?,?)";
+ PreparedStatement pst = MyConnection.getinstance().getCnx().prepareStatement(requete1);
+ pst.setDate(4, r.getDate_Reservation());
+ pst.setInt(3, r.getNbr_Personne());
+ pst.setString(2, r.getNom_Client());
+ pst.setString(1, r.getNom_Restaurant());
+ pst.executeUpdate();
+ System.out.println(" Reservation Restaurant ajouté !");
+
+ } catch (SQLException ex) {
+ System.out.println(ex.getMessage());
+ }
+ }
+ public ObservableList listerRestaurantReservations() {
+ ObservableList myList = FXCollections.observableArrayList();
+ try {
+
+ String requete2 = "Select * FROM restaurantsreservations";
+ Statement st = MyConnection.getinstance().getCnx().createStatement();
+ ResultSet rs = st.executeQuery(requete2);
+ while (rs.next()) {
+ RestaurantReservation rec = new RestaurantReservation();
+ rec.setId(rs.getInt(1));
+ rec.setNom_Restaurant(rs.getString("Nom_Restaurant"));
+ rec. setNom_Client(rs.getString("nom_Client"));
+ rec.setNbr_Personne(rs.getInt("Nbr_Personne"));
+ rec.setDate_Reservation(rs.getDate("Date_Reservation"));
+
+
+ myList.add(rec);
+
+ }
+ } catch (SQLException ex) {
+ System.out.println(ex.getMessage());
+
+ }
+ return myList;
+ }
+ public void supprimer_RestaurantReservation(RestaurantReservation R) {
+
+ try {
+ String requete3 = "DELETE FROM restaurantsreservations WHERE id=" + R.getId();
+ Statement st = MyConnection.getinstance().getCnx().createStatement();
+
+ st.executeUpdate(requete3);
+ System.out.println(" Reservation Restaurant supprimé !");
+
+ } catch (SQLException ex) {
+ System.err.println(ex.getMessage());
+ }
+
+ }
+// public void supprimer_RestaurantReservation(int id) {
+//
+// try {
+// String requete3 = "DELETE FROM restaurantsreservations WHERE id=" + id;
+// Statement st = MyConnection.getinstance().getCnx().createStatement();
+//
+// st.executeUpdate(requete3);
+// System.out.println("Reservation Restaurant supprimé !");
+//
+// } catch (SQLException ex) {
+// System.err.println(ex.getMessage());
+// }
+//
+// }
+
+ public void modifier_RestaurantReservation(RestaurantReservation r,String Nom_Restaurant, String nom_Client,int Nbr_Personne,Date Date_Reservation) {
+ try {
+ String requete4 = " UPDATE restaurantsreservations SET " + " Nom_Restaurant = ?,nom_Client=?, Nbr_Personne = ? ,Date_Reservation= ? WHERE id= " + r.getId();
+ PreparedStatement pst = MyConnection.getinstance().getCnx().prepareStatement(requete4);
+ pst.setString(1, Nom_Restaurant);
+ pst.setString(2, nom_Client);
+ pst.setInt(3, Nbr_Personne);
+ pst.setDate(4, Date_Reservation);
+ pst.executeUpdate();
+ System.out.println("Reservation Restaurant modifié !");
+
+ } catch (SQLException ex) {
+ System.err.println(ex.getMessage());
+ }
+ }
+// public void modifier_RestaurantReservation(int id,String Nom_Restaurant, String nom_Client,int Nbr_Personne,Date Date_Reservation) {
+// try {
+// String requete4 = " UPDATE restaurantsreservations SET " + " Nom_Restaurant = ?,nom_Client=?, Nbr_Personne = ? ,Date_Reservation= ?WHERE id= "+ id;
+// PreparedStatement pst = MyConnection.getinstance().getCnx().prepareStatement(requete4);
+// pst.setString(1, Nom_Restaurant);
+// pst.setString(2, nom_Client);
+// pst.setInt(3, Nbr_Personne);
+// pst.setDate(4, Date_Reservation);
+// pst.executeUpdate();
+// System.out.println("Reservation Restaurant modifié !");
+//
+// } catch (SQLException ex) {
+// System.err.println(ex.getMessage());
+// }
+// }
+}
diff --git a/ghofrane/dynamic_developpers/src/edu/connexion3a29/tests/MainClass.java b/ghofrane/dynamic_developpers/src/edu/connexion3a29/tests/MainClass.java
new file mode 100644
index 0000000..0850b2c
--- /dev/null
+++ b/ghofrane/dynamic_developpers/src/edu/connexion3a29/tests/MainClass.java
@@ -0,0 +1,61 @@
+/*
+ * To change this license header, choose License Headers in Project Properties.
+ * To change this template file, choose Tools | Templates
+ * and open the template in the editor.
+ */
+package edu.connexion3a29.tests;
+
+import edu.connexion3a29.entities.Restaurant;
+import edu.connexion3a29.entities.RestaurantReservation;
+import edu.connexion3a29.services.RestaurantCrud;
+import edu.connexion3a29.services.RestaurantReservationCrud;
+import java.util.Date;
+import java.text.ParseException;
+import java.text.SimpleDateFormat;
+import java.text.ParseException;
+import java.text.SimpleDateFormat;
+import java.util.Arrays;
+
+import java.util.List;
+
+
+/**
+ *
+ * @author ASUS
+ */
+public class MainClass {
+
+ /**
+ * @param args the command line arguments
+ */
+ public static void main(String[] args) {
+ // TODO code application logic here
+ RestaurantCrud rc=new RestaurantCrud();
+ Restaurant r= new Restaurant("brodway","menzah6",41707517,"blablabla");
+ //rc.ajouter_restaurant(r);
+ // System.out.println(rc.listerRestaurants());
+ // rc.supprimer_restaurant(r);
+ //rc.modifier_restaurant(1, "ffff", "rrrr", 0111, "eeee");
+ //rc.supprimer_restaurant(1);
+ SimpleDateFormat f = new SimpleDateFormat("dd-MM-yyyy");
+ String string_date = "12-02-2040";
+
+ long milliseconds_date= 0;
+
+ try {
+ Date dD = f.parse(string_date);
+
+ milliseconds_date= dD.getTime();
+
+ } catch (ParseException e) {
+ e.printStackTrace();
+ }
+ RestaurantReservationCrud rcd=new RestaurantReservationCrud();
+ RestaurantReservation rr=new RestaurantReservation("tt","tt",66,new java.sql.Date(milliseconds_date));
+ // rcd.ajouter_restaurantreservation(rr);
+ // System.out.println(rcd.listerRestaurantReservations());
+ // rcd.modifier_RestaurantReservation(1,"rr", "uuu", 0,new java.sql.Date(milliseconds_date));
+ // rcd.supprimer_RestaurantReservation(1);
+ }
+
+}
diff --git a/ghofrane/dynamic_developpers/src/edu/connexion3a29/utils/MyConnection.java b/ghofrane/dynamic_developpers/src/edu/connexion3a29/utils/MyConnection.java
new file mode 100644
index 0000000..4bbfedd
--- /dev/null
+++ b/ghofrane/dynamic_developpers/src/edu/connexion3a29/utils/MyConnection.java
@@ -0,0 +1,45 @@
+/*
+ * To change this license header, choose License Headers in Project Properties.
+ * To change this template file, choose Tools | Templates
+ * and open the template in the editor.
+ */
+package edu.connexion3a29.utils;
+
+import java.sql.Connection;
+import java.sql.DriverManager;
+import java.sql.SQLException;
+
+/**
+ *
+ * @author ASUS
+ */
+public class MyConnection {
+ public String url="jdbc:mysql://localhost:3306/travelme";
+ public String login="root";
+ public String pwd="";
+ Connection cnx;
+ public static MyConnection instance;
+ private MyConnection() {
+ try {
+ cnx=DriverManager.getConnection(url, login, pwd);
+ System.out.println("connexion établie !");
+ } catch (SQLException ex) {
+ System.err.println(ex.getMessage());
+ }
+ }
+
+ public Connection getCnx() {
+ return cnx;
+ }
+
+ public static MyConnection getinstance()
+ {
+ if(instance==null)
+ {
+ instance=new MyConnection();
+ }
+ return instance;
+ }
+
+
+}
diff --git a/Dynamic-Developers/dist/lib/mysql-connector-java-5.1.23-bin.jar b/ghofrane/mysql-connector-java-5.1.23-bin.jar
similarity index 100%
rename from Dynamic-Developers/dist/lib/mysql-connector-java-5.1.23-bin.jar
rename to ghofrane/mysql-connector-java-5.1.23-bin.jar