feat(erp): verser les pièces juridiques de 1_DOCUMENTS dans la GED (#88)

Co-authored-by: Gabriel Radureau <[email protected]>
This commit was merged in pull request #88.
This commit is contained in:
2026-08-13 19:15:01 +02:00
committed by arcodange
parent 9253ac8d4c
commit 216dc0213b
3 changed files with 529 additions and 0 deletions
+136
View File
@@ -0,0 +1,136 @@
/*
Which documents of 1_DOCUMENTS belong in the ERP, and where.
This is a MANIFEST, not a mirror. 1_DOCUMENTS is the operator's own filing
cabinet — versioned in git, organised the way he thinks. The ERP holds the
subset that a reader of the accounts needs to make sense of them: what
justifies a charge, what proves the company exists, what fixes the terms of an
arrangement between the company and its gérant.
DELIBERATE EXCLUSIONS. Copying everything would be easier and worse:
- identity papers (CNI, justificatif de domicile) — personal data, no
accounting reader needs them, and the ERP is web-facing;
- `documents/__france_travail`, `documents/00_creation/journal|impots|ursaff`
— administrative correspondence, not evidence of a booked fact;
- the housing invoices are included, but as EVIDENCE OF A FORFAIT, never as
charges — see the note on that folder below.
*/
export type GedDir = {
/** Directory label as it appears in the GED tree. */
label: string;
/** Parent label, or null for a root directory. */
parent: string | null;
desc: string;
};
export type GedFile = {
/** Path relative to the 1_DOCUMENTS root. */
src: string;
/** Directory label it belongs to. */
dir: string;
/** Filename in the GED — ASCII, no spaces: the upload API and the URLs that
* serve the file both handle them poorly, and a document nobody can link to
* is a document nobody will read. */
as: string;
};
export const DIRS: GedDir[] = [
{
label: "Juridique",
parent: null,
desc: "Pièces constitutives et registres de la société. Copie de travail — l'original fait foi dans 1_DOCUMENTS, versionné en git.",
},
{
label: "Identite",
parent: "Juridique",
desc: "Statuts, KBIS, registre des bénéficiaires effectifs.",
},
{
label: "Decisions",
parent: "Juridique",
desc: "Registre des décisions de l'associé unique. Numérotation chronologique, jamais réutilisée.",
},
{
label: "Domiciliation",
parent: "Juridique",
desc: "Siège social au domicile du gérant : convention d'indemnité d'occupation, autorisation du propriétaire, plan, notification syndic, bail sous-jacent.",
},
{
label: "Domiciliation-justificatifs",
parent: "Juridique",
desc: "Base de calcul du forfait de 220 EUR/mois. CES FACTURES NE SONT PAS DES CHARGES DE LA SOCIETE : la convention les inclut forfaitairement dans l'indemnité et exclut toute régularisation. Les enregistrer séparément serait un double emploi.",
},
];
export const FILES: GedFile[] = [
// --- Identité ---
{
src: "documents/01_identite/Statuts_SARLU_ARCODANGE.pdf",
dir: "Identite",
as: "statuts-sarlu-arcodange.pdf",
},
{
src: "documents/01_identite/Extrait KBIS_ARCODANGE.pdf",
dir: "Identite",
as: "extrait-kbis-arcodange.pdf",
},
{
src: "documents/02_registres/beneficiaires_effectifs_RBE/RBE_10110895_.pdf",
dir: "Identite",
as: "registre-beneficiaires-effectifs.pdf",
},
// --- Registre des décisions ---
{
src: "documents/02_registres/decisions/0001_domiciliation_evry_coucouronnes.pdf",
dir: "Decisions",
as: "0001-decision-associe-unique-domiciliation.pdf",
},
// --- Domiciliation ---
{
src: "documents/00_creation/siege/AUTORISATION DUSAGE PROFESSIONNEL ET DE SOUS-LOCATION PARTIELLE.pdf",
dir: "Domiciliation",
as: "autorisation-proprietaire-usage-professionnel.pdf",
},
{
src: "documents/00_creation/siege/planDomiciliationARCODANGE.pdf",
dir: "Domiciliation",
as: "plan-domiciliation.pdf",
},
{
src: "documents/00_creation/siege/notification_syndic.pdf",
dir: "Domiciliation",
as: "notification-syndic-copropriete.pdf",
},
// EXCLU — le bail sous-jacent (Joël → Gabriel Radureau, 60 m²) pèse 8,6 Mo :
// un scan 11 pages en 5100×7016 pts. L'ERP plafonne le téléversement à 2 Mo
// (`MAX_FILE_SIZE`). Le recompresser reviendrait à altérer le rendu d'une
// pièce juridique avec un outil dont personne n'a vérifié la sortie ; il reste
// donc dans 1_DOCUMENTS, versionné en git, qui en est de toute façon
// l'exemplaire de référence. Pour le verser malgré tout : relever
// `MAIN_UPLOAD_DOC` côté Dolibarr et `upload_max_filesize` côté PHP.
// Ce n'est pas la pièce opérante : la convention d'indemnité et l'autorisation
// du propriétaire le sont, et toutes deux sont versées.
// --- Justificatifs du forfait ---
// Le forfait de 220 EUR couvre « quote-part de valeur locative, électricité,
// chauffage et accès à internet ». Ces trois pièces montrent que le montant
// n'a pas été choisi au hasard — c'est tout ce qu'on leur demande.
{
src: "factures/logement/electricite_76_50_TTC_BiMestriel.pdf",
dir: "Domiciliation-justificatifs",
as: "totalenergies-electricite-bimestriel.pdf",
},
{
src: "factures/logement/internet_orange_janvier_29_99_TTC_mensuel.pdf",
dir: "Domiciliation-justificatifs",
as: "orange-fibre-29-99-mensuel.pdf",
},
{
src: "factures/logement/assuranceHabitationAssocie_83_18_annuel.pdf",
dir: "Domiciliation-justificatifs",
as: "assurance-habitation-83-18-annuel.pdf",
},
];