From 38812a33fb0e7b5e63fbf20ab6dfa1fb32396325 Mon Sep 17 00:00:00 2001 From: "medhi.rodrigues" Date: Thu, 13 Mar 2025 10:27:03 +0100 Subject: [PATCH] PAs de doc 3 --- GSBapplication/src/Metier/Observation.java | 54 ------------------- GSBapplication/src/TEST/testMain.java | 4 +- .../src/acces_aux_donnes/MedicamentSQL.java | 2 +- .../src/presentation/jffAjoutObservation.java | 4 +- .../src/presentation/jffConnexion.java | 4 +- .../src/presentation/jffFamilleMedoc.java | 4 +- .../src/presentation/jffInfoMedoc.java | 4 +- 7 files changed, 11 insertions(+), 65 deletions(-) delete mode 100644 GSBapplication/src/Metier/Observation.java diff --git a/GSBapplication/src/Metier/Observation.java b/GSBapplication/src/Metier/Observation.java deleted file mode 100644 index 4fd5939..0000000 --- a/GSBapplication/src/Metier/Observation.java +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license - * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template - */ - -package Metier; - -/** - * - * @author medhi.rodrigues - */ -public class Observation { - /** - * observation = l'observation d'un médicament - */ - private String observation; - private String idMedoc; - private int idPraticien; - - //Constructeur - public Observation(String idMedoc,int idPraticien, String observ){ - this.idMedoc = idMedoc; - this.idPraticien = idPraticien; - this.observation = observ; - } - - //LES GUETTEUR - /** - * @return the observation - */ - public String getObservation() { - return observation; - } - - /** - * @return l'identifiant du médicament - */ - public String getIdMedoc(){ - return this.idMedoc; - } - - /** - * - * @return l'identifiant du praticien - */ - public int getIdPraticien(){ - return this.idPraticien; - } - - - - - -} diff --git a/GSBapplication/src/TEST/testMain.java b/GSBapplication/src/TEST/testMain.java index 1209e29..a2bfa13 100644 --- a/GSBapplication/src/TEST/testMain.java +++ b/GSBapplication/src/TEST/testMain.java @@ -4,8 +4,8 @@ */ package TEST; -import acces_aux_donnes.connexionSQL; -import acces_aux_donnes.praticienSQL; +import acces_aux_donnes.ConnexionSQL; +import acces_aux_donnes.PraticienSQL; import acces_aux_donnes.MedicamentSQL; import java.sql.Connection; diff --git a/GSBapplication/src/acces_aux_donnes/MedicamentSQL.java b/GSBapplication/src/acces_aux_donnes/MedicamentSQL.java index baa8764..39f8a75 100644 --- a/GSBapplication/src/acces_aux_donnes/MedicamentSQL.java +++ b/GSBapplication/src/acces_aux_donnes/MedicamentSQL.java @@ -19,7 +19,7 @@ public class MedicamentSQL { private ResultSet result = null; public MedicamentSQL() { - connexionTest = connexionSQL.getConnect("10.121.38.75","bdgsb","adminGSB","mdpGSB"); + connexionTest = ConnexionSQL.getConnect("10.121.38.75","bdgsb","adminGSB","mdpGSB"); } public ArrayList rechercherMedicament (String nomCo){ diff --git a/GSBapplication/src/presentation/jffAjoutObservation.java b/GSBapplication/src/presentation/jffAjoutObservation.java index 52c9f73..ade7b60 100644 --- a/GSBapplication/src/presentation/jffAjoutObservation.java +++ b/GSBapplication/src/presentation/jffAjoutObservation.java @@ -4,7 +4,7 @@ */ package presentation; -import acces_aux_donnes.observationSQL; +import acces_aux_donnes.ObservationSQL; /** * @@ -94,7 +94,7 @@ public class jffAjoutObservation extends javax.swing.JFrame { }// //GEN-END:initComponents private void jBsoumettreActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jBsoumettreActionPerformed - observationSQL observ = new observationSQL(); + ObservationSQL observ = new ObservationSQL(); observ.ajouterObservation(this.idMedoc, this.idPraticien, jTAobservation.getText()); }//GEN-LAST:event_jBsoumettreActionPerformed diff --git a/GSBapplication/src/presentation/jffConnexion.java b/GSBapplication/src/presentation/jffConnexion.java index aa1c02a..cb2abd9 100644 --- a/GSBapplication/src/presentation/jffConnexion.java +++ b/GSBapplication/src/presentation/jffConnexion.java @@ -4,7 +4,7 @@ */ package presentation; -import acces_aux_donnes.praticienSQL; +import acces_aux_donnes.PraticienSQL; /** * @@ -158,7 +158,7 @@ public class jffConnexion extends javax.swing.JFrame { private void jBValiderActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jBValiderActionPerformed String identifiant = jTFIdentifiant.getText(); String mdp = String.valueOf(jPFmdp.getPassword()); - praticienSQL testPraticien = new praticienSQL(); + PraticienSQL testPraticien = new PraticienSQL(); String [] lePraticien = testPraticien.rechercherPraticien(identifiant,mdp); if (lePraticien[0] != null){ System.out.print("TEST REUSSIE"); diff --git a/GSBapplication/src/presentation/jffFamilleMedoc.java b/GSBapplication/src/presentation/jffFamilleMedoc.java index a668c0a..aa0d791 100644 --- a/GSBapplication/src/presentation/jffFamilleMedoc.java +++ b/GSBapplication/src/presentation/jffFamilleMedoc.java @@ -4,7 +4,7 @@ */ package presentation; -import Metier.medicament; +import Metier.Medicament; import acces_aux_donnes.MedicamentSQL; import java.util.ArrayList; @@ -103,7 +103,7 @@ public class jffFamilleMedoc extends javax.swing.JFrame { String effetTrouve = rechercheMedoc.get(3); String contreIndicationTrouve = rechercheMedoc.get(4); String imgTrouve = "../img/"+ idTrouve +".jpg"; - medicament medocTrouve = new medicament(idTrouve, nomTrouve , compositionTrouve, effetTrouve + Medicament medocTrouve = new Medicament(idTrouve, nomTrouve , compositionTrouve, effetTrouve , contreIndicationTrouve,imgTrouve); new jffInfoMedoc(medocTrouve).setVisible(true); diff --git a/GSBapplication/src/presentation/jffInfoMedoc.java b/GSBapplication/src/presentation/jffInfoMedoc.java index 807e801..d05668a 100644 --- a/GSBapplication/src/presentation/jffInfoMedoc.java +++ b/GSBapplication/src/presentation/jffInfoMedoc.java @@ -4,7 +4,7 @@ */ package presentation; -import Metier.medicament; +import Metier.Medicament; /** * @@ -15,7 +15,7 @@ public class jffInfoMedoc extends javax.swing.JFrame { /** * Creates new form jffInfoMedoc */ - public jffInfoMedoc(medicament medocTrouve) { + public jffInfoMedoc(Medicament medocTrouve) { initComponents(); }