Modifs divers +début du système de mail
This commit is contained in:
parent
c6289a1588
commit
69f06e9cde
15 changed files with 7450 additions and 61 deletions
BIN
Assets/Logos/nothing.jpg
Normal file
BIN
Assets/Logos/nothing.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 64 KiB |
BIN
Assets/Logos/octime.png
Normal file
BIN
Assets/Logos/octime.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 12 KiB |
|
|
@ -68,10 +68,12 @@ function getHashPwd($bdd, $username)
|
|||
|
||||
function getEvenements($bdd, $site)
|
||||
{
|
||||
|
||||
$results = mysqli_query(
|
||||
$bdd,
|
||||
"SELECT * FROM evenements WHERE `site_id`='" . $site . "' ORDER BY date DESC"
|
||||
"SELECT * FROM evenements
|
||||
WHERE site_id = '" . $site . "'
|
||||
OR public = 1
|
||||
ORDER BY date DESC"
|
||||
);
|
||||
|
||||
$evenements = [];
|
||||
|
|
@ -391,14 +393,50 @@ function getSpecificRaccourcis($bdd, $id)
|
|||
return $return;
|
||||
}
|
||||
|
||||
function getGuides($bdd) {
|
||||
function getGuides($bdd)
|
||||
{
|
||||
$results = mysqli_query($bdd, "SELECT * FROM `guides`");
|
||||
|
||||
|
||||
$return = [];
|
||||
|
||||
|
||||
while ($row = mysqli_fetch_assoc($results)) {
|
||||
$return[] = $row;
|
||||
}
|
||||
|
||||
|
||||
return $return;
|
||||
}
|
||||
}
|
||||
|
||||
function updateEventDate($bdd, $eventid, $date)
|
||||
{
|
||||
$stmt = mysqli_prepare(
|
||||
$bdd,
|
||||
"UPDATE evenements SET date = ? WHERE id = ?"
|
||||
);
|
||||
|
||||
mysqli_stmt_bind_param($stmt, "si", $date, $eventid);
|
||||
mysqli_stmt_execute($stmt);
|
||||
|
||||
$success = mysqli_stmt_affected_rows($stmt) >= 0;
|
||||
|
||||
mysqli_stmt_close($stmt);
|
||||
|
||||
return $success;
|
||||
}
|
||||
|
||||
function getEventDate($bdd, $event)
|
||||
{
|
||||
$stmt = mysqli_prepare(
|
||||
$bdd,
|
||||
"SELECT date FROM evenements WHERE id = ? LIMIT 1"
|
||||
);
|
||||
|
||||
mysqli_stmt_bind_param($stmt, "s", $event);
|
||||
mysqli_stmt_execute($stmt);
|
||||
|
||||
$result = mysqli_stmt_get_result($stmt);
|
||||
$row = mysqli_fetch_assoc($result);
|
||||
|
||||
mysqli_stmt_close($stmt);
|
||||
|
||||
return $row ? $row['date'] : null;
|
||||
}
|
||||
|
|
|
|||
67
Assets/sendMail.php
Normal file
67
Assets/sendMail.php
Normal file
|
|
@ -0,0 +1,67 @@
|
|||
<?php
|
||||
|
||||
require '../Mailer/PHPMailer.php';
|
||||
require '../Mailer/SMTP.php';
|
||||
require '../Mailer/Exception.php';
|
||||
|
||||
use PHPMailer\PHPMailer\PHPMailer;
|
||||
use PHPMailer\PHPMailer\Exception;
|
||||
|
||||
$objet = ["Demande de compte", "Activation de votre compte"];
|
||||
$message = ["
|
||||
<h1>Validation de création de compte</h1>
|
||||
<p>L'utilisateur {user} a demandé la création de son compte.</p>
|
||||
Le mail de validation sera envoyé à l'adresse : {mail}<br>
|
||||
Si vous voulez accepter, cliquez <a href='http://172.17.0.224/validate.php'>ici</a><br>
|
||||
<p>Sinon, vous pouvez simplement ignorer ce message</p><br>
|
||||
<p>Des bisous</p>
|
||||
","
|
||||
<h1>Activation de votre compte</h1>
|
||||
<p>Cliquez sur le lien ci-dessous afin de créer votre mot de passe;<br>
|
||||
Ce lien expirera dans 7 jours<br>
|
||||
Merci de ne pas répondre à cet email.
|
||||
</p>
|
||||
{lien}
|
||||
"];
|
||||
if(isset($_GET['type'])){
|
||||
$type = $_GET['type'];
|
||||
}else{
|
||||
die("pas de type");
|
||||
}
|
||||
|
||||
if($type == 0){
|
||||
$user = $_GET['user'];
|
||||
$email = $_GET['email'];
|
||||
$message[0] = str_replace("{user}", $user, $message[0]);
|
||||
$message[0] = str_replace('{mail}', $email, $message[0]);
|
||||
}
|
||||
|
||||
$mail = new PHPMailer(true);
|
||||
|
||||
try {
|
||||
|
||||
$mail->isSMTP();
|
||||
$mail->Host = 'smtp.office365.com';
|
||||
$mail->SMTPAuth = true;
|
||||
$mail->Username = 'intranet-apei@apeimbge.fr';
|
||||
$mail->Password = 'Asdb0789!';
|
||||
$mail->SMTPSecure = 'tls';
|
||||
$mail->Port = 587;
|
||||
$mail->CharSet = 'UTF-8';
|
||||
|
||||
$mail->isHTML(true);
|
||||
|
||||
$mail->setFrom('intranet-apei@apeimbge.fr', 'Demande de connexion');
|
||||
//$mail->addAddress('blemaire@apeimbge.fr');
|
||||
$mail->addAddress('erwann.philippe2@gmail.com');
|
||||
|
||||
$mail->Subject = $objet[$type];
|
||||
$mail->Body = $message[$type];
|
||||
|
||||
$mail->send();
|
||||
|
||||
header('location: ../index.php');
|
||||
|
||||
} catch (Exception $e) {
|
||||
echo "Erreur lors de l'envoi : {$mail->ErrorInfo}";
|
||||
}
|
||||
40
Mailer/Exception.php
Normal file
40
Mailer/Exception.php
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* PHPMailer Exception class.
|
||||
* PHP Version 5.5.
|
||||
*
|
||||
* @see https://github.com/PHPMailer/PHPMailer/ The PHPMailer GitHub project
|
||||
*
|
||||
* @author Marcus Bointon (Synchro/coolbru) <phpmailer@synchromedia.co.uk>
|
||||
* @author Jim Jagielski (jimjag) <jimjag@gmail.com>
|
||||
* @author Andy Prevost (codeworxtech) <codeworxtech@users.sourceforge.net>
|
||||
* @author Brent R. Matzelle (original founder)
|
||||
* @copyright 2012 - 2020 Marcus Bointon
|
||||
* @copyright 2010 - 2012 Jim Jagielski
|
||||
* @copyright 2004 - 2009 Andy Prevost
|
||||
* @license https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html GNU Lesser General Public License
|
||||
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE.
|
||||
*/
|
||||
|
||||
namespace PHPMailer\PHPMailer;
|
||||
|
||||
/**
|
||||
* PHPMailer exception handler.
|
||||
*
|
||||
* @author Marcus Bointon <phpmailer@synchromedia.co.uk>
|
||||
*/
|
||||
class Exception extends \Exception
|
||||
{
|
||||
/**
|
||||
* Prettify error message output.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function errorMessage()
|
||||
{
|
||||
return '<strong>' . htmlspecialchars($this->getMessage(), ENT_COMPAT | ENT_HTML401) . "</strong><br />\n";
|
||||
}
|
||||
}
|
||||
5525
Mailer/PHPMailer.php
Normal file
5525
Mailer/PHPMailer.php
Normal file
File diff suppressed because it is too large
Load diff
1617
Mailer/SMTP.php
Normal file
1617
Mailer/SMTP.php
Normal file
File diff suppressed because it is too large
Load diff
24
activate.php
Normal file
24
activate.php
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
<?php
|
||||
if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
||||
header('location: ./Assets/sendMail.php?type=0&user='.$_POST['user'] .'&email='. htmlspecialchars($_POST['mail']));
|
||||
}
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="fr">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Activer mon compte</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Activer mon compte sur l'intranet</h1>
|
||||
<form action="" method="post">
|
||||
<label for="user">Veuillez le nom d'utilisateur de votre pc (APEIXXXX)</label>
|
||||
<input type="text" name="user" id="user" placeholder="APEIXXXX" required><br>
|
||||
<label for="mail">Veuillez entrer votre adresse mail (pcharlot@apeimbge.fr)</label>
|
||||
<input type="text" name="mail" id="mail" placeholder="pcharlot@apeimbge.fr" required><br>
|
||||
<button type="submit">Demander l'activation</button>
|
||||
</form>
|
||||
<h3>Veuillez ne pas faire la demande plusieurs fois.</h3>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -105,7 +105,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
|||
<div class="collapse navbar-collapse" id="navbarSupportedContent">
|
||||
<ul class="navbar-nav mr-auto">
|
||||
<li class="nav-item">
|
||||
<a href="#" class="nav-link">Évènements</a>
|
||||
<a href="index.php" class="nav-link">Évènements</a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a href="modifyActuality.php" class="nav-link">Actualités</a>
|
||||
|
|
|
|||
|
|
@ -25,6 +25,9 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST' && empty($_POST['new'])) {
|
|||
if (!empty($_POST['title'])) {
|
||||
updateEventTitle($bdd, $eventId, trim($_POST['title']));
|
||||
}
|
||||
if(!empty($_POST['date'])) {
|
||||
updateEventDate($bdd, $eventId, $_POST['date']);
|
||||
}
|
||||
|
||||
if (!empty($_FILES['couverture']['name'])) {
|
||||
$uploadDir = "../Photos/INTRANET/";
|
||||
|
|
@ -92,25 +95,7 @@ if (!empty($_POST['new'])) {
|
|||
<meta charset="UTF-8">
|
||||
<title>Gestion Intranet</title>
|
||||
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css" rel="stylesheet">
|
||||
|
||||
<style>
|
||||
.preview-box {
|
||||
height: 220px;
|
||||
border: 2px dashed #ddd;
|
||||
border-radius: 8px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
overflow: hidden;
|
||||
background: #fafafa;
|
||||
}
|
||||
|
||||
.preview-box img {
|
||||
max-height: 100%;
|
||||
max-width: 100%;
|
||||
}
|
||||
</style>
|
||||
|
||||
<link rel="stylesheet" href="../styles-scripts/admin.modifyEvent.css">
|
||||
</head>
|
||||
|
||||
<body class="container py-4">
|
||||
|
|
@ -186,15 +171,17 @@ if (!empty($_POST['new'])) {
|
|||
</div>
|
||||
<div class="mb-3">
|
||||
<label class="form-label">Date de l'évènement</label>
|
||||
<input type="date" name="date" class="form-control" value="<?= date('Y-m-d') ?>" required>
|
||||
<input type="date" name="date" id="date" class="form-control" value="<?= getEventDate($bdd, $eventId) ?>" required>
|
||||
</div>
|
||||
<?php if (empty($_GET['id'])): ?>
|
||||
<input type="text" name="new" id="new" value="new" style="display: none;">
|
||||
<?php endif ?>
|
||||
|
||||
<button type="button" class="btn btn-danger" onclick="window.location.href='delete.php?type=event&id=<?= $_GET['id'] ?>'">
|
||||
<?php if(!empty($_GET['id'])): ?>
|
||||
<button type="button" class="btn btn-danger" onclick="window.location.href='delete.php?type=event&id=<?= $_GET['id'] ?>'">
|
||||
Supprimer
|
||||
</button>
|
||||
<?php endif;?>
|
||||
|
||||
<button type="submit" class="btn btn-primary">
|
||||
Enregistrer les modifications
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ $prefixe = $config["LOCAL_IMG_PREFIXE"]."gallerie/";
|
|||
<html lang="fr">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Mon Diaporama Auto</title>
|
||||
<title>Diaporama</title>
|
||||
<link rel="stylesheet" href="./styles-scripts/diapo.css">
|
||||
</head>
|
||||
<body>
|
||||
|
|
|
|||
134
intranet v1.sql
134
intranet v1.sql
|
|
@ -23,14 +23,16 @@ CREATE TABLE IF NOT EXISTS `actus` (
|
|||
`date` date NOT NULL,
|
||||
`idSite` tinyint NOT NULL,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb3;
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=9 DEFAULT CHARSET=utf8mb3;
|
||||
|
||||
-- Listage des données de la table intranet.actus : ~4 rows (environ)
|
||||
-- Listage des données de la table intranet.actus : ~6 rows (environ)
|
||||
INSERT INTO `actus` (`id`, `titre`, `actu`, `image`, `date`, `idSite`) VALUES
|
||||
(1, 'Actualité 1', 'vrbvjerbvkrebamjvberamjnaerinvipezjbiperjabiprejaibojrbiojerao^bjreîobjeriôajboerijbioajrebjreoibjaeribjeroiajboerjb', 'https://i.ytimg.com/vi/wPPgjdh9trw/hq720.jpg?sqp=-oaymwEhCK4FEIIDSFryq4qpAxMIARUAAAAAGAElAADIQj0AgKJD&rs=AOn4CLBKWQvC3UMgJapHoPeEOBfOgVBrgQ', '2026-02-10', 0),
|
||||
(2, 'Actualité 2', 'rveuherubiueriuberuihbeiuhubihraiuehbuihearphberiuahbuiearhbiuherauihbuireahiuhabieruphbiruehabuihberiuhahbuirhbeabaeveccece', 'https://media.istockphoto.com/id/1500645450/fr/photo/image-floue-de-mouvement-de-la-circulation-sur-lautoroute.jpg?s=612x612&w=0&k=20&c=8Rg-6jb0bn3mER7fHzj8XQ4fgO96-537MjpUtXAlkNI=', '2026-02-10', 0),
|
||||
(3, 'Vélow', 'On a un vélo', 'https://numerique.umontpellier.fr/wp-content/uploads/2024/07/Image-3-scaled.jpg', '2026-02-10', 0),
|
||||
(4, 'XP', 'g\'tohgio\'h', 'https://images.ctfassets.net/hrltx12pl8hq/28ECAQiPJZ78hxatLTa7Ts/2f695d869736ae3b0de3e56ceaca3958/free-nature-images.jpg?fit=fill&w=1200&h=630', '2026-02-10', 0);
|
||||
(1, 'Chill avec les potes', 'Ajourd\'hui on a chill avec les potes à la maison, moi et les boys forever.', 'actu_1_1772639173.JPG', '2026-02-10', 1),
|
||||
(2, '#Onfoutlefeu (Manifestation)', 'rveuherubiueriuberuihbeiuhubihraiuehbuihearphberiuahbuiearhbiuherauihbuireahiuhabieruphbiruehabuihberiuhahbuirhbeabaeveccece', 'actu_2_1772639391.jpg', '2026-02-10', 1),
|
||||
(3, 'Nouveau pc de g@m3r', 'On a un vélo', 'actu_3_1772638885.JPG', '2026-02-10', 1),
|
||||
(4, 'Futur repas :miam:', 'g\'tohgio\'h', 'actu_4_1772639824.jpg', '2026-02-10', 1),
|
||||
(7, 'uytre', 'gdnngd', 'actu_7_1773042067.gif', '2026-03-09', 1),
|
||||
(8, 'TIC et TAC', 'TIC et TAC arrivent à APEI de Maubeuge', 'actu_8_1773146906.jpg', '2026-03-10', 2);
|
||||
|
||||
-- Listage de la structure de table intranet. evenements
|
||||
CREATE TABLE IF NOT EXISTS `evenements` (
|
||||
|
|
@ -39,22 +41,24 @@ CREATE TABLE IF NOT EXISTS `evenements` (
|
|||
`titre` tinytext CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL,
|
||||
`couverture` text CHARACTER SET utf8mb3 COLLATE utf8mb3_general_ci NOT NULL,
|
||||
`site_id` tinyint DEFAULT NULL,
|
||||
`public` tinyint(1) NOT NULL DEFAULT '0',
|
||||
PRIMARY KEY (`id`) USING BTREE,
|
||||
KEY `FK_evenements_site` (`site_id`),
|
||||
CONSTRAINT `FK_evenements_site` FOREIGN KEY (`site_id`) REFERENCES `site` (`site_id`) ON DELETE CASCADE ON UPDATE CASCADE
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8mb3;
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=18 DEFAULT CHARSET=utf8mb3;
|
||||
|
||||
-- Listage des données de la table intranet.evenements : ~9 rows (environ)
|
||||
INSERT INTO `evenements` (`id`, `date`, `titre`, `couverture`, `site_id`) VALUES
|
||||
(1, '2026-02-24', '50 ans des papillons blancs', 'event_1_1772616599.JPG', 1),
|
||||
(2, '2026-02-24', 'Accueil des nouveaux salariés', 'event_2_1772616804.JPG', 1),
|
||||
(3, '2026-02-24', 'AG 2014 La longueville', 'event_3_1772619824.JPG', 1),
|
||||
(4, '2026-02-24', 'Fête associative 2018', 'event_4_1772620173.jpg', 1),
|
||||
(5, '2026-02-24', 'ptkhpkth', 'https://upload.wikimedia.org/wikipedia/commons/b/b6/Image_created_with_a_mobile_phone.png', 1),
|
||||
(6, '2026-02-24', 'miaou', 'https://static.vecteezy.com/ti/photos-gratuite/t2/36324708-ai-genere-image-de-une-tigre-en-marchant-dans-le-foret-photo.jpg', 2),
|
||||
(7, '2026-02-24', 'wow', 'https://static.nationalgeographic.fr/files/styles/image_3200/public/01-solar-system-pia12114_orig.webp?w=1190&h=896', 2),
|
||||
(8, '2026-02-24', 'ptkhpkth', 'https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcSbspCVkfI_IJYPEpTu8Qbb9s-FE5sMbdNDbQ&s', 2),
|
||||
(9, '2026-02-24', 'ptkhpkth', 'https://cdn.pixabay.com/photo/2024/05/26/10/15/bird-8788491_1280.jpg', 2);
|
||||
-- Listage des données de la table intranet.evenements : ~10 rows (environ)
|
||||
INSERT INTO `evenements` (`id`, `date`, `titre`, `couverture`, `site_id`, `public`) VALUES
|
||||
(1, '2026-02-28', '50 ans des papillons blancs', 'event_1_1772616599.JPG', 2, 1),
|
||||
(3, '2026-02-24', 'Assemblée générale 2014 La longueville', 'event_3_1772619824.JPG', 2, 0),
|
||||
(4, '2026-02-24', 'Fête associative 2018', 'event_4_1772620173.jpg', 2, 1),
|
||||
(6, '2026-02-24', 'miaou', 'https://static.vecteezy.com/ti/photos-gratuite/t2/36324708-ai-genere-image-de-une-tigre-en-marchant-dans-le-foret-photo.jpg', 3, 0),
|
||||
(7, '2026-02-24', 'wow', 'https://static.nationalgeographic.fr/files/styles/image_3200/public/01-solar-system-pia12114_orig.webp?w=1190&h=896', 3, 0),
|
||||
(8, '2026-02-24', 'ptkhpkth', 'https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcSbspCVkfI_IJYPEpTu8Qbb9s-FE5sMbdNDbQ&s', 3, 0),
|
||||
(9, '2026-02-24', 'ptkhpkth', 'https://cdn.pixabay.com/photo/2024/05/26/10/15/bird-8788491_1280.jpg', 3, 0),
|
||||
(10, '2026-02-24', '40 ans IME Jeumont', 'event_10_1772786010.JPG', 2, 0),
|
||||
(16, '2015-03-10', 'bla bla bla bla bla', 'event_16_1772793122.jfif', 2, 0),
|
||||
(17, '2017-10-10', 'JADE 2017', 'event_17_1773139543.jpg', 2, 0);
|
||||
|
||||
-- Listage de la structure de table intranet. gallerie
|
||||
CREATE TABLE IF NOT EXISTS `gallerie` (
|
||||
|
|
@ -65,7 +69,7 @@ CREATE TABLE IF NOT EXISTS `gallerie` (
|
|||
CONSTRAINT `FK_gallerie_evenements` FOREIGN KEY (`event_id`) REFERENCES `evenements` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3;
|
||||
|
||||
-- Listage des données de la table intranet.gallerie : ~41 rows (environ)
|
||||
-- Listage des données de la table intranet.gallerie : ~90 rows (environ)
|
||||
INSERT INTO `gallerie` (`event_id`, `chemin`, `texte`) VALUES
|
||||
(4, 'gallery_4_1772628170_0.JPG', ''),
|
||||
(4, 'gallery_4_1772628170_1.JPG', ''),
|
||||
|
|
@ -108,7 +112,67 @@ INSERT INTO `gallerie` (`event_id`, `chemin`, `texte`) VALUES
|
|||
(1, 'gallery_1_1772629484_18.JPG', ''),
|
||||
(1, 'gallery_1_1772629484_19.JPG', ''),
|
||||
(1, 'gallery_1_1772629707_0.JPG', ''),
|
||||
(3, 'gallery_3_1772632151_0.JPG', '');
|
||||
(3, 'gallery_3_1772632151_0.JPG', ''),
|
||||
(3, 'gallery_3_1772633113_0.JPG', ''),
|
||||
(3, 'gallery_3_1772633113_1.JPG', ''),
|
||||
(3, 'gallery_3_1772633113_2.JPG', ''),
|
||||
(3, 'gallery_3_1772633113_3.JPG', ''),
|
||||
(3, 'gallery_3_1772633113_4.JPG', ''),
|
||||
(3, 'gallery_3_1772633113_5.JPG', ''),
|
||||
(3, 'gallery_3_1772633114_6.JPG', ''),
|
||||
(3, 'gallery_3_1772633114_7.JPG', ''),
|
||||
(3, 'gallery_3_1772633114_8.JPG', ''),
|
||||
(3, 'gallery_3_1772633114_9.JPG', ''),
|
||||
(3, 'gallery_3_1772633468_0.JPG', ''),
|
||||
(3, 'gallery_3_1772633469_1.JPG', ''),
|
||||
(3, 'gallery_3_1772633469_2.JPG', ''),
|
||||
(3, 'gallery_3_1772633469_3.JPG', ''),
|
||||
(3, 'gallery_3_1772633469_4.JPG', ''),
|
||||
(3, 'gallery_3_1772633469_5.JPG', ''),
|
||||
(3, 'gallery_3_1772633469_6.JPG', ''),
|
||||
(3, 'gallery_3_1772633469_7.JPG', ''),
|
||||
(3, 'gallery_3_1772633469_8.JPG', ''),
|
||||
(10, 'gallery_10_1772786068_0.JPG', ''),
|
||||
(10, 'gallery_10_1772786068_1.JPG', ''),
|
||||
(10, 'gallery_10_1772786069_2.JPG', ''),
|
||||
(10, 'gallery_10_1772786069_3.JPG', ''),
|
||||
(10, 'gallery_10_1772786069_4.JPG', ''),
|
||||
(10, 'gallery_10_1772786069_5.JPG', ''),
|
||||
(10, 'gallery_10_1772786069_6.JPG', ''),
|
||||
(10, 'gallery_10_1772786069_7.JPG', ''),
|
||||
(10, 'gallery_10_1772786069_8.JPG', ''),
|
||||
(10, 'gallery_10_1772786069_9.JPG', ''),
|
||||
(10, 'gallery_10_1772786069_10.JPG', ''),
|
||||
(16, 'gallery_16_1772793327_0.jfif', ''),
|
||||
(16, 'gallery_16_1772793327_1.jfif', ''),
|
||||
(16, 'gallery_16_1772793327_2.jfif', ''),
|
||||
(16, 'gallery_16_1772793327_3.jfif', ''),
|
||||
(16, 'gallery_16_1772802166_0.gif', ''),
|
||||
(17, 'gallery_17_1773139597_0.jpg', ''),
|
||||
(17, 'gallery_17_1773139597_1.jpg', ''),
|
||||
(17, 'gallery_17_1773139597_2.jpg', ''),
|
||||
(17, 'gallery_17_1773139597_3.jpg', ''),
|
||||
(17, 'gallery_17_1773139597_4.jpg', ''),
|
||||
(17, 'gallery_17_1773139597_5.jpg', ''),
|
||||
(17, 'gallery_17_1773139597_6.jpg', ''),
|
||||
(17, 'gallery_17_1773139597_7.jpg', ''),
|
||||
(17, 'gallery_17_1773139597_8.jpg', ''),
|
||||
(17, 'gallery_17_1773139597_9.jpg', ''),
|
||||
(17, 'gallery_17_1773139597_10.jpg', ''),
|
||||
(17, 'gallery_17_1773139598_11.jpg', ''),
|
||||
(17, 'gallery_17_1773139598_12.jpg', '');
|
||||
|
||||
-- Listage de la structure de table intranet. guides
|
||||
CREATE TABLE IF NOT EXISTS `guides` (
|
||||
`id` int NOT NULL AUTO_INCREMENT,
|
||||
`nom` tinytext NOT NULL,
|
||||
`lien` text NOT NULL,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb3;
|
||||
|
||||
-- Listage des données de la table intranet.guides : ~1 rows (environ)
|
||||
INSERT INTO `guides` (`id`, `nom`, `lien`) VALUES
|
||||
(1, 'Test Guide 1', 'https://google.fr');
|
||||
|
||||
-- Listage de la structure de table intranet. permissions
|
||||
CREATE TABLE IF NOT EXISTS `permissions` (
|
||||
|
|
@ -133,9 +197,9 @@ CREATE TABLE IF NOT EXISTS `raccourcis` (
|
|||
`image` text NOT NULL,
|
||||
`url` text NOT NULL,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8mb3 COMMENT='Raccourcis de la page d''accueil';
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=13 DEFAULT CHARSET=utf8mb3 COMMENT='Raccourcis de la page d''accueil';
|
||||
|
||||
-- Listage des données de la table intranet.raccourcis : ~8 rows (environ)
|
||||
-- Listage des données de la table intranet.raccourcis : ~10 rows (environ)
|
||||
INSERT INTO `raccourcis` (`id`, `nom`, `image`, `url`) VALUES
|
||||
(1, 'Google', './Assets/Logos/google.png', 'https://google.com/'),
|
||||
(2, 'Orange', './Assets/Logos/orange.png', 'https://dro.orange-business.com/authentification?codeContexte=eceDefault&TYPE=33554433&REALMOID=06-0008fae7-1ec1-1184-b5ad-5e0e0a63d064&GUID=1&SMAUTHREASON=0&METHOD=GET&SMAGENTNAME=-SM-WSU81RKkuhqhTH%2b1DDCWyU0dUsCVOUEXZH%2fo6toyJ5TivCcULz4UBdXhakZa13z8&TARGET=-SM-HTTPS%3a%2f%2fespaceclient%2eorange--business%2ecom%2fgroup%2fece2%2fhome%3fcodeContexte%3deceDefault'),
|
||||
|
|
@ -144,19 +208,28 @@ INSERT INTO `raccourcis` (`id`, `nom`, `image`, `url`) VALUES
|
|||
(5, 'Outlook', './Assets/Logos/outlook.jpg', 'https://outlook.live.com/owa/'),
|
||||
(6, 'Netvie', './Assets/Logos/netvie.jpg', 'https://n.netsoins.com/'),
|
||||
(7, 'Teams', './Assets/Logos/teams.png', 'https://login.microsoftonline.com/common/oauth2/v2.0/authorize?response_type=id_token&scope=openid%20profile&client_id=5e3ce6c0-2b1f-4285-8d4b-75ee78787346&redirect_uri=https%3A%2F%2Fteams.microsoft.com%2Fgo&state=eyJpZCI6IjdkMjgxYjQ4LWY2ZDMtNDI4MS05ODUxLWRmYzJkMTE5YzViYSIsInRzIjoxNjU0NjkwMTIxLCJtZXRob2QiOiJyZWRpcmVjdEludGVyYWN0aW9uIn0%3D&nonce=103471a8-5ca1-403b-865b-e9b83ff1e769&client_info=1&x-client-SKU=MSAL.JS&x-client-Ver=1.3.4&client-request-id=7f26a741-1190-4cfe-8025-20c36359120b&response_mode=fragment'),
|
||||
(9, 'Octime', 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAOEAAADhCAMAAAAJbSJIAAAAllBMVEUAUIz///8AS4kAQIOju9BGd6T6/f4ATosASYgAR4dMe6YARYaowdQATIkARocAQ4U7cKBUgKn1+fvk7fMAPoIAU45sk7bM2eXY4+zw9fh9n77q8fZhirErZZnD0+Hg6vG1ydubtc2NqsWBosAaW5J0mLmKqcUyZ5o+caBpkLWxxddbha0wYpbH1uMSWZLS4OsALnoAOYFPEgTXAAAI70lEQVR4nO2aC5OqOBaAMShJRAFBFERFbGh8u/P//9wCOYFgiy19p2pvb52v6k7ZIYac5LwdTUMQBEEQBEEQBEEQBEEQBEEQBEEQBEEQBEEQBEEQBEEQBEEQBEEQBEEQBEEQBEEQBEEQBEEQBEEQBEGQpzDT1htsTujXOcRS51SwYvRxrIWpabz+JJjCI/6wPG3WhD11r9kTyu30/JEMG/arc/qwA6Jr40ydUzEjNH8ca/HJWAafCCzkwKPM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yByjRZNNlcEi2qk1bKih1BMW7Ciuq0+qUWsvisG1GYhv1eTiiSWRcZTfpoBUMLp5aD04p2UWI8BnjLmbw6jFuM6INNcjDgtb36DabdCWPFJvWK6KUbaJyLmF5XUqAM1n+gr5VTpm3ek8ZR2N9jp03bYtG7+P2uXFd9pl9/NpMcXKT8jIH89pXemtPLR4r8i56cw9tuhPD0cLtolz4tAxbTc8Znm52VTI/Xz/MJ/vYw0PXmet0y3XhwczFlQ/DEzZy7R/HsyjuIo+cNa6n8PC8Is3xzS+CP1Tv5g6+TLKF2FNt2EH4so/xz0btX8ZRRpw0i/+dRxs7WbDCONsM1gfAp0MjJGe++WGJdfLqGVBCwNBp+zQTDYWds7L0usUbCbs9mAT4w47vV/YfyNsGywZv7gmA3IpLyxg3VbxrfgbrNh+M995/u/PxySa3i/D8ZJZF7cvRVH9zic2dkgCIxP2/hR0v3XwQ9ZdvTHZ0Jm6+Lfal1EC5ZnmWP5i9/uZQDKLVY4mDJtK/5xYXecT4u0+P9DQARBEARBEARBEARBEARBEARBEARBEARBEARBEARBEARBEARBEARBEARBEARBEARBEARBEARBEARBEOTf5r+dOJVMCYEquAAAAABJRU5ErkJggg==', 'http://172.17.0.239/WD210AWP/WD210AWP.EXE/CONNECT/wmoctime92?INI=APEI&');
|
||||
(9, 'Octime', './Assets/Logos/octime.png', 'http://172.17.0.239/WD210AWP/WD210AWP.EXE/CONNECT/wmoctime92?INI=APEI&'),
|
||||
(10, 'malakoff', 'https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcTcQZG24wWrwI5cMUjZxk2jAoLkM4ue5xVgew&s', 'https://connexion.malakoffhumanis.com/entreprises/login/?sessionOnly=true&goto=https%3A%2F%2Fconnexion.malakoffhumanis.com%2Fentreprises%2Fauth%2Foauth2.0%2Fv1%2Fauthorize%3Fredirect_uri%3Dhttps%253A%252F%252Fespace-entreprise.malakoffhumanis.com%26client_id%3D2984dd01-0449-44cc-bce4-bb5a01d86895%26response_type%3Dcode%26state%3DR9jfTumx7x%26scope%3DphoneNumberAndEmail%2Bentreprises%2Bprofile%2Bopenid%26nonce%3D0.zyyvn70cn5h%26code_challenge%3DJP13n_I6BCRrEUcCL-eWFJOjpPqfEf9vG80th2Hh6tk%26code_challenge_method%3DS256'),
|
||||
(12, 'teste de ra', './Assets/Logos/nothing.jpg', 'https://accounts.google.com/v3/signin/identifier?continue=https%3A%2F%2Fsites.google.com%2Fsite%2Fbdumbge%2Fhome&followup=https%3A%2F%2Fsites.google.com%2Fsite%2Fbdumbge%2Fhome&ifkv=ASKV5Mj4fAqVIp99h_LjoeiDIZX1sTwzSe7T2gg1dsarFNfPdbsyWVCEBrJvAkMXh1UrXnr7zv3cIA&osid=1&passive=1209600&flowName=GlifWebSignIn&flowEntry=ServiceLogin&dsh=S372091009%3A1747655585598786');
|
||||
|
||||
-- Listage de la structure de table intranet. site
|
||||
CREATE TABLE IF NOT EXISTS `site` (
|
||||
`site_id` tinyint NOT NULL AUTO_INCREMENT,
|
||||
`nom` tinytext NOT NULL,
|
||||
PRIMARY KEY (`site_id`) USING BTREE
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb3;
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb3;
|
||||
|
||||
-- Listage des données de la table intranet.site : ~2 rows (environ)
|
||||
-- Listage des données de la table intranet.site : ~9 rows (environ)
|
||||
INSERT INTO `site` (`site_id`, `nom`) VALUES
|
||||
(1, 'siège'),
|
||||
(2, 't');
|
||||
(2, 'siège'),
|
||||
(3, 'ime la source'),
|
||||
(4, 'ime st hilaire'),
|
||||
(5, 'ime jeumont'),
|
||||
(8, 'foyer la longueville'),
|
||||
(10, 'centre habitat'),
|
||||
(11, 'masfamcaj'),
|
||||
(22, 'avs'),
|
||||
(25, 'samsah');
|
||||
|
||||
-- Listage de la structure de table intranet. utilisateurs
|
||||
CREATE TABLE IF NOT EXISTS `utilisateurs` (
|
||||
|
|
@ -170,11 +243,12 @@ CREATE TABLE IF NOT EXISTS `utilisateurs` (
|
|||
KEY `FK_utilisateurs_permissions` (`permissions`),
|
||||
CONSTRAINT `fk_site_id` FOREIGN KEY (`site_id`) REFERENCES `site` (`site_id`) ON DELETE SET NULL ON UPDATE CASCADE,
|
||||
CONSTRAINT `FK_utilisateurs_permissions` FOREIGN KEY (`permissions`) REFERENCES `permissions` (`nom`) ON DELETE CASCADE ON UPDATE CASCADE
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb3 COMMENT='Comptes autorisés à modifier les raccourcis\r\nMots de passes stoqués en SHA256';
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb3 COMMENT='Comptes autorisés à modifier les raccourcis\r\nMots de passes stoqués en SHA256';
|
||||
|
||||
-- Listage des données de la table intranet.utilisateurs : ~1 rows (environ)
|
||||
-- Listage des données de la table intranet.utilisateurs : ~2 rows (environ)
|
||||
INSERT INTO `utilisateurs` (`id`, `username`, `password`, `permissions`, `site_id`) VALUES
|
||||
(1, 'erwann', '5e884898da28047151d0e56f8dc6292773603d0d6aabbdd62a11ef721d1542d8', 'admin', 1);
|
||||
(1, 'erwann', '5e884898da28047151d0e56f8dc6292773603d0d6aabbdd62a11ef721d1542d8', 'admin', 2),
|
||||
(4, 'blandine', '5e884898da28047151d0e56f8dc6292773603d0d6aabbdd62a11ef721d1542d8', 'admin', 2);
|
||||
|
||||
/*!40103 SET TIME_ZONE=IFNULL(@OLD_TIME_ZONE, 'system') */;
|
||||
/*!40101 SET SQL_MODE=IFNULL(@OLD_SQL_MODE, '') */;
|
||||
|
|
|
|||
|
|
@ -40,6 +40,7 @@ if(isset($_POST['user']) && isset($_POST['password']) && isset($_GET['redirect_t
|
|||
<input type="hidden" name="csrf" value="<?= $csrf ?>">
|
||||
<button type="submit" class="btn btn-primary">Connexion</button>
|
||||
</form>
|
||||
<a href="./activate.php">Activer mon compte</a>
|
||||
<h3>En cas d'oubli de votre mot de passe, veuillez contacter Blandine Lemaire au <a href="tel:20117">20117</a></h3>
|
||||
</body>
|
||||
</html>
|
||||
15
styles-scripts/admin.modifyEvent.css
Normal file
15
styles-scripts/admin.modifyEvent.css
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
.preview-box {
|
||||
height: 220px;
|
||||
border: 2px dashed #ddd;
|
||||
border-radius: 8px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
overflow: hidden;
|
||||
background: #fafafa;
|
||||
}
|
||||
|
||||
.preview-box img {
|
||||
max-height: 100%;
|
||||
max-width: 100%;
|
||||
}
|
||||
|
|
@ -47,7 +47,8 @@ document.querySelectorAll(".editable-image").forEach(img => {
|
|||
|
||||
img.addEventListener("click", function () {
|
||||
|
||||
const url = prompt("Nouvelle image (URL ou chemin local):", this.src);
|
||||
let url = "./Assets/Logos/";
|
||||
url += prompt("Nouvelle image (URL ou chemin local):", this.src);
|
||||
|
||||
if (!url) return;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue