-
Notifications
You must be signed in to change notification settings - Fork 0
/
C_Global.cpp
71 lines (61 loc) · 1.79 KB
/
C_Global.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
#include "C_Global.h"
using namespace Composants;
C_Global::C_Global() {
}
int C_Global::getParam() {
return this->param;
}
String^ C_Global::getModif() {
return this->modif;
}
String^ C_Global::getValeur() {
return this->valeur;
}
String^ C_Global::getTable() {
return this->table;
}
void C_Global::setParam(int Param) {
this->param = Param;
}
void C_Global::setModif(String^ Modif) {
this->modif = Modif;
}
void C_Global::setTable(String^ Table) {
this->table = Table;
}
void C_Global::setValeur(String^ Valeur) {
this->valeur = Valeur;
}
String^ C_Global::update() {
return "UPDATE" + this->getTable() + "SET " + this->getModif() + "='" + this->getValeur() + "' WHERE id_person = " + this->getParam();
}
String^ C_Global::select() {
return "SELECT * FROM " + this->getTable() + " CROSS JOIN client WHERE " + this->getTable() + ".id_person = person.id_person";
}
String^ C_Global::selectParam() {
return "SELECT " + this->getParam() + "FROM " + this->getTable() + " CROSS JOIN client WHERE " + this->getTable() + ".id_person=" + this->getParam() + "";
}
String^ C_Global::delet() {
return "Rien";
}
void C_Global::setMail(String^ Mail) {
this->mail = Mail;
}
void C_Global::setPassword(String^Password) {
this->password = Password;
}
String^ C_Global::getMail() {
return this->mail;
}
String^ C_Global::getPassword() {
return this->password;
}
String^ C_Global::checkType() {
return "SELECT (typeOf) FROM staff WHERE staff.mail=" + this->getMail() + ";";
}
String^ C_Global::mailVerif() {
return "SELECT COUNT * FROM staff WHERE mail=" + this->getMail() + ";";
}
String^ C_Global::MailPassword() {
return "SELECT COUNT * FROM staff WHERE (SELECT (password) FROM staff where mail=" + this->getMail() + ")=" + this->getPassword() + ";";
}