|
|
|
@ -28,11 +28,13 @@ void sauvegardeArticles(int reference[], float weight[], float volume[], float u
|
|
|
|
|
void sauvegardeClients(int clientID[], int clientPassword[], float cagnotte[], int suspended[], int isAdmin[], int tLogClient);
|
|
|
|
|
|
|
|
|
|
//! DECALAGES TABLEAUX
|
|
|
|
|
void decalageADroite(int tab[], int index, int tlog);
|
|
|
|
|
void decalageAGauche(int tab[], int index, int tlog);
|
|
|
|
|
void decalageADroiteInt(int tab[], int index, int tlog);
|
|
|
|
|
void decalageAGaucheInt(int tab[], int index, int tlog);
|
|
|
|
|
void decalageADroiteFloat(float tab[], int index, int tlog);
|
|
|
|
|
void decalageAGaucheFloat(float tab[], int index, int tlog);
|
|
|
|
|
|
|
|
|
|
//! GESTION CLIENTS
|
|
|
|
|
int inputClient(int id, int passwd, int index, int clientID[], int clientPassword[], float cagnotte[], int suspended[], int isAdmin[], int *tlog);
|
|
|
|
|
void inputClient(int id, int passwd, int index, int clientID[], int clientPassword[], float cagnotte[], int suspended[], int isAdmin[], int *tlog);
|
|
|
|
|
void modifyClient(int clientID[], float cagnotte[], int suspended[], int isAdmin[], int tlog);
|
|
|
|
|
void deleteClient(int clientID[], float cagnotte[], int suspended[], int isAdmin[], int *tlog);
|
|
|
|
|
|
|
|
|
@ -52,12 +54,13 @@ int searchTab(int targetTab[], int valSearched, int tLog, int *found);
|
|
|
|
|
//! PANIER
|
|
|
|
|
void clientConstraint(float *weight, float *volume, float *price);
|
|
|
|
|
int constraintExceeded(float weightConstraint, float volumeConstraint, float *priceConstraint, float *cagnotte, float tabWeight[], float tabVolume[], float tabPrice[], int tabItemRef[], int tabBasketRef[], int tabBasketQuantity[], int tlogItem, int tlogBasket);
|
|
|
|
|
int basket_add (int tab_reference[], float unitPrice[], float *cagnotte, int basket_tab_ref[], int basket_tab_qte[], int tlog, int tlog_basket);
|
|
|
|
|
void display_basket(int basket_tab_ref[], int basket_qte[], float weight[], float volume[], float cagnotte[], float unitPrice[], int tlog, int tlog_basket);
|
|
|
|
|
int basket_del_article( int basket_tab_ref[], int basket_tab_qte[], int tlog_basket);
|
|
|
|
|
void basket_add(int tab_reference[], float unitPrice[], float *cagnotte, int basket_tab_ref[], int basket_tab_qte[], int tlogItem, int *tlog_basket);
|
|
|
|
|
void display_basket(int basket_tab_ref[], int tabItemRef[], int basket_qte[], float tabWeight[], float tabVolume[], float cagnotte, float tabUnitPrice[], int tlogItem, int tlog_basket);
|
|
|
|
|
void reinit_basket(int *tlog_basket);
|
|
|
|
|
void basket_del_article(int basket_tab_ref[], int basket_tab_qte[], int *tlog_basket);
|
|
|
|
|
|
|
|
|
|
//! LOGIN
|
|
|
|
|
int login(int clientID[], int clientPassword[], int isAdmin[], int tlog);
|
|
|
|
|
int login(int clientID[], int clientPassword[], int isAdmin[], int tlog, int *index);
|
|
|
|
|
int signup(int clientID[], int clientPassword[], float cagnotte[], int suspended[], int isAdmin[], int *tlog);
|
|
|
|
|
|
|
|
|
|
//! MOT DE PASSE
|
|
|
|
@ -65,5 +68,5 @@ int encrypt(int password);
|
|
|
|
|
int decrypt(int password);
|
|
|
|
|
|
|
|
|
|
//! MENUS
|
|
|
|
|
void adminMenu(void);
|
|
|
|
|
void clientMenu(float *weight, float *volume, float *price);
|
|
|
|
|
void adminMenu(int clientID[], int clientPassword[], float cagnotte[], int suspended[], int isAdmin[], int tabReference[], float tabWeight[], float tabVolume[], float unitPrice[], int *tlogItem, int *tlogClient);
|
|
|
|
|
void clientMenu(float *weight, float *volume, float *price, int tabItemRef[], float unitPrice[], float *cagnotte, int basket_tab_ref[], int basket_tab_qte[], float tabWeight[], float tabVolume[], int tlogItem, int *tlogBasket);
|