# Réinstallation TIJARA from zero

Package complet du **même projet** (PHP + Flutter) pour repartir à neuf.

## Téléchargement

- Branche : https://github.com/stegeoflotte-dev/dev/archive/refs/heads/cursor/gestion-commerciale-maroc-6eed.zip  
- Package prêt : `releases/TIJARA-FRESH-INSTALL.zip`

## Base MySQL neuve

1. Créer une base vide (cPanel)
2. phpMyAdmin → Import :
   - optionnel : `sql/drop_all.mysql.sql` (si ancienne base)
   - puis : `sql/schema_full.mysql.sql` (schéma complet)

## Config + seed

```bash
cp includes/config.example.php includes/config.php
# éditer MySQL + app_url + jwt_secret
php sql/fresh_install.php
```

Sans SSH :

```
https://VOTRE-DOMAINE/install_web.php?key=tijara-install-2026&fresh=1
```

Puis **supprimer** `install_web.php`.

## Comptes démo

- `admin@atlastech.ma` / `admin123`
- `commercial@atlastech.ma` / `demo123`
- `comptable@atlastech.ma` / `demo123`
- `flotte@atlastech.ma` / `demo123`
- `chauffeur@atlastech.ma` / `demo123`

## Flutter

```bash
cd flutter_app
flutter build apk --dart-define=API_URL=https://VOTRE-DOMAINE
```

Guide arabe détaillé : `INSTALL-FROM-ZERO-AR.md`
