diff --git a/api.py b/api.py index b6926e4..ff07614 100644 --- a/api.py +++ b/api.py @@ -487,7 +487,6 @@ async def changer_statut_devis(id: str, nouveau_statut: int = Query(..., ge=0, l 📄 Changement de statut d'un devis via gateway Windows """ try: - # ✅ APPEL VIA SAGE_CLIENT (HTTP vers Windows) resultat = sage_client.changer_statut_devis(id, nouveau_statut) logger.info(f"✅ Statut devis {id} changé: {nouveau_statut}") diff --git a/sage_client.py b/sage_client.py index 741794f..d50e1c3 100644 --- a/sage_client.py +++ b/sage_client.py @@ -119,7 +119,7 @@ class SageGatewayClient: def changer_statut_devis(self, numero: str, nouveau_statut: int) -> Dict: """✅ NOUVEAU: Change le statut d'un devis""" return self._post( - "/sage/devis/statut", {"numero": numero, "nouveau_statut": nouveau_statut} + "/sage/devis/{id}/statut", {"numero": numero, "nouveau_statut": nouveau_statut} ).get("data", {}) # =====================================================