Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
5dbed78
add new table for tracking interventions with relevant attributes
MohammedBelfellah Dec 4, 2025
ccddc42
update table header and attributes for document/media tracking
MohammedBelfellah Dec 4, 2025
35baed3
Merge pull request #6 from MohammedBelfellah/modifications-MCD-MOT
MohammedBelfellah Dec 4, 2025
12db608
feat: Add building management templates and functionality
MohammedBelfellah Dec 6, 2025
192e246
feat: Add custom Jinja filter for safe date formatting and enhance in…
MohammedBelfellah Dec 6, 2025
23643b6
feat: Enhance dashboard with map view and building details integration
MohammedBelfellah Dec 6, 2025
a0d9c2e
Enhance building, inspection, and intervention listings with search a…
MohammedBelfellah Dec 6, 2025
fde7541
feat: Add, edit, and view templates for proprietors, protections, and…
MohammedBelfellah Dec 6, 2025
ded304f
feat: Add document management templates and functionality
MohammedBelfellah Dec 6, 2025
fe4432b
feat: Implement edit functionality for inspections and interventions,…
MohammedBelfellah Dec 6, 2025
93a0d88
feat: Improve delete confirmation and enhance datalist options in var…
MohammedBelfellah Dec 6, 2025
7158743
feat: Update .gitignore, modify run configuration, and add Procfile f…
MohammedBelfellah Dec 6, 2025
9aca48d
feat: Update run.py to set default port to 5000 and enable debug mode…
MohammedBelfellah Dec 6, 2025
79516e1
feat: Refactor config and run scripts to improve environment variable…
MohammedBelfellah Dec 6, 2025
d9fbb0b
feat: Update requirements.txt to include new dependencies and improve…
MohammedBelfellah Dec 6, 2025
2d635c9
Refactor code structure for improved readability and maintainability
MohammedBelfellah Dec 6, 2025
5419534
feat: Enhance navbar branding with custom SVG logo and adjust styles
MohammedBelfellah Dec 8, 2025
eb9e96f
Revise README for SIPU project details
MohammedBelfellah Dec 10, 2025
99e1271
Update database connection method in db.py
MohammedBelfellah Dec 10, 2025
5e21baa
Clean up run.py by removing unused code
MohammedBelfellah Dec 10, 2025
18d4b6d
Refactor code structure for improved readability and maintainability
MohammedBelfellah Dec 10, 2025
11dc850
Refactor code structure for improved readability and maintainability
MohammedBelfellah Dec 13, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added MCC/mcc.PNG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added MCT/mct.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 11 additions & 0 deletions MLD/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,17 @@ <h1>Modèle Logique de Données (MLD)</h1>
</div>
</div>

<div class="table-box">
<div class="table-header">DOCUMENT / MEDIA</div>
<div class="table-content">
<div class="attribute"><span class="pk">ID_Doc</span></div>
<div class="attribute">Titre_Document</div>
<div class="attribute">Type</div>
<div class="attribute">URL_Fichier</div>
<div class="attribute"><span class="fk">Code_Batiment</span> <span class="fk-desc">(Réf. Bâtiment)</span></div>
</div>
</div>

</div>

</body>
Expand Down
Binary file added MOT/MOT.pdf
Binary file not shown.
251 changes: 0 additions & 251 deletions MOT/index.html

This file was deleted.

37 changes: 37 additions & 0 deletions MPD/update_schema_table_stracter.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
-- 1. Enable PostGIS extension (if not already done)
CREATE EXTENSION IF NOT EXISTS postgis;

-- 2. Add the geometry column
ALTER TABLE BATIMENT
ADD COLUMN geom GEOMETRY(POINT, 4326);

-- 3. (Optional) Auto-fill geometry from your existing lat/lon columns
UPDATE BATIMENT
SET geom = ST_SetSRID(ST_MakePoint(longitude, latitude), 4326)
WHERE longitude IS NOT NULL AND latitude IS NOT NULL;




ALTER TABLE INTERVENTION
ADD COLUMN date_validation DATE,
ADD COLUMN commentaire_validation TEXT; -- For notes from the municipality




ALTER TABLE INTERVENTION
ADD COLUMN statut_travaux VARCHAR(50) DEFAULT 'Planifié';
-- Example values: 'Planifié', 'En cours', 'Terminé', 'Annulé'


