From c139d1f1ee602930772af2058a75d2707b6ff5a4 Mon Sep 17 00:00:00 2001 From: DahmaneYanis Date: Thu, 5 Jan 2023 15:12:01 +0100 Subject: [PATCH 1/3] =?UTF-8?q?Modification=20du=20git=20+=20cr=C3=A9ation?= =?UTF-8?q?=20d'un=20fichier=20test?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitignore | 3 ++- source/main.c | 5 +++-- source/sae.c | 6 +++--- source/test.c | 19 +++++++++++++++++++ 4 files changed, 27 insertions(+), 6 deletions(-) create mode 100644 source/test.c diff --git a/.gitignore b/.gitignore index 878db66..fb66af2 100644 --- a/.gitignore +++ b/.gitignore @@ -2,4 +2,5 @@ a.out *.gch *.vscode* -exe* \ No newline at end of file +exe* +.nfs* \ No newline at end of file diff --git a/source/main.c b/source/main.c index 839760e..ae2fa94 100644 --- a/source/main.c +++ b/source/main.c @@ -1,13 +1,14 @@ #include "../header/sae.h" - +void testJean(void); int main(void) { + testJean(); #ifdef _WIN32 color #endif - Globale(); + //Globale(); //system("color 01"); diff --git a/source/sae.c b/source/sae.c index 36beac0..805391f 100644 --- a/source/sae.c +++ b/source/sae.c @@ -20,7 +20,7 @@ void Globale(void) tLog = chargementLog("../donnees/log.don"); //Appel du menu visiteur - //menuVisiteur(); + menuVisiteur(tLog); //Sauvegarde dans les fichiers } @@ -83,7 +83,7 @@ Log * chargementLog(char * nomFichier) * choixMenuVisiteur. Selon le choix de l'utilisateur, la fonction appelle la fonction correspondante * ou met fin à l'exécution de la fonction. */ -void menuVisiteur(void) +void menuVisiteur(Log * tLog) //void menuVisiteur(VilleIut *villeIut, int nbVilles) { int choix; @@ -98,7 +98,7 @@ void menuVisiteur(void) switch(choix) { case 1: - //afficheVillesIUT(villeIut, nbVilles); + //afficheVillesIUT(villeIut, 0); printf("Affiche les villes qui ont des IUT. (En attente de la fonction de chargement)\n"); break; case 2: diff --git a/source/test.c b/source/test.c new file mode 100644 index 0000000..0fefc61 --- /dev/null +++ b/source/test.c @@ -0,0 +1,19 @@ +#include "../header/sae.h" + + +/** + * @brief Test fonction Jean + * + */ +void testJean(void) +{ + VilleIut **tIut = (VilleIut **)malloc(sizeof(VilleIut *)*5); + strcpy(tIut[0]->nom, "John"); + strcpy(tIut[0]->ldept->nomDept, "Info"); + strcpy(tIut[0]->ldept->resp, "YAnis"); + tIut[0]->ldept->nbP = 12; + tIut[0]->ldept->suiv = NULL; + + + //afficheVillesIUT(tIut, 0); +} From 2d323409b19323de64f35a0f1df6e918e06971a6 Mon Sep 17 00:00:00 2001 From: DahmaneYanis Date: Thu, 5 Jan 2023 15:12:33 +0100 Subject: [PATCH 2/3] =?UTF-8?q?Oups=20j'ai=20oubli=C3=A9=20sae.h=20git=20a?= =?UTF-8?q?dd=20header!=20MY=20BAD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- header/sae.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/header/sae.h b/header/sae.h index 3f11c18..bfc1641 100644 --- a/header/sae.h +++ b/header/sae.h @@ -90,7 +90,7 @@ typedef struct void Globale(void); Log * chargementLog(char * nomFichier); //void menuVisiteur(VilleIut *villeIut, int nbVilles); -void menuVisiteur(void); +void menuVisiteur(Log * tLog); int afficherMenuVisiteur(void); int choixMenuVisiteur(void); void banniereConnection(void); From 8751226a3629aecedc890d5fd43686000149ad15 Mon Sep 17 00:00:00 2001 From: DahmaneYanis Date: Thu, 5 Jan 2023 15:19:44 +0100 Subject: [PATCH 3/3] =?UTF-8?q?Programme=20=C3=A0=20nouveau=20fonctionnel?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- source/main.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/source/main.c b/source/main.c index ae2fa94..df5064d 100644 --- a/source/main.c +++ b/source/main.c @@ -1,14 +1,13 @@ #include "../header/sae.h" -void testJean(void); int main(void) { - testJean(); + #ifdef _WIN32 color #endif - //Globale(); + Globale(); //system("color 01");