%
This commit is contained in:
parent
af4b827eba
commit
f900c6179d
13
FIProjetIHM2022.iml
Normal file
13
FIProjetIHM2022.iml
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<module type="JAVA_MODULE" version="4">
|
||||||
|
<component name="NewModuleRootManager" inherit-compiler-output="true">
|
||||||
|
<exclude-output />
|
||||||
|
<content url="file://$MODULE_DIR$">
|
||||||
|
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
|
||||||
|
</content>
|
||||||
|
<orderEntry type="inheritedJdk" />
|
||||||
|
<orderEntry type="sourceFolder" forTests="false" />
|
||||||
|
<orderEntry type="library" name="mariadb-connector" level="project" />
|
||||||
|
<orderEntry type="library" name="mariadb-connector1" level="project" />
|
||||||
|
</component>
|
||||||
|
</module>
|
BIN
out/production/FIProjetIHM2022/BButton.class
Normal file
BIN
out/production/FIProjetIHM2022/BButton.class
Normal file
Binary file not shown.
BIN
out/production/FIProjetIHM2022/BDatabase.class
Normal file
BIN
out/production/FIProjetIHM2022/BDatabase.class
Normal file
Binary file not shown.
BIN
out/production/FIProjetIHM2022/BFrame.class
Normal file
BIN
out/production/FIProjetIHM2022/BFrame.class
Normal file
Binary file not shown.
BIN
out/production/FIProjetIHM2022/BImage.class
Normal file
BIN
out/production/FIProjetIHM2022/BImage.class
Normal file
Binary file not shown.
BIN
out/production/FIProjetIHM2022/BInput.class
Normal file
BIN
out/production/FIProjetIHM2022/BInput.class
Normal file
Binary file not shown.
BIN
out/production/FIProjetIHM2022/BLabel.class
Normal file
BIN
out/production/FIProjetIHM2022/BLabel.class
Normal file
Binary file not shown.
BIN
out/production/FIProjetIHM2022/BLayout.class
Normal file
BIN
out/production/FIProjetIHM2022/BLayout.class
Normal file
Binary file not shown.
BIN
out/production/FIProjetIHM2022/Home.class
Normal file
BIN
out/production/FIProjetIHM2022/Home.class
Normal file
Binary file not shown.
BIN
out/production/FIProjetIHM2022/LoginConnection.class
Normal file
BIN
out/production/FIProjetIHM2022/LoginConnection.class
Normal file
Binary file not shown.
BIN
out/production/FIProjetIHM2022/Main.class
Normal file
BIN
out/production/FIProjetIHM2022/Main.class
Normal file
Binary file not shown.
BIN
out/production/FIProjetIHM2022/ManageStudent.class
Normal file
BIN
out/production/FIProjetIHM2022/ManageStudent.class
Normal file
Binary file not shown.
BIN
out/production/FIProjetIHM2022/assets/img/logo.ico
Normal file
BIN
out/production/FIProjetIHM2022/assets/img/logo.ico
Normal file
Binary file not shown.
After Width: | Height: | Size: 66 KiB |
BIN
out/production/FIProjetIHM2022/assets/img/logo.png
Normal file
BIN
out/production/FIProjetIHM2022/assets/img/logo.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 8.3 KiB |
216
out/production/FIProjetIHM2022/assets/info/bdd/gruppapp.sql
Normal file
216
out/production/FIProjetIHM2022/assets/info/bdd/gruppapp.sql
Normal file
@ -0,0 +1,216 @@
|
|||||||
|
-- phpMyAdmin SQL Dump
|
||||||
|
-- version 5.2.0
|
||||||
|
-- https://www.phpmyadmin.net/
|
||||||
|
--
|
||||||
|
-- Hôte : localhost
|
||||||
|
-- Généré le : mar. 04 oct. 2022 à 15:55
|
||||||
|
-- Version du serveur : 10.8.3-MariaDB
|
||||||
|
-- Version de PHP : 8.1.7
|
||||||
|
|
||||||
|
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
|
||||||
|
START TRANSACTION;
|
||||||
|
SET time_zone = "+00:00";
|
||||||
|
|
||||||
|
|
||||||
|
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
|
||||||
|
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
|
||||||
|
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
|
||||||
|
/*!40101 SET NAMES utf8mb4 */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Base de données : `boudjeml`
|
||||||
|
--
|
||||||
|
|
||||||
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Structure de la table `Comptes`
|
||||||
|
--
|
||||||
|
|
||||||
|
CREATE TABLE `Comptes` (
|
||||||
|
`idCompte` int(11) NOT NULL,
|
||||||
|
`idGrade` int(11) NOT NULL,
|
||||||
|
`utilisateur` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||||
|
`pass` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Déchargement des données de la table `Comptes`
|
||||||
|
--
|
||||||
|
|
||||||
|
INSERT INTO `Comptes` (`idCompte`, `idGrade`, `utilisateur`, `pass`) VALUES
|
||||||
|
(0, 0, 'admin', 'admin'),
|
||||||
|
(1, 1, 'prof', 'prof'),
|
||||||
|
(2, 2, 'eleve', 'eleve');
|
||||||
|
|
||||||
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Structure de la table `Demandes`
|
||||||
|
--
|
||||||
|
|
||||||
|
CREATE TABLE `Demandes` (
|
||||||
|
`idRequete` int(11) NOT NULL,
|
||||||
|
`idCompte` int(11) NOT NULL,
|
||||||
|
`type` int(11) NOT NULL,
|
||||||
|
`contenu` text COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||||
|
`quand` date NOT NULL,
|
||||||
|
`heure` time NOT NULL
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||||
|
|
||||||
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Structure de la table `Grades`
|
||||||
|
--
|
||||||
|
|
||||||
|
CREATE TABLE `Grades` (
|
||||||
|
`idGrade` int(11) NOT NULL,
|
||||||
|
`intitule` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Déchargement des données de la table `Grades`
|
||||||
|
--
|
||||||
|
|
||||||
|
INSERT INTO `Grades` (`idGrade`, `intitule`) VALUES
|
||||||
|
(0, 'Administrateur'),
|
||||||
|
(1, 'Professeur'),
|
||||||
|
(2, 'Eleve');
|
||||||
|
|
||||||
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Structure de la table `Groupes`
|
||||||
|
--
|
||||||
|
|
||||||
|
CREATE TABLE `Groupes` (
|
||||||
|
`idGroupe` int(11) NOT NULL,
|
||||||
|
`intitule` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Déchargement des données de la table `Groupes`
|
||||||
|
--
|
||||||
|
|
||||||
|
INSERT INTO `Groupes` (`idGroupe`, `intitule`) VALUES
|
||||||
|
(0, 'Groupe de TP 1'),
|
||||||
|
(1, 'Groupe de TP 2'),
|
||||||
|
(2, 'Groupe de TP 3');
|
||||||
|
|
||||||
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Structure de la table `Membres`
|
||||||
|
--
|
||||||
|
|
||||||
|
CREATE TABLE `Membres` (
|
||||||
|
`idCompte` int(11) NOT NULL,
|
||||||
|
`idGroupe` int(11) DEFAULT NULL,
|
||||||
|
`nom` text COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||||
|
`prenom` text COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||||
|
`adresse` text COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||||
|
`numero` text COLLATE utf8mb4_unicode_ci DEFAULT NULL
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Déchargement des données de la table `Membres`
|
||||||
|
--
|
||||||
|
|
||||||
|
INSERT INTO `Membres` (`idCompte`, `idGroupe`, `nom`, `prenom`, `adresse`, `numero`) VALUES
|
||||||
|
(0, NULL, 'Upec', 'Fontainebleau', 'Route forestière Hurtault 77300 Fontainebleau', '01.45.17.10.00'),
|
||||||
|
(1, NULL, 'Florent', 'Madelaine', NULL, '01.45.17.65.94'),
|
||||||
|
(2, 0, 'Bilal', 'Boudjemline', '14 rue Charles Meunier Avon', '06.60.30.19.27');
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Index pour les tables déchargées
|
||||||
|
--
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Index pour la table `Comptes`
|
||||||
|
--
|
||||||
|
ALTER TABLE `Comptes`
|
||||||
|
ADD PRIMARY KEY (`idCompte`),
|
||||||
|
ADD KEY `idGrade` (`idGrade`);
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Index pour la table `Demandes`
|
||||||
|
--
|
||||||
|
ALTER TABLE `Demandes`
|
||||||
|
ADD PRIMARY KEY (`idRequete`),
|
||||||
|
ADD KEY `idCompte` (`idCompte`);
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Index pour la table `Grades`
|
||||||
|
--
|
||||||
|
ALTER TABLE `Grades`
|
||||||
|
ADD PRIMARY KEY (`idGrade`);
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Index pour la table `Groupes`
|
||||||
|
--
|
||||||
|
ALTER TABLE `Groupes`
|
||||||
|
ADD PRIMARY KEY (`idGroupe`);
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Index pour la table `Membres`
|
||||||
|
--
|
||||||
|
ALTER TABLE `Membres`
|
||||||
|
ADD PRIMARY KEY (`idCompte`),
|
||||||
|
ADD KEY `idGroupe` (`idGroupe`);
|
||||||
|
|
||||||
|
--
|
||||||
|
-- AUTO_INCREMENT pour les tables déchargées
|
||||||
|
--
|
||||||
|
|
||||||
|
--
|
||||||
|
-- AUTO_INCREMENT pour la table `Comptes`
|
||||||
|
--
|
||||||
|
ALTER TABLE `Comptes`
|
||||||
|
MODIFY `idCompte` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- AUTO_INCREMENT pour la table `Demandes`
|
||||||
|
--
|
||||||
|
ALTER TABLE `Demandes`
|
||||||
|
MODIFY `idRequete` int(11) NOT NULL AUTO_INCREMENT;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- AUTO_INCREMENT pour la table `Grades`
|
||||||
|
--
|
||||||
|
ALTER TABLE `Grades`
|
||||||
|
MODIFY `idGrade` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- AUTO_INCREMENT pour la table `Groupes`
|
||||||
|
--
|
||||||
|
ALTER TABLE `Groupes`
|
||||||
|
MODIFY `idGroupe` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Contraintes pour les tables déchargées
|
||||||
|
--
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Contraintes pour la table `Comptes`
|
||||||
|
--
|
||||||
|
ALTER TABLE `Comptes`
|
||||||
|
ADD CONSTRAINT `Comptes_ibfk_1` FOREIGN KEY (`idGrade`) REFERENCES `Grades` (`idGrade`);
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Contraintes pour la table `Demandes`
|
||||||
|
--
|
||||||
|
ALTER TABLE `Demandes`
|
||||||
|
ADD CONSTRAINT `Demandes_ibfk_1` FOREIGN KEY (`idCompte`) REFERENCES `Comptes` (`idCompte`);
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Contraintes pour la table `Membres`
|
||||||
|
--
|
||||||
|
ALTER TABLE `Membres`
|
||||||
|
ADD CONSTRAINT `Membres_ibfk_1` FOREIGN KEY (`idCompte`) REFERENCES `Comptes` (`idCompte`),
|
||||||
|
ADD CONSTRAINT `Membres_ibfk_2` FOREIGN KEY (`idGroupe`) REFERENCES `Groupes` (`idGroupe`);
|
||||||
|
COMMIT;
|
||||||
|
|
||||||
|
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
||||||
|
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
|
||||||
|
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
|
3261
out/production/FIProjetIHM2022/assets/info/model.mdj
Normal file
3261
out/production/FIProjetIHM2022/assets/info/model.mdj
Normal file
File diff suppressed because it is too large
Load Diff
BIN
out/production/FIProjetIHM2022/libs/mariadb-connector.jar
Normal file
BIN
out/production/FIProjetIHM2022/libs/mariadb-connector.jar
Normal file
Binary file not shown.
@ -1,8 +1,10 @@
|
|||||||
import javax.swing.*;
|
import javax.swing.*;
|
||||||
|
import java.awt.event.ActionEvent;
|
||||||
|
import java.awt.event.ActionListener;
|
||||||
import java.lang.management.ManagementPermission;
|
import java.lang.management.ManagementPermission;
|
||||||
import java.sql.Connection;
|
import java.sql.Connection;
|
||||||
|
|
||||||
public class Home extends BFrame{
|
public class Home extends BFrame implements ActionListener {
|
||||||
protected BDatabase sharedObject;
|
protected BDatabase sharedObject;
|
||||||
protected BLayout settings = new BLayout();
|
protected BLayout settings = new BLayout();
|
||||||
protected int grade;
|
protected int grade;
|
||||||
@ -71,10 +73,12 @@ public class Home extends BFrame{
|
|||||||
this.settings.setPositionY(1);
|
this.settings.setPositionY(1);
|
||||||
this.add(blank[0], this.settings);
|
this.add(blank[0], this.settings);
|
||||||
|
|
||||||
BButton maganageMembers = new BButton("Gestion des Membres");
|
BButton manageMember = new BButton("Gestion des Membres");
|
||||||
|
manageMember.addActionListener(this);
|
||||||
|
manageMember.setActionCommand("membergest");
|
||||||
this.settings.setPositionX(1);
|
this.settings.setPositionX(1);
|
||||||
this.settings.setPositionY(2);
|
this.settings.setPositionY(2);
|
||||||
this.add(maganageMembers, this.settings);
|
this.add(manageMember, this.settings);
|
||||||
|
|
||||||
this.settings.setPositionX(1);
|
this.settings.setPositionX(1);
|
||||||
this.settings.setPositionY(3);
|
this.settings.setPositionY(3);
|
||||||
@ -85,8 +89,6 @@ public class Home extends BFrame{
|
|||||||
this.settings.setPositionY(4);
|
this.settings.setPositionY(4);
|
||||||
this.add(requestMembers, this.settings);
|
this.add(requestMembers, this.settings);
|
||||||
|
|
||||||
ManageStudent goToManage = new ManageStudent(this.sharedObject);
|
|
||||||
|
|
||||||
this.openBFrame();
|
this.openBFrame();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -97,4 +99,15 @@ public class Home extends BFrame{
|
|||||||
private void eleve() {
|
private void eleve() {
|
||||||
this.openBFrame();
|
this.openBFrame();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void actionPerformed(ActionEvent e) {
|
||||||
|
if(e.getActionCommand() == "membergest") {
|
||||||
|
ManageStudent goToManageStudent = new ManageStudent(this.sharedObject);
|
||||||
|
} else if(e.getActionCommand() == "grupgest") {
|
||||||
|
|
||||||
|
} else if(e.getActionCommand() == "gestrequest") {
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -93,16 +93,13 @@ public class ManageStudent extends BFrame implements ActionListener {
|
|||||||
System.out.println(this.data[i] + " | " + i);
|
System.out.println(this.data[i] + " | " + i);
|
||||||
}
|
}
|
||||||
|
|
||||||
JList<String> list = new JList<>(this.data);
|
return new JList<>(this.data);
|
||||||
this.refreshBFrame();
|
|
||||||
|
|
||||||
return list;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void actionPerformed(ActionEvent e) {
|
public void actionPerformed(ActionEvent e) {
|
||||||
if(e.getActionCommand() == "search") {
|
if(e.getActionCommand() == "search") {
|
||||||
refreshList(this.inSearch.getText());
|
this.add(refreshList(this.inSearch.getText()), this.settings);
|
||||||
} else {
|
} else {
|
||||||
System.out.println("ok");
|
System.out.println("ok");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user