refactor: nettoyer terminologie entité→organisation et corriger mapping TONTINE
- ADMIN_ENTITE→ADMIN_ORGANISATION dans Javadoc et README - OrganisationModuleService: retirer TONTINE de MUTUELLE (BCEAO-réglementé, incompatible) - Ajouter TONTINE aux ASSOCIATION et CLUB_SERVICE (pratique courante Afrique de l'Ouest) - V18 migration: aligner modules_requis avec le code Java
This commit is contained in:
@@ -519,13 +519,13 @@ lionsctl pipeline \
|
|||||||
### Authentification
|
### Authentification
|
||||||
|
|
||||||
- **Méthode** : OIDC/JWT via Keycloak
|
- **Méthode** : OIDC/JWT via Keycloak
|
||||||
- **Rôles** : SUPER_ADMIN, ADMIN_ENTITE, MEMBRE_ACTIF, MEMBRE
|
- **Rôles** : SUPER_ADMIN, ADMIN_ORGANISATION, MEMBRE_ACTIF, MEMBRE
|
||||||
- **Token** : Bearer token dans header `Authorization`
|
- **Token** : Bearer token dans header `Authorization`
|
||||||
|
|
||||||
### Endpoints protégés
|
### Endpoints protégés
|
||||||
|
|
||||||
```java
|
```java
|
||||||
@RolesAllowed({"SUPER_ADMIN", "ADMIN_ENTITE"})
|
@RolesAllowed({"SUPER_ADMIN", "ADMIN_ORGANISATION"})
|
||||||
@POST
|
@POST
|
||||||
@Path("/budgets")
|
@Path("/budgets")
|
||||||
public Response createBudget(BudgetRequest request) {
|
public Response createBudget(BudgetRequest request) {
|
||||||
|
|||||||
@@ -82,7 +82,7 @@ import org.jboss.logging.Logger;
|
|||||||
* <ul>
|
* <ul>
|
||||||
* <li>OIDC avec Keycloak (realm: unionflow)</li>
|
* <li>OIDC avec Keycloak (realm: unionflow)</li>
|
||||||
* <li>JWT signature côté backend (HMAC-SHA256)</li>
|
* <li>JWT signature côté backend (HMAC-SHA256)</li>
|
||||||
* <li>RBAC avec rôles: SUPER_ADMIN, ADMIN_ENTITE, MEMBRE</li>
|
* <li>RBAC avec rôles: SUPER_ADMIN, ADMIN_ORGANISATION, MEMBRE</li>
|
||||||
* <li>Permissions granulaires par module</li>
|
* <li>Permissions granulaires par module</li>
|
||||||
* <li>CORS configuré pour client web</li>
|
* <li>CORS configuré pour client web</li>
|
||||||
* <li>HTTPS obligatoire en production</li>
|
* <li>HTTPS obligatoire en production</li>
|
||||||
|
|||||||
@@ -100,12 +100,7 @@ public class OrganisationModuleService {
|
|||||||
modules.add("TONTINE");
|
modules.add("TONTINE");
|
||||||
modules.add("FINANCE");
|
modules.add("FINANCE");
|
||||||
}
|
}
|
||||||
case "MUTUELLE_EPARGNE" -> {
|
case "MUTUELLE", "MUTUELLE_EPARGNE", "MUTUELLE_CREDIT" -> {
|
||||||
modules.add("EPARGNE");
|
|
||||||
modules.add("FINANCE");
|
|
||||||
modules.add("LCB_FT");
|
|
||||||
}
|
|
||||||
case "MUTUELLE_CREDIT" -> {
|
|
||||||
modules.add("EPARGNE");
|
modules.add("EPARGNE");
|
||||||
modules.add("CREDIT");
|
modules.add("CREDIT");
|
||||||
modules.add("FINANCE");
|
modules.add("FINANCE");
|
||||||
@@ -130,7 +125,11 @@ public class OrganisationModuleService {
|
|||||||
case "GIE" -> {
|
case "GIE" -> {
|
||||||
modules.add("FINANCE");
|
modules.add("FINANCE");
|
||||||
}
|
}
|
||||||
case "ASSOCIATION", "CLUB_SERVICE", "CLUB_SPORTIF", "CLUB_CULTUREL" -> {
|
case "ASSOCIATION", "CLUB_SERVICE" -> {
|
||||||
|
modules.add("TONTINE");
|
||||||
|
modules.add("VOTES");
|
||||||
|
}
|
||||||
|
case "CLUB_SPORTIF", "CLUB_CULTUREL" -> {
|
||||||
modules.add("VOTES");
|
modules.add("VOTES");
|
||||||
}
|
}
|
||||||
default -> LOG.debugf("Type d''organisation non reconnu pour module mapping : %s", typeOrganisation);
|
default -> LOG.debugf("Type d''organisation non reconnu pour module mapping : %s", typeOrganisation);
|
||||||
|
|||||||
@@ -60,8 +60,8 @@ END $$;
|
|||||||
INSERT INTO types_reference (id, domaine, libelle, code, categorie, modules_requis, actif, est_defaut, est_systeme, ordre_affichage, date_creation, date_modification, version)
|
INSERT INTO types_reference (id, domaine, libelle, code, categorie, modules_requis, actif, est_defaut, est_systeme, ordre_affichage, date_creation, date_modification, version)
|
||||||
SELECT gen_random_uuid(), 'TYPE_ORGANISATION', v.libelle, v.code, v.categorie, v.modules_requis, true, false, true, 0, NOW(), NOW(), 0
|
SELECT gen_random_uuid(), 'TYPE_ORGANISATION', v.libelle, v.code, v.categorie, v.modules_requis, true, false, true, 0, NOW(), NOW(), 0
|
||||||
FROM (VALUES
|
FROM (VALUES
|
||||||
('Association Générale', 'ASSOCIATION', 'ASSOCIATIF', 'MEMBRES,COTISATIONS,EVENEMENTS,COMMUNICATION,DOCUMENTS,VOTES,AIDE'),
|
('Association Générale', 'ASSOCIATION', 'ASSOCIATIF', 'MEMBRES,COTISATIONS,EVENEMENTS,COMMUNICATION,DOCUMENTS,VOTES,TONTINE,AIDE'),
|
||||||
('Club Service', 'CLUB_SERVICE', 'ASSOCIATIF', 'MEMBRES,COTISATIONS,EVENEMENTS,COMMUNICATION,DOCUMENTS,VOTES,PROJETS_SOLIDAIRES'),
|
('Club Service', 'CLUB_SERVICE', 'ASSOCIATIF', 'MEMBRES,COTISATIONS,EVENEMENTS,COMMUNICATION,DOCUMENTS,VOTES,TONTINE,PROJETS_SOLIDAIRES'),
|
||||||
('Club Sportif', 'CLUB_SPORTIF', 'ASSOCIATIF', 'MEMBRES,COTISATIONS,EVENEMENTS,COMMUNICATION,DOCUMENTS'),
|
('Club Sportif', 'CLUB_SPORTIF', 'ASSOCIATIF', 'MEMBRES,COTISATIONS,EVENEMENTS,COMMUNICATION,DOCUMENTS'),
|
||||||
('Club Culturel', 'CLUB_CULTUREL','ASSOCIATIF', 'MEMBRES,COTISATIONS,EVENEMENTS,COMMUNICATION,DOCUMENTS')
|
('Club Culturel', 'CLUB_CULTUREL','ASSOCIATIF', 'MEMBRES,COTISATIONS,EVENEMENTS,COMMUNICATION,DOCUMENTS')
|
||||||
) AS v(libelle, code, categorie, modules_requis)
|
) AS v(libelle, code, categorie, modules_requis)
|
||||||
|
|||||||
Reference in New Issue
Block a user