Compare commits

...

5 Commits

Author SHA1 Message Date
Hug0lvt 4dc209a8fe Correction diagramme de classe
continuous-integration/drone/push Build is passing Details
2 years ago
Lucas EVARD a9204cf152 Depot MLD et script TABLE
continuous-integration/drone/push Build is passing Details
2 years ago
Hugo LIVET d7e3839507 Ajout de Sonnar
continuous-integration/drone/push Build is passing Details
2 years ago
Lucas EVARD 91d835adbb Dépot du script des tables de la base de donnée et script gestion des conversions
continuous-integration/drone/push Build is passing Details
2 years ago
Nicolas MAYE 9e0ea8fd52 ajustement de la branche documentation
continuous-integration/drone/push Build is passing Details
2 years ago

@ -21,3 +21,23 @@ steps:
- dotnet restore CI_CONSECO.sln
- dotnet test CI_CONSECO.sln --no-restore
depends_on: [build]
- name: code-analysis
image: hub.codefirst.iut.uca.fr/thomas.bellembois/codefirst-dronesonarplugin-dotnet6
commands:
- cd Code/
- dotnet restore CI_CONSECO.sln
- dotnet sonarscanner begin /k:ConsEco /d:sonar.host.url=$${PLUGIN_SONAR_HOST} /d:sonar.coverageReportPaths="coveragereport/SonarQube.xml" /d:sonar.coverage.exclusions="Tests/**" /d:sonar.login=$${PLUGIN_SONAR_TOKEN}
- dotnet build CI_CONSECO.sln -c Release --no-restore
- dotnet test CI_CONSECO.sln --logger trx --no-restore /p:CollectCoverage=true /p:CoverletOutputFormat=cobertura --collect "XPlat Code Coverage"
- reportgenerator -reports:"**/coverage.cobertura.xml" -reporttypes:SonarQube -targetdir:"coveragereport"
- dotnet publish CI_CONSECO.sln -c Release --no-restore -o CI_PROJECT_DIR/build/release
- dotnet sonarscanner end /d:sonar.login=$${PLUGIN_SONAR_TOKEN}
secrets: [ SECRET_SONAR_LOGIN ]
settings:
# accessible en ligne de commande par ${PLUGIN_SONAR_HOST}
sonar_host: https://codefirst.iut.uca.fr/sonar/
# accessible en ligne de commande par ${PLUGIN_SONAR_TOKEN}
sonar_token:
from_secret: SECRET_SONAR_LOGIN
depends_on: [tests]

Binary file not shown.

After

Width:  |  Height:  |  Size: 446 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 132 KiB

File diff suppressed because it is too large Load Diff

@ -0,0 +1,24 @@
while [ 0 -eq 0 ]; do
insert(){
dev1="'$1'"
dev2="'$2'"
date=`date +"%d/%m/%Y:%H:%M:%S"`
date2="'$date'"
rep=`curl -s https://www.freeforexapi.com/api/live?pairs=$1$2 | grep rate | cut -d : -f 4 | cut -d , -f 1`
echo 'DELETE from conversion WHERE device1='$dev1' AND device2='$dev2';INSERT INTO conversion VALUES ('$dev1', '$rep', '$dev2','$date2');' | PGPASSWORD=lulu psql -d piege -U lulu &> /dev/null
rep=`curl -s https://www.freeforexapi.com/api/live?pairs=$2$1 | grep rate | cut -d : -f 4 | cut -d , -f 1`
echo 'DELETE from conversion WHERE device1='$dev2' AND device2='$dev1';INSERT INTO conversion VALUES ('$dev2', '$rep', '$dev1','$date2');' | PGPASSWORD=amodif psql -d amodif -U amodif &> /dev/null
}
insert EUR USD
insert EUR GBP
insert GBP USD
insert USD JPY
insert AUD USD
insert USD CHF
insert NZD USD
insert EUR CAD
insert ZAR USD
sleep 10
done

@ -0,0 +1,105 @@
DROP TABLE Planification;
DROP TABLE Opération;
DROP TABLE Echeancier;
DROP TABLE Compte;
DROP TABLE InscrBanque;
DROP TABLE Banque;
DROP TABLE DeviseInscrit;
DROP TABLE Inscrit;
DROP TABLE Devise;
CREATE TABLE Devise
(
id char(3) PRIMARY KEY,
nom varchar(20)
);
CREATE TABLE Inscrit
(
id char(5) PRIMARY KEY,
nom varchar(40),
prenom varchar(40),
mail varchar(40),
mdp varchar(40)
);
CREATE TABLE DeviseInscrit
(
devise char(3),
idInscrit char(5) UNIQUE,
PRIMARY KEY(devise,idInscrit),
FOREIGN KEY (devise) REFERENCES Devise(id),
FOREIGN KEY (idInscrit) REFERENCES Inscrit(id)
);
CREATE TABLE Banque
(
nom varchar(40) PRIMARY KEY,
urlsite varchar(60),
urllogo varchar(60)
);
CREATE TABLE InscrBanque
(
id char(5) PRIMARY KEY,
nomBanque varchar(40),
idInscrit char(5) UNIQUE,
UNIQUE(nomBanque,idInscrit),
FOREIGN KEY (nomBanque) REFERENCES Banque(nom),
FOREIGN KEY (idInscrit) REFERENCES Inscrit(id)
);
CREATE TABLE Compte
(
id char (5) PRIMARY KEY,
nom varchar(40),
idInscritBanque char(5),
FOREIGN KEY (idInscritBanque) REFERENCES InscrBanque(id),
UNIQUE(idInscritBanque,nom)
);
CREATE TABLE Echeancier
(
id char(5) PRIMARY KEY,
nom varchar(40),
credit numeric,
compte char(5),
debit numeric,
dateE date,
datecrea date,
methodePayement varchar(20),
CONSTRAINT ck_methPaye CHECK (methodePayement IN ('CB','Cheque','Espece','Prélevement')),
FOREIGN KEY(compte) REFERENCES Compte(id),
UNIQUE (datecrea,compte)
);
CREATE TABLE Opération
(
id char(5) PRIMARY KEY,
nom varchar(40),
credit numeric,
compte char(5),
debit numeric,
dateO date,
datecrea date,
methodePayement varchar(20),
CONSTRAINT ck_methPaye CHECK (methodePayement IN ('CB','Cheque','Espece','Prélevement')),
FOREIGN KEY(compte) REFERENCES Compte(id),
UNIQUE (datecrea,compte)
);
CREATE TABLE Planification
(
id char(5) PRIMARY KEY,
nom varchar(40),
credit numeric,
compte char(5),
debit numeric,
dateP date,
datecrea date,
methodePayement varchar(20),
CONSTRAINT ck_methPaye CHECK (methodePayement IN ('CB','Cheque','Espece','Prélevement')),
FOREIGN KEY(compte) REFERENCES Compte(id),
UNIQUE (datecrea,compte)
);
Loading…
Cancel
Save