|
|
|
@ -3,6 +3,7 @@
|
|
|
|
|
#include <errno.h>
|
|
|
|
|
#include "saeP2.h"
|
|
|
|
|
#include <string.h>
|
|
|
|
|
#include "../annexe/saeAnnexe.h"
|
|
|
|
|
|
|
|
|
|
candidat* LoadCandid(void)
|
|
|
|
|
{
|
|
|
|
@ -154,10 +155,35 @@ void ListeCandidat(int nbcandidat,candidat *tcandidat)
|
|
|
|
|
printf("Candidat non trouvé");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void Candidater()
|
|
|
|
|
void Candidater(VilleIUT* tiut[],int *tlogi, candidat* tcandidat, int numcandid)
|
|
|
|
|
{
|
|
|
|
|
char VilleRech[31];
|
|
|
|
|
printf("Veuillez entrez la ville de l'IUT au quel vous souhaitez candidatez :");
|
|
|
|
|
scanf("%s",VilleRech);
|
|
|
|
|
int ind=rechercheIUT(tiut,*tlogi,VilleRech);
|
|
|
|
|
if(ind==-1) return;
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
char DepRech[31];
|
|
|
|
|
printf("Veuillez entrez le département dans lequel vous souhaitez y postuler :");
|
|
|
|
|
scanf("%s",DepRech);
|
|
|
|
|
if (existeDep(tiut[ind]->ldept, DepRech)==0) return;
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
int i;
|
|
|
|
|
for (i=0;tcandidat[i].numcandid!=numcandid;++i);
|
|
|
|
|
voeu* voeu_ajout = (voeu*) malloc (sizeof(voeu));
|
|
|
|
|
strcpy(voeu_ajout->ville,VilleRech);
|
|
|
|
|
strcpy(voeu_ajout->dep,DepRech);
|
|
|
|
|
voeu_ajout->ddep=0;
|
|
|
|
|
voeu_ajout->vcand=0;
|
|
|
|
|
tcandidat[i].TabVoeu[tcandidat[i].nbchoix]=voeu_ajout;
|
|
|
|
|
tcandidat[i].nbchoix++;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//void gestionPhaseCandidatures(); A FAIRE.
|