864bc7e8e8
Nouveau module Logistique (M5), sans entité ni migration (ticket 1.2) : - LogistiqueModule (ID logistique, permissions weighing_tickets.view/manage) enregistré dans config/modules.php - layer front frontend/modules/logistique (auto-détecté) - sidebar : section Logistique + item /weighing-tickets (gate ...view) + clés i18n sidebar.logistique.* - 3 miroirs RBAC alignés : sidebar.php, personas.ts (user-full), SeedE2ECommand (user-full) - matrice métier RbacSeeder : Bureau + Usine = view/manage ; Compta + Commerciale = aucun accès (spec § 5.2)
34 lines
1.1 KiB
PHP
34 lines
1.1 KiB
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Module\Logistique;
|
|
|
|
final class LogistiqueModule
|
|
{
|
|
public const string ID = 'logistique';
|
|
public const string LABEL = 'Logistique';
|
|
public const bool REQUIRED = false;
|
|
|
|
/**
|
|
* Liste declarative des permissions RBAC exposees par le module Logistique.
|
|
*
|
|
* Socle des tickets de pesee (M5 § 5.1, ERP-181) :
|
|
* - `view` : consultation de la liste / fiche d'un ticket de pesee ;
|
|
* - `manage` : creation / modification d'un ticket de pesee.
|
|
*
|
|
* Consommee par `app:sync-permissions`. Matrice role -> permissions dans
|
|
* `RbacSeeder::MATRIX` (§ 5.2 : Bureau / Usine = view + manage ; Compta /
|
|
* Commerciale = aucun acces).
|
|
*
|
|
* @return array<int, array{code: string, label: string}>
|
|
*/
|
|
public static function permissions(): array
|
|
{
|
|
return [
|
|
['code' => 'logistique.weighing_tickets.view', 'label' => 'Voir les tickets de pesée'],
|
|
['code' => 'logistique.weighing_tickets.manage', 'label' => 'Créer / modifier les tickets de pesée'],
|
|
];
|
|
}
|
|
}
|