Skip to main content

Groupement de déchets amiante

Un traiteur a 2 bordereaux qu'il souhaite groupés. Après la crétation des 2 bordereaux initiaux, un bordereau de groupement est créé.
graph LR A0[(BSDAs à grouper)] -->|createForm| A A(INITIAL) -->|signBsda| B(SIGNED_BY_PRODUCER) B -->|signBsda| C(SIGNED_BY_WORKER) C --> |signBsda| D(SENT) D --> |signBsda| E(PROCESSED)

Les informations du BSDA sont remplies. Ici, comme c'est le groupement qui nous intéresse on rempli un une seule fois toutes les informations du bordereaux, même celles de réception. On a plus qu'à apposer les signatures sur le bordereau pour qu'il soit groupable.
mutation Createbsda($input: BsdaInput!) {  createBsda(input: $input) {    id    status  }}
{  "input": {    "emitter": {      "isPrivateIndividual": false,      "company": {        "siret": "SIRET_PRODUCTEUR",        "name": "Déchets & Co",        "address": "1 rue de paradis, 75010 PARIS",        "contact": "Jean Dupont",        "phone": "01 00 00 00 00",        "mail": "jean.dupont@dechets.org"      },      "pickupSite": {        "address": "5 rue du chantier",        "postalCode": "75010",        "city": "Paris",        "infos": "Site de stockage de boues"      }    },    "worker": {      "company": {        "siret": "SIRET_WORKER",        "name": "Entreprise de travaux & Co",        "address": "1 avenue du travail 67100 Strasbourg",        "contact": "Thomas Lebosseur",        "phone": "03 00 00 00 00",        "mail": "thomas.lebosseur@worker.fr"      }    },    "destination": {      "company": {        "siret": "SIRET_TRAITEUR_1",        "name": "Traiteur & Co",        "address": "1 avenue de l'incinérateur 67100 Strasbourg",        "contact": "Thomas Largeron",        "phone": "03 00 00 00 00",        "mail": "thomas.largeron@incinerateur.fr"      },      "plannedOperationCode": "D 13",      "cap": "CAP",      "reception": {        "acceptationStatus": "ACCEPTED",        "date": "2022-01-13T15:07:34.938Z",        "weight": 2.1      },      "operation": {        "code": "D 13",        "date": "2022-01-13T15:07:34.938Z"      }    },    "transporter": {      "company": {        "siret": "SIRET_TRANSPORTEUR",        "name": "Transport & Co",        "address": "1 rue des 6 chemins, 07100 ANNONAY",        "contact": "Claire Dupuis",        "mail": "claire.dupuis@transportco.fr",        "phone": "04 00 00 00 00"      },      "recepisse": {        "number": "12379",        "department": "07",        "validityLimit": "2020-06-30"      },      "transport": {        "mode": "ROAD",        "plates": [          "abc21cde"        ],        "takenOverAt": "2022-01-13T15:07:34.938Z"      }    },    "waste": {      "code": "16 01 11*",      "consistence": "SOLIDE",      "familyCode": "Code famille",      "materialName": "Nom du matériau",      "name": "Nom",      "sealNumbers": [        "1",        "2",        "3"      ],      "adr": "ADR"    },    "packagings": [      {        "type": "BIG_BAG",        "quantity": 2      }    ],    "weight": {      "isEstimate": true,      "value": 2.3    }  }}
L'entreprise producteur appose une signature "EMISSION" sur le BSDA.
mutation SignBsda($id: ID!, $input: BsdaSignatureInput!) {  signBsda(id: $id, input: $input) {    id    status  }}
{  "id": "ID_BSD",  "input": {    "author": "Jean Dupont",    "type": "EMISSION"  }}
L'entreprise worker appose une signature "WORK" sur le BSDA.
mutation SignBsda($id: ID!, $input: BsdaSignatureInput!) {  signBsda(id: $id, input: $input) {    id    status  }}
{  "id": "ID_BSD",  "input": {    "author": "Jean Dupont",    "type": "WORK"  }}
L'entreprise transporteur appose une signature "TRANSPORT" sur le BSDA.
mutation SignBsda($id: ID!, $input: BsdaSignatureInput!) {  signBsda(id: $id, input: $input) {    id    status  }}
{  "id": "ID_BSD",  "input": {    "author": "Jean Dupont",    "type": "TRANSPORT"  }}
L'entreprise traiteur appose une signature "OPERATION" sur le BSDA.
mutation SignBsda($id: ID!, $input: BsdaSignatureInput!) {  signBsda(id: $id, input: $input) {    id    status  }}
{  "id": "ID_BSD",  "input": {    "author": "Jean Dupont",    "type": "OPERATION"  }}
Les informations du BSDA sont remplies. Ici, comme c'est le groupement qui nous intéresse on rempli un une seule fois toutes les informations du bordereaux, même celles de réception. On a plus qu'à apposer les signatures sur le bordereau pour qu'il soit groupable.
mutation Createbsda($input: BsdaInput!) {  createBsda(input: $input) {    id    status  }}
{  "input": {    "type": "OTHER_COLLECTIONS",    "emitter": {      "isPrivateIndividual": false,      "company": {        "siret": "SIRET_PRODUCTEUR",        "name": "Déchets & Co",        "address": "1 rue de paradis, 75010 PARIS",        "contact": "Jean Dupont",        "phone": "01 00 00 00 00",        "mail": "jean.dupont@dechets.org"      },      "pickupSite": {        "address": "5 rue du chantier",        "postalCode": "75010",        "city": "Paris",        "infos": "Site de stockage de boues"      }    },    "worker": {      "company": {        "siret": "SIRET_WORKER",        "name": "Entreprise de travaux & Co",        "address": "1 avenue du travail 67100 Strasbourg",        "contact": "Thomas Lebosseur",        "phone": "03 00 00 00 00",        "mail": "thomas.lebosseur@worker.fr"      }    },    "destination": {      "company": {        "siret": "SIRET_TRAITEUR_1",        "name": "Traiteur & Co",        "address": "1 avenue de l'incinérateur 67100 Strasbourg",        "contact": "Thomas Largeron",        "phone": "03 00 00 00 00",        "mail": "thomas.largeron@incinerateur.fr"      },      "plannedOperationCode": "D 13",      "cap": "CAP",      "reception": {        "acceptationStatus": "ACCEPTED",        "date": "2022-01-13T15:07:34.938Z",        "weight": 2.1      },      "operation": {        "code": "D 13",        "date": "2022-01-13T15:07:34.938Z"      }    },    "transporter": {      "company": {        "siret": "SIRET_TRANSPORTEUR",        "name": "Transport & Co",        "address": "1 rue des 6 chemins, 07100 ANNONAY",        "contact": "Claire Dupuis",        "mail": "claire.dupuis@transportco.fr",        "phone": "04 00 00 00 00"      },      "recepisse": {        "number": "12379",        "department": "07",        "validityLimit": "2020-06-30"      },      "transport": {        "mode": "ROAD",        "plates": [          "abc21cde"        ],        "takenOverAt": "2022-01-13T15:07:34.938Z"      }    },    "waste": {      "code": "16 01 11*",      "consistence": "SOLIDE",      "familyCode": "Code famille",      "materialName": "Nom du matériau",      "name": "Nom",      "sealNumbers": [        "1",        "2",        "3"      ],      "adr": "ADR"    },    "packagings": [      {        "type": "BIG_BAG",        "quantity": 2      }    ],    "weight": {      "isEstimate": true,      "value": 2.3    }  }}
L'entreprise producteur appose une signature "EMISSION" sur le BSDA.
mutation SignBsda($id: ID!, $input: BsdaSignatureInput!) {  signBsda(id: $id, input: $input) {    id    status  }}
{  "id": "ID_BSD",  "input": {    "author": "Jean Dupont",    "type": "EMISSION"  }}
L'entreprise worker appose une signature "WORK" sur le BSDA.
mutation SignBsda($id: ID!, $input: BsdaSignatureInput!) {  signBsda(id: $id, input: $input) {    id    status  }}
{  "id": "ID_BSD",  "input": {    "author": "Jean Dupont",    "type": "WORK"  }}
L'entreprise transporteur appose une signature "TRANSPORT" sur le BSDA.
mutation SignBsda($id: ID!, $input: BsdaSignatureInput!) {  signBsda(id: $id, input: $input) {    id    status  }}
{  "id": "ID_BSD",  "input": {    "author": "Jean Dupont",    "type": "TRANSPORT"  }}
L'entreprise traiteur appose une signature "OPERATION" sur le BSDA.
mutation SignBsda($id: ID!, $input: BsdaSignatureInput!) {  signBsda(id: $id, input: $input) {    id    status  }}
{  "id": "ID_BSD",  "input": {    "author": "Jean Dupont",    "type": "OPERATION"  }}
Création d'un bordereau initial (amené à être groupé)
mutation Createbsda($input: BsdaInput!) {  createBsda(input: $input) {    id    status  }}
{  "input": {    "type": "GATHERING",    "emitter": {      "isPrivateIndividual": false,      "company": {        "siret": "SIRET_TRAITEUR_1",        "name": "Déchets & Co",        "address": "1 rue de paradis, 75010 PARIS",        "contact": "Jean Dupont",        "phone": "01 00 00 00 00",        "mail": "jean.dupont@dechets.org"      },      "pickupSite": {        "address": "5 rue du chantier",        "postalCode": "75010",        "city": "Paris",        "infos": "Site de stockage de boues"      }    },    "destination": {      "company": {        "siret": "SIRET_TRAITEUR_2",        "name": "Traiteur & Co",        "address": "1 avenue de l'incinérateur 67100 Strasbourg",        "contact": "Thomas Largeron",        "phone": "03 00 00 00 00",        "mail": "thomas.largeron@incinerateur.fr"      },      "plannedOperationCode": "D 5",      "cap": "CAP"    },    "transporter": {      "company": {        "siret": "SIRET_TRANSPORTEUR",        "name": "Transport & Co",        "address": "1 rue des 6 chemins, 07100 ANNONAY",        "contact": "Claire Dupuis",        "mail": "claire.dupuis@transportco.fr",        "phone": "04 00 00 00 00"      },      "recepisse": {        "number": "12379",        "department": "07",        "validityLimit": "2020-06-30"      }    },    "waste": {      "code": "16 01 11*",      "consistence": "SOLIDE",      "familyCode": "Code famille",      "materialName": "Nom du matériau",      "name": "Nom",      "sealNumbers": [        "1",        "2",        "3"      ],      "adr": "ADR"    },    "packagings": [      {        "type": "BIG_BAG",        "quantity": 2      }    ],    "weight": {      "isEstimate": true,      "value": 2.3    },    "grouping": [      "ID_BSD_GROUPE_1",      "ID_BSD_GROUPE_1"    ]  }}
L'entreprise traiteur appose une signature "EMISSION" sur le BSDA.
mutation SignBsda($id: ID!, $input: BsdaSignatureInput!) {  signBsda(id: $id, input: $input) {    id    status  }}
{  "id": "ID_BSD",  "input": {    "author": "Jean Dupont",    "type": "EMISSION"  }}
Mise à jour des informations du BSDA.
mutation Updatebsda($id: ID!, $input: BsdaInput!) {  updateBsda(id: $id, input: $input) {    id    status  }}
{  "id": "ID_BSD",  "input": {    "transporter": {      "transport": {        "mode": "ROAD",        "plates": [          "abc21cde"        ],        "takenOverAt": "2022-01-13T15:07:34.939Z"      }    }  }}
L'entreprise transporteur appose une signature "TRANSPORT" sur le BSDA.
mutation SignBsda($id: ID!, $input: BsdaSignatureInput!) {  signBsda(id: $id, input: $input) {    id    status  }}
{  "id": "ID_BSD",  "input": {    "author": "Jean Dupont",    "type": "TRANSPORT"  }}
Mise à jour des informations du BSDA.
mutation Updatebsda($id: ID!, $input: BsdaInput!) {  updateBsda(id: $id, input: $input) {    id    status  }}
{  "id": "ID_BSD",  "input": {    "destination": {      "reception": {        "acceptationStatus": "ACCEPTED",        "date": "2022-01-13T15:07:34.939Z",        "weight": 2.1      },      "operation": {        "code": "D 5",        "date": "2022-01-13T15:07:34.939Z"      }    }  }}
L'entreprise traiteur2 appose une signature "OPERATION" sur le BSDA.
mutation SignBsda($id: ID!, $input: BsdaSignatureInput!) {  signBsda(id: $id, input: $input) {    id    status  }}
{  "id": "ID_BSD",  "input": {    "author": "Jean Dupont",    "type": "OPERATION"  }}