-- Add a constraint to ensure only valid states are entered
ALTER TABLE INSPECTION
ADD CONSTRAINT chk_etat_constate
CHECK (etat_constate IN ('Bon', 'Moyen', 'Dégradé', 'En ruine'));






Binary file modified Mini-Projet géoinformation_2025-2026.pdf
Binary file not shown.
Binary file removed Mini-Projet2géoinformation_2025-2026.pdf
Binary file not shown.
78 changes: 77 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,77 @@
# mini-project
# 🏰 Système d'Information Patrimonial Urbain (SIPU)

<p align="center">
<img src="https://img.shields.io/badge/École-FST%20Tanger-blue?style=for-the-badge&logo=academic" alt="FST Tanger">
<img src="https://img.shields.io/badge/Filière-Géoinformation-green?style=for-the-badge&logo=map" alt="GéoInfo">
<img src="https://img.shields.io/badge/Cours-Admin%20Réseaux%20%26%20OS-orange?style=for-the-badge&logo=linux" alt="OS">
</p>

<p align="center">
<strong>Un projet complet d'ingénierie : De la conception Merise au déploiement Cloud.</strong>
</p>

---

## 📖 Présentation

Ce dépôt contient l'intégralité du projet de **Gestion du Patrimoine Urbain**. Il a pour but de moderniser le suivi des monuments historiques en centralisant les données techniques, administratives et géographiques au sein d'un système unique.

Le projet est structuré pour suivre rigoureusement le cycle de vie d'un logiciel, depuis l'analyse conceptuelle jusqu'à l'implémentation technique.

---

## 📂 Structure du Dépôt

L'organisation des fichiers suit la méthodologie **MERISE**, garantissant une traçabilité complète de la conception.

| Dossier | Description | Contenu |
| :--- | :--- | :--- |
| **🗂️ MCC** | Modèle Conceptuel de Communication | Diagrammes de flux entre les acteurs (Service Municipal, Prestataires). |
| **🧠 MCD** | Modèle Conceptuel de Données | Schémas Entité-Association (Bâtiments, Inspections, Zones). |
| **⚙️ MCT** | Modèle Conceptuel de Traitements | Diagrammes des processus métier (Validation travaux, Inspections). |
| **📋 MOT** | Modèle Organisationnel de Traitements | Répartition des tâches (Homme vs Machine). |
| **🔄 MLD** | Modèle Logique de Données | Traduction du MCD en schéma relationnel (Clés étrangères). |
| **💾 MPD** | Modèle Physique de Données | Scripts de création des tables PostgreSQL. |
| **💻 ui-app** | **Application Web (Code Source)** | Le code Python/Flask complet. **(Voir README interne)** |
| **🔍 requetes_SQL** | Analyses de Données | Requêtes SQL complexes pour les statistiques (Question 10). |

---

## 🛠️ Stack Technologique

Le projet s'appuie sur des technologies robustes et open-source :

* **Conception :** Méthode Merise.
* **Base de Données :** PostgreSQL 16 + **PostGIS** (Extension Spatiale).
* **Backend :** Python 3.10 (Flask Framework).
* **Frontend :** Bootstrap 5 + Jinja2.
* **Cartographie :** Leaflet.js.
* **Déploiement :** Railway (App) + Neon (Database).

---

## 🚀 Installation et Démonstration

### Pour lancer l'application :
Toute la documentation technique, l'installation des dépendances (`requirements.txt`) et le guide de démarrage se trouvent dans le dossier dédié :

👉 **[Accéder au dossier `ui-app`](./ui-app)**

### Documents de référence :
Les spécifications complètes et le rapport final sont disponibles à la racine :
* `Mini-Projet géoinformation_2025-2026.pdf` (Cahier des charges)

---

## 👥 Auteurs

Projet réalisé par les étudiants ingénieurs de la **FST Tanger** :

* **Mohammed Belfellah** ([@MohammedBelfellah](https://github.com/MohammedBelfellah))
* **Hamza Boulahrouf** ([@Hamza-7bl](https://github.com/Hamza-7bl))

---

<p align="center">
<i>Année Universitaire 2024-2025</i>
</p>
Empty file removed mini-projet.txt
Empty file.
4 changes: 4 additions & 0 deletions ui-app/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
venv/
.env
*.pyc
__pycache__/
1 change: 1 addition & 0 deletions ui-app/Procfile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
web: gunicorn run:app
Loading