mirror of
https://github.com/Ladebeze66/llm_ticket3.git
synced 2025-12-15 20:17:14 +01:00
15:20
This commit is contained in:
parent
85079a6281
commit
009a5c1186
File diff suppressed because it is too large
Load Diff
@ -1,70 +0,0 @@
|
||||
# Ticket T0167: Pb d'affaire/chantier/partie dans un programme d'essai
|
||||
|
||||
## Informations du ticket
|
||||
|
||||
- **id**: 179
|
||||
- **code**: T0167
|
||||
- **name**: Pb d'affaire/chantier/partie dans un programme d'essai
|
||||
- **project_name**: Demandes
|
||||
- **stage_name**: Clôturé
|
||||
- **user_id**:
|
||||
- **partner_id/email_from**: CONSEIL DEPARTEMENTAL DU CALVADOS (14), Guillaume LENEVEU, guillaume.leneveu@calvados.fr
|
||||
- **create_date**: 27/04/2020 06:21:36
|
||||
- **write_date/last modification**: 03/10/2024 13:10:50
|
||||
|
||||
- **description**:
|
||||
|
||||
Je viens vers toi car Mr NOVO m’a fait remonter un léger beug sur le numéro d’échantillon B2020-0001 (Voir PJ).
|
||||
En effet, il n’arrive pas à mettre le nom de la partie dans la partie ( en rouge sur la PJ). Il faudrait mettre « joint de chaussée côté giberville » comme stipulé dans le numéro d’affaire -> 20017 SETR -> LIAISON RD403 – RD402 DESSERTE PORTUAIRE VIADUC -> JOINT DE CHAUSSEE COTE GIBERVILLE.
|
||||
J’ai essayé de modifié la partie mais je n’y arrive pas.
|
||||
|
||||
## Messages
|
||||
|
||||
### Message 1
|
||||
**author_id**: Youness BENDEQ
|
||||
**date**: 27/04/2020 06:20:22
|
||||
**message_type**: E-mail
|
||||
**subject**: Pb d'affaire/chantier/partie dans un programme d'essai
|
||||
**id**: 11333
|
||||
\-------- Message transféré -------- Sujet : | De retour !
|
||||
---|---
|
||||
Date : | Mon, 20 Apr 2020 14:52:05 +0000
|
||||
De : | LENEVEU Guillaume [](mailto:Guillaume.LENEVEU@calvados.fr)
|
||||
Pour : | Youness BENDEQ [](mailto:youness.bendeq@cbao.fr)
|
||||
|
||||
Bonjour Youness,
|
||||
|
||||
J’espère que tu vas bien ainsi que toute l’équipe BRG-LAB.
|
||||
|
||||
Je viens vers toi car Mr NOVO m’a fait remonter un léger beug sur le numéro d’échantillon B2020-0001 (Voir PJ). En effet, il n’arrive pas à mettre le nom de la partie dans la partie ( en rouge sur la PJ). Il faudrait mettre « joint de chaussée côté giberville » comme stipulé dans le numéro d’affaire -> 20017 SETR -> LIAISON RD403 – RD402 DESSERTE PORTUAIRE VIADUC -> JOINT DE CHAUSSEE COTE GIBERVILLE.
|
||||
|
||||
J’ai essayé de modifié la partie mais je n’y arrive pas.
|
||||
|
||||
Merci de ta réponse.
|
||||
|
||||
Bonne fin de journée.
|
||||
|
||||
**Cordialement,
|
||||
|
||||
DGA Aménagement et Environnement Direction de l’eau et des Risques Adjoint au Chef du service Laboratoire Routes et Matériaux 24 rue des Monts Panneaux ZI Ouest
|
||||
|
||||
14650 Carpiquet
|
||||
|
||||
**Tél.** 02 31 26 52 62
|
||||
|
||||
**Port.** 06 11 39 10 60
|
||||
|
||||
**Fax.** 02 31 26 99 38 **Mail.**_[guillaume.leneveu@calvados.fr](mailto:guillaume.leneveu@calvados.fr)
|
||||
|
||||
_
|
||||
|
||||
**attachment_ids**:
|
||||
- Problème partie.png (image/png) [ID: 32382]
|
||||
- image001.png (image/png) [ID: 32380]
|
||||
|
||||
---
|
||||
|
||||
## Informations sur l'extraction
|
||||
|
||||
- **Date d'extraction**: 04/04/2025 11:49:08
|
||||
- **Répertoire**: output/ticket_T0167/T0167_20250404_114905
|
||||
File diff suppressed because one or more lines are too long
@ -1,111 +0,0 @@
|
||||
TICKET: T0167 - Pb d'affaire/chantier/partie dans un programme d'essai
|
||||
Date d'extraction: 2025-04-04 11:49:08
|
||||
Nombre de messages: 5
|
||||
|
||||
================================================================================
|
||||
|
||||
********************************************************************************
|
||||
*** MESSAGE TRANSFÉRÉ ***
|
||||
********************************************************************************
|
||||
|
||||
DATE: 2020-04-27 06:20:22
|
||||
DE: Youness BENDEQ
|
||||
OBJET: Pb d'affaire/chantier/partie dans un programme d'essai
|
||||
|
||||
\-------- Message transféré -------- Sujet : | De retour !
|
||||
---|---
|
||||
Date : | Mon, 20 Apr 2020 14:52:05 +0000
|
||||
De : | LENEVEU Guillaume [](mailto:Guillaume.LENEVEU@calvados.fr)
|
||||
Pour : | Youness BENDEQ [](mailto:youness.bendeq@cbao.fr)
|
||||
|
||||
Bonjour Youness,
|
||||
|
||||
J’espère que tu vas bien ainsi que toute l’équipe BRG-LAB.
|
||||
|
||||
Je viens vers toi car Mr NOVO m’a fait remonter un léger beug sur le numéro d’échantillon B2020-0001 (Voir PJ). En effet, il n’arrive pas à mettre le nom de la partie dans la partie ( en rouge sur la PJ). Il faudrait mettre « joint de chaussée côté giberville » comme stipulé dans le numéro d’affaire -> 20017 SETR -> LIAISON RD403 – RD402 DESSERTE PORTUAIRE VIADUC -> JOINT DE CHAUSSEE COTE GIBERVILLE.
|
||||
|
||||
J’ai essayé de modifié la partie mais je n’y arrive pas.
|
||||
|
||||
Merci de ta réponse.
|
||||
|
||||
Bonne fin de journée.
|
||||
|
||||
**Cordialement,
|
||||
|
||||
**
|
||||
|
||||
**Guillaume LENEVEU**
|
||||
|
||||
DGA Aménagement et Environnement Direction de l’eau et des Risques Adjoint au Chef du service Laboratoire Routes et Matériaux 24 rue des Monts Panneaux ZI Ouest
|
||||
|
||||
14650 Carpiquet
|
||||
|
||||
**Tél.** 02 31 26 52 62
|
||||
|
||||
**Port.** 06 11 39 10 60
|
||||
|
||||
**Fax.** 02 31 26 99 38 **Mail.**_[guillaume.leneveu@calvados.fr](mailto:guillaume.leneveu@calvados.fr)
|
||||
|
||||
_
|
||||
|
||||

|
||||
|
||||
|
||||
**************************************************************************************************
|
||||
« Cette transmission contient des informations confidentielles et/ou personnelles
|
||||
appartenant au conseil départemental du Calvados pour être utilisées exclusivement par le
|
||||
destinataire. Toute utilisation, reproduction, publication, diffusion en l'état ou
|
||||
partiellement par une autre personne que le destinataire est interdite, sauf autorisation
|
||||
expresse du conseil départemental du Calvados. En cas d'erreur de transmission, merci de
|
||||
détruire le(s) document(s) reçu(s). Le conseil départemental du Calvados n'est pas
|
||||
responsable des virus, altérations, falsifications.
|
||||
Droits réservés - conseil départemental du Calvados».
|
||||
**************************************************************************************************
|
||||
|
||||
---
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
********************************************************************************
|
||||
*** CHANGEMENT D'ÉTAT ***
|
||||
********************************************************************************
|
||||
|
||||
DATE: 2020-04-27 06:21:37
|
||||
DE: OdooBot
|
||||
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
********************************************************************************
|
||||
*** CHANGEMENT D'ÉTAT ***
|
||||
********************************************************************************
|
||||
|
||||
DATE: 2020-04-27 07:19:57
|
||||
DE: Youness BENDEQ
|
||||
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
********************************************************************************
|
||||
*** CHANGEMENT D'ÉTAT ***
|
||||
********************************************************************************
|
||||
|
||||
DATE: 2020-04-27 07:20:20
|
||||
DE: Youness BENDEQ
|
||||
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
********************************************************************************
|
||||
*** CHANGEMENT D'ÉTAT ***
|
||||
********************************************************************************
|
||||
|
||||
DATE: 2020-04-27 07:24:40
|
||||
DE: Youness BENDEQ
|
||||
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 249 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 24 KiB |
@ -1,38 +0,0 @@
|
||||
[
|
||||
{
|
||||
"id": 32382,
|
||||
"name": "Problème partie.png",
|
||||
"mimetype": "image/png",
|
||||
"file_size": 255246,
|
||||
"create_date": "2020-04-27 06:21:36",
|
||||
"create_uid": [
|
||||
1,
|
||||
"OdooBot"
|
||||
],
|
||||
"description": "Problème partie.png",
|
||||
"res_name": "[T0167] Pb d'affaire/chantier/partie dans un programme d'essai",
|
||||
"creator_name": "OdooBot",
|
||||
"creator_id": 1,
|
||||
"download_status": "success",
|
||||
"local_path": "output/ticket_T0167/T0167_20250404_114905/attachments/Probleme_partie.png",
|
||||
"error": ""
|
||||
},
|
||||
{
|
||||
"id": 32380,
|
||||
"name": "image001.png",
|
||||
"mimetype": "image/png",
|
||||
"file_size": 25085,
|
||||
"create_date": "2020-04-27 06:21:36",
|
||||
"create_uid": [
|
||||
1,
|
||||
"OdooBot"
|
||||
],
|
||||
"description": "image001.png",
|
||||
"res_name": "[T0167] Pb d'affaire/chantier/partie dans un programme d'essai",
|
||||
"creator_name": "OdooBot",
|
||||
"creator_id": 1,
|
||||
"download_status": "success",
|
||||
"local_path": "output/ticket_T0167/T0167_20250404_114905/attachments/image001.png",
|
||||
"error": ""
|
||||
}
|
||||
]
|
||||
@ -1,9 +0,0 @@
|
||||
[
|
||||
{
|
||||
"id": 10972,
|
||||
"partner_id": [
|
||||
8504,
|
||||
"CONSEIL DEPARTEMENTAL DU CALVADOS (14), Guillaume LENEVEU"
|
||||
]
|
||||
}
|
||||
]
|
||||
File diff suppressed because one or more lines are too long
@ -1,57 +0,0 @@
|
||||
{
|
||||
"id": 179,
|
||||
"name": "Pb d'affaire/chantier/partie dans un programme d'essai",
|
||||
"description": "<p>Je viens vers toi car Mr NOVO m’a fait remonter un léger beug sur le numéro d’échantillon B2020-0001 (Voir PJ).</p><p>En effet, il n’arrive pas à mettre le nom de la partie dans la partie ( en rouge sur la PJ). Il faudrait mettre « joint de chaussée côté giberville » comme stipulé dans le numéro d’affaire -> 20017 SETR -> LIAISON RD403 – RD402 DESSERTE PORTUAIRE VIADUC -> JOINT DE CHAUSSEE COTE GIBERVILLE.</p><p>J’ai essayé de modifié la partie mais je n’y arrive pas.</p>",
|
||||
"stage_id": [
|
||||
8,
|
||||
"Clôturé"
|
||||
],
|
||||
"project_id": [
|
||||
3,
|
||||
"Demandes"
|
||||
],
|
||||
"partner_id": [
|
||||
8504,
|
||||
"CONSEIL DEPARTEMENTAL DU CALVADOS (14), Guillaume LENEVEU"
|
||||
],
|
||||
"user_id": [
|
||||
9,
|
||||
"Youness BENDEQ"
|
||||
],
|
||||
"date_start": "2020-04-20 14:52:00",
|
||||
"date_end": false,
|
||||
"date_deadline": false,
|
||||
"create_date": "2020-04-27 06:21:36",
|
||||
"write_date": "2024-10-03 13:10:50",
|
||||
"tag_ids": [
|
||||
15
|
||||
],
|
||||
"priority": "0",
|
||||
"email_from": "guillaume.leneveu@calvados.fr",
|
||||
"email_cc": "",
|
||||
"message_ids": [
|
||||
11346,
|
||||
11345,
|
||||
11344,
|
||||
11343,
|
||||
11342,
|
||||
11335,
|
||||
11334,
|
||||
11333,
|
||||
11332
|
||||
],
|
||||
"message_follower_ids": [
|
||||
10972
|
||||
],
|
||||
"timesheet_ids": [
|
||||
51
|
||||
],
|
||||
"attachment_ids": [],
|
||||
"stage_id_name": "Clôturé",
|
||||
"project_id_name": "Demandes",
|
||||
"partner_id_name": "CONSEIL DEPARTEMENTAL DU CALVADOS (14), Guillaume LENEVEU",
|
||||
"user_id_name": "Youness BENDEQ",
|
||||
"tag_names": [
|
||||
"BRG-LAB WEB"
|
||||
]
|
||||
}
|
||||
@ -1,16 +0,0 @@
|
||||
{
|
||||
"id": 179,
|
||||
"code": "T0167",
|
||||
"name": "Pb d'affaire/chantier/partie dans un programme d'essai",
|
||||
"description": "<p>Je viens vers toi car Mr NOVO m’a fait remonter un léger beug sur le numéro d’échantillon B2020-0001 (Voir PJ).</p><p>En effet, il n’arrive pas à mettre le nom de la partie dans la partie ( en rouge sur la PJ). Il faudrait mettre « joint de chaussée côté giberville » comme stipulé dans le numéro d’affaire -> 20017 SETR -> LIAISON RD403 – RD402 DESSERTE PORTUAIRE VIADUC -> JOINT DE CHAUSSEE COTE GIBERVILLE.</p><p>J’ai essayé de modifié la partie mais je n’y arrive pas.</p>",
|
||||
"stage": "Clôturé",
|
||||
"project": "Demandes",
|
||||
"partner": "CONSEIL DEPARTEMENTAL DU CALVADOS (14), Guillaume LENEVEU",
|
||||
"assigned_to": "Youness BENDEQ",
|
||||
"tags": [
|
||||
"BRG-LAB WEB"
|
||||
],
|
||||
"create_date": "2020-04-27 06:21:36",
|
||||
"write_date": "2024-10-03 13:10:50",
|
||||
"deadline": false
|
||||
}
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
703
output/ticket_T0282/T0282_20250404_151451/all_messages.json
Normal file
703
output/ticket_T0282/T0282_20250404_151451/all_messages.json
Normal file
File diff suppressed because one or more lines are too long
351
output/ticket_T0282/T0282_20250404_151451/all_messages.txt
Normal file
351
output/ticket_T0282/T0282_20250404_151451/all_messages.txt
Normal file
File diff suppressed because one or more lines are too long
@ -0,0 +1,34 @@
|
||||
CBAO S.A.R.L. Développeur de rentabilité
|
||||
80 rue Louis Braille
|
||||
66000 Perpignan Bram Béton, Elisabeth PATEBEX
|
||||
France La Sablière
|
||||
Rte de Montréal - BP 32
|
||||
Bram Béton, BRAM BÉTON 11150 BRAM
|
||||
La Sablière France
|
||||
Rte de Montréal - BP 32
|
||||
BRAM 11150
|
||||
|
||||
Devis № SO012
|
||||
|
||||
Date du devis : Vendeur : Date d'expiration:
|
||||
17/06/2020 16:08:08 Youness BENDEQ 17/07/2020
|
||||
|
||||
Description Quantité Prix unitaire Taxes Montant
|
||||
|
||||
Développement
|
||||
|
||||
DÉVELOPPEMENT SPÉCIFIQUE (1H) 3,000 90,00 TVA 20% 270,00 €
|
||||
|
||||
Création d'un programme permettant de renommer 462 numéros de formules à béton tout en préservant l'intégrité
|
||||
de la base de données.
|
||||
|
||||
Sous-total 270,00 €
|
||||
TVA 20% sur 270,00 € 54,00 €
|
||||
Total
|
||||
324,00 €
|
||||
|
||||
https://odoo.cbao.fr/conditions-generales-de-prestations
|
||||
|
||||
Téléphone : 04 68 64 15 31 Courriel : contact@cbao.fr Web: http://www.cbao.fr TVA: 35 415 079 433
|
||||
Page: 1 / 1
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
After Width: | Height: | Size: 118 B |
Binary file not shown.
Binary file not shown.
146
output/ticket_T0282/T0282_20250404_151451/attachments_info.json
Normal file
146
output/ticket_T0282/T0282_20250404_151451/attachments_info.json
Normal file
@ -0,0 +1,146 @@
|
||||
[
|
||||
{
|
||||
"id": 33829,
|
||||
"name": "Devis-SO012.pdf",
|
||||
"mimetype": "application/pdf",
|
||||
"file_size": 36688,
|
||||
"create_date": "2020-06-17 14:30:00",
|
||||
"create_uid": [
|
||||
9,
|
||||
"Youness BENDEQ"
|
||||
],
|
||||
"description": false,
|
||||
"res_name": "[T0282] Renommage du numéro d'identification de certaines formules dans BCN",
|
||||
"creator_name": "Youness BENDEQ",
|
||||
"creator_id": 9,
|
||||
"download_status": "success",
|
||||
"local_path": "output/ticket_T0282/T0282_20250404_151451/attachments/Devis-SO012.pdf",
|
||||
"error": ""
|
||||
},
|
||||
{
|
||||
"id": 33752,
|
||||
"name": "Formules Patebex Cournanel.xls",
|
||||
"mimetype": "application/vnd.ms-excel",
|
||||
"file_size": 72704,
|
||||
"create_date": "2020-06-16 12:51:44",
|
||||
"create_uid": [
|
||||
1,
|
||||
"OdooBot"
|
||||
],
|
||||
"description": "Formules Patebex Cournanel.xls",
|
||||
"res_name": "[T0282] Renommage du numéro d'identification de certaines formules dans BCN",
|
||||
"creator_name": "OdooBot",
|
||||
"creator_id": 1,
|
||||
"download_status": "success",
|
||||
"local_path": "output/ticket_T0282/T0282_20250404_151451/attachments/Formules_Patebex_Cournanel.xls",
|
||||
"error": ""
|
||||
},
|
||||
{
|
||||
"id": 33751,
|
||||
"name": "formules bb lafarge.xls",
|
||||
"mimetype": "application/vnd.ms-excel",
|
||||
"file_size": 72192,
|
||||
"create_date": "2020-06-16 12:51:44",
|
||||
"create_uid": [
|
||||
1,
|
||||
"OdooBot"
|
||||
],
|
||||
"description": "formules bb lafarge.xls",
|
||||
"res_name": "[T0282] Renommage du numéro d'identification de certaines formules dans BCN",
|
||||
"creator_name": "OdooBot",
|
||||
"creator_id": 1,
|
||||
"download_status": "success",
|
||||
"local_path": "output/ticket_T0282/T0282_20250404_151451/attachments/formules_bb_lafarge.xls",
|
||||
"error": ""
|
||||
},
|
||||
{
|
||||
"id": 33750,
|
||||
"name": "Formules bac.xls",
|
||||
"mimetype": "application/vnd.ms-excel",
|
||||
"file_size": 58880,
|
||||
"create_date": "2020-06-16 12:51:44",
|
||||
"create_uid": [
|
||||
1,
|
||||
"OdooBot"
|
||||
],
|
||||
"description": "Formules bac.xls",
|
||||
"res_name": "[T0282] Renommage du numéro d'identification de certaines formules dans BCN",
|
||||
"creator_name": "OdooBot",
|
||||
"creator_id": 1,
|
||||
"download_status": "success",
|
||||
"local_path": "output/ticket_T0282/T0282_20250404_151451/attachments/Formules_bac.xls",
|
||||
"error": ""
|
||||
},
|
||||
{
|
||||
"id": 33748,
|
||||
"name": "blocked.gif",
|
||||
"mimetype": "image/gif",
|
||||
"file_size": 118,
|
||||
"create_date": "2020-06-16 12:51:44",
|
||||
"create_uid": [
|
||||
1,
|
||||
"OdooBot"
|
||||
],
|
||||
"description": "blocked.gif",
|
||||
"res_name": "[T0282] Renommage du numéro d'identification de certaines formules dans BCN",
|
||||
"creator_name": "OdooBot",
|
||||
"creator_id": 1,
|
||||
"download_status": "success",
|
||||
"local_path": "output/ticket_T0282/T0282_20250404_151451/attachments/blocked.gif",
|
||||
"error": ""
|
||||
},
|
||||
{
|
||||
"id": 33651,
|
||||
"name": "Formules Patebex Cournanel.xls",
|
||||
"mimetype": "application/vnd.ms-excel",
|
||||
"file_size": 72704,
|
||||
"create_date": "2020-06-11 15:57:20",
|
||||
"create_uid": [
|
||||
1,
|
||||
"OdooBot"
|
||||
],
|
||||
"description": "Formules Patebex Cournanel.xls",
|
||||
"res_name": "[T0282] Renommage du numéro d'identification de certaines formules dans BCN",
|
||||
"creator_name": "OdooBot",
|
||||
"creator_id": 1,
|
||||
"download_status": "success",
|
||||
"local_path": "output/ticket_T0282/T0282_20250404_151451/attachments/Formules_Patebex_Cournanel_1.xls",
|
||||
"error": ""
|
||||
},
|
||||
{
|
||||
"id": 33650,
|
||||
"name": "formules bb lafarge.xls",
|
||||
"mimetype": "application/vnd.ms-excel",
|
||||
"file_size": 72192,
|
||||
"create_date": "2020-06-11 15:57:20",
|
||||
"create_uid": [
|
||||
1,
|
||||
"OdooBot"
|
||||
],
|
||||
"description": "formules bb lafarge.xls",
|
||||
"res_name": "[T0282] Renommage du numéro d'identification de certaines formules dans BCN",
|
||||
"creator_name": "OdooBot",
|
||||
"creator_id": 1,
|
||||
"download_status": "success",
|
||||
"local_path": "output/ticket_T0282/T0282_20250404_151451/attachments/formules_bb_lafarge_1.xls",
|
||||
"error": ""
|
||||
},
|
||||
{
|
||||
"id": 33649,
|
||||
"name": "Formules bac.xls",
|
||||
"mimetype": "application/vnd.ms-excel",
|
||||
"file_size": 58880,
|
||||
"create_date": "2020-06-11 15:57:20",
|
||||
"create_uid": [
|
||||
1,
|
||||
"OdooBot"
|
||||
],
|
||||
"description": "Formules bac.xls",
|
||||
"res_name": "[T0282] Renommage du numéro d'identification de certaines formules dans BCN",
|
||||
"creator_name": "OdooBot",
|
||||
"creator_id": 1,
|
||||
"download_status": "success",
|
||||
"local_path": "output/ticket_T0282/T0282_20250404_151451/attachments/Formules_bac_1.xls",
|
||||
"error": ""
|
||||
}
|
||||
]
|
||||
9
output/ticket_T0282/T0282_20250404_151451/followers.json
Normal file
9
output/ticket_T0282/T0282_20250404_151451/followers.json
Normal file
@ -0,0 +1,9 @@
|
||||
[
|
||||
{
|
||||
"id": 11457,
|
||||
"partner_id": [
|
||||
424,
|
||||
"BRAM BETON"
|
||||
]
|
||||
}
|
||||
]
|
||||
659
output/ticket_T0282/T0282_20250404_151451/messages_raw.json
Normal file
659
output/ticket_T0282/T0282_20250404_151451/messages_raw.json
Normal file
File diff suppressed because one or more lines are too long
20
output/ticket_T0282/T0282_20250404_151451/structure.json
Normal file
20
output/ticket_T0282/T0282_20250404_151451/structure.json
Normal file
@ -0,0 +1,20 @@
|
||||
{
|
||||
"date_extraction": "2025-04-04T15:14:56.077117",
|
||||
"ticket_id": 294,
|
||||
"ticket_code": "T0282",
|
||||
"ticket_name": "Renommage du numéro d'identification de certaines formules dans BCN",
|
||||
"output_dir": "output/ticket_T0282/T0282_20250404_151451",
|
||||
"files": {
|
||||
"ticket_info": "ticket_info.json",
|
||||
"ticket_summary": "ticket_summary.json",
|
||||
"messages": "all_messages.json",
|
||||
"messages_raw": "messages_raw.json",
|
||||
"messages_text": "all_messages.txt",
|
||||
"attachments": "attachments_info.json",
|
||||
"followers": "followers.json"
|
||||
},
|
||||
"stats": {
|
||||
"messages_count": 17,
|
||||
"attachments_count": 8
|
||||
}
|
||||
}
|
||||
70
output/ticket_T0282/T0282_20250404_151451/ticket_info.json
Normal file
70
output/ticket_T0282/T0282_20250404_151451/ticket_info.json
Normal file
@ -0,0 +1,70 @@
|
||||
{
|
||||
"id": 294,
|
||||
"name": "Renommage du numéro d'identification de certaines formules dans BCN",
|
||||
"description": "<p>Souhaite renommer le numéro d'identification de certaines formules dans BCN<br></p>",
|
||||
"stage_id": [
|
||||
8,
|
||||
"Clôturé"
|
||||
],
|
||||
"project_id": [
|
||||
3,
|
||||
"Demandes"
|
||||
],
|
||||
"partner_id": [
|
||||
10370,
|
||||
"BRAM BETON, Elisabeth PATEBEX"
|
||||
],
|
||||
"user_id": [
|
||||
9,
|
||||
"Youness BENDEQ"
|
||||
],
|
||||
"date_start": "2020-05-28 15:01:30",
|
||||
"date_end": false,
|
||||
"date_deadline": false,
|
||||
"create_date": "2020-05-28 15:01:30",
|
||||
"write_date": "2024-10-03 13:10:50",
|
||||
"tag_ids": [
|
||||
12
|
||||
],
|
||||
"priority": "0",
|
||||
"email_from": "sarlpatebex@PATEBEX.COM",
|
||||
"email_cc": "",
|
||||
"message_ids": [
|
||||
17388,
|
||||
17387,
|
||||
16626,
|
||||
16612,
|
||||
16611,
|
||||
15349,
|
||||
13380,
|
||||
13379,
|
||||
13303,
|
||||
13277,
|
||||
13174,
|
||||
13170,
|
||||
12949,
|
||||
12756,
|
||||
12652,
|
||||
12651,
|
||||
12629,
|
||||
12628,
|
||||
12627,
|
||||
12528,
|
||||
12481,
|
||||
12480
|
||||
],
|
||||
"message_follower_ids": [
|
||||
11457
|
||||
],
|
||||
"timesheet_ids": [
|
||||
103
|
||||
],
|
||||
"attachment_ids": [],
|
||||
"stage_id_name": "Clôturé",
|
||||
"project_id_name": "Demandes",
|
||||
"partner_id_name": "BRAM BETON, Elisabeth PATEBEX",
|
||||
"user_id_name": "Youness BENDEQ",
|
||||
"tag_names": [
|
||||
"BCN"
|
||||
]
|
||||
}
|
||||
@ -0,0 +1,16 @@
|
||||
{
|
||||
"id": 294,
|
||||
"code": "T0282",
|
||||
"name": "Renommage du numéro d'identification de certaines formules dans BCN",
|
||||
"description": "<p>Souhaite renommer le numéro d'identification de certaines formules dans BCN<br></p>",
|
||||
"stage": "Clôturé",
|
||||
"project": "Demandes",
|
||||
"partner": "BRAM BETON, Elisabeth PATEBEX",
|
||||
"assigned_to": "Youness BENDEQ",
|
||||
"tags": [
|
||||
"BCN"
|
||||
],
|
||||
"create_date": "2020-05-28 15:01:30",
|
||||
"write_date": "2024-10-03 13:10:50",
|
||||
"deadline": false
|
||||
}
|
||||
@ -0,0 +1,33 @@
|
||||
{
|
||||
"id": "11046",
|
||||
"code": "T11067",
|
||||
"name": "changement nom centrale d'enrobage",
|
||||
"description": "*Aucune description fournie*",
|
||||
"project_name": "Demandes",
|
||||
"stage_name": "Clôturé",
|
||||
"user_id": "",
|
||||
"partner_id_email_from": "CONSEIL DEPARTEMENTAL DU MORBIHAN (56), Dominique CARVAL, CARVAL Dominique <dominique.carval@morbihan.fr>",
|
||||
"create_date": "18/03/2025 13:22:27",
|
||||
"write_date_last_modification": "02/04/2025 07:16:48",
|
||||
"date_deadline": "02/04/2025 00:00:00",
|
||||
"messages": [
|
||||
{
|
||||
"author_id": "Dominique CARVAL",
|
||||
"date": "18/03/2025 13:18:31",
|
||||
"message_type": "E-mail",
|
||||
"subject": "changement nom centrale d'enrobage",
|
||||
"id": "227725",
|
||||
"content": "Bonjour, \n\n3 centrales d’enrobage ont changé de nom.\n\nComment faire ce changement sur BRG-LAB ?\n\n(ici ARMOR ENROBÉS devient BREIZH ENROBÉS sur 3 sites)\n\nBonne réception\n\n\nDirection des Infrastructures et des mobilités (DIM)\n\nService d’Appui aux Politiques d’Aménagement / Pôle Laboratoire Routier (SAPA/PLR)\n\n115, rue du commerce – 56000 VANNES\n\n\n- image004.jpg (image/jpeg) [ID: 144794]\n- image003.png (image/png) [ID: 144792]\n\n---\n\n"
|
||||
},
|
||||
{
|
||||
"author_id": "Romuald GRUSON",
|
||||
"date": "18/03/2025 14:18:51",
|
||||
"message_type": "E-mail",
|
||||
"subject": "Re: [T11067] - changement nom centrale d'enrobage",
|
||||
"id": "227731",
|
||||
"content": "Bonjour,\n\nEffectivement, il y a une anomalie lors du changement du nom d'un poste de production. Les mises à jour déployées ce soir et demain devraient vous permettre d’effectuer cette modification.\n\nPour cela, il faut éditer le nom du poste de production d’enrobée, l’enregistrer dans la fiche générale, puis cliquer sur la petite flèche à droite du nom et le modifier.\n\nJe reste à votre entière disposition pour toute information complémentaire.\n\nCordialement,\n\n\\---\n\n- image.png (image/png) [ID: 144796]\n\n---\n"
|
||||
}
|
||||
],
|
||||
"date_d'extraction": "04/04/2025 15:17:13",
|
||||
"répertoire": "output/ticket_T11067/T11067_20250404_151710"
|
||||
}
|
||||
@ -0,0 +1,80 @@
|
||||
# Ticket T11067: changement nom centrale d'enrobage
|
||||
|
||||
## Informations du ticket
|
||||
|
||||
- **id**: 11046
|
||||
- **code**: T11067
|
||||
- **name**: changement nom centrale d'enrobage
|
||||
- **project_name**: Demandes
|
||||
- **stage_name**: Clôturé
|
||||
- **user_id**:
|
||||
- **partner_id/email_from**: CONSEIL DEPARTEMENTAL DU MORBIHAN (56), Dominique CARVAL, CARVAL Dominique <dominique.carval@morbihan.fr>
|
||||
- **create_date**: 18/03/2025 13:22:27
|
||||
- **write_date/last modification**: 02/04/2025 07:16:48
|
||||
- **date_deadline**: 02/04/2025 00:00:00
|
||||
|
||||
- **description**:
|
||||
|
||||
*Aucune description fournie*
|
||||
|
||||
## Messages
|
||||
|
||||
### Message 1
|
||||
**author_id**: Dominique CARVAL
|
||||
**date**: 18/03/2025 13:18:31
|
||||
**message_type**: E-mail
|
||||
**subject**: changement nom centrale d'enrobage
|
||||
**id**: 227725
|
||||
Bonjour,
|
||||
|
||||
3 centrales d’enrobage ont changé de nom.
|
||||
|
||||
Comment faire ce changement sur BRG-LAB ?
|
||||
|
||||
(ici ARMOR ENROBÉS devient BREIZH ENROBÉS sur 3 sites)
|
||||
|
||||
Bonne réception
|
||||
|
||||
**Dominique CARVAL
|
||||
|
||||
Direction des Infrastructures et des mobilités (DIM)
|
||||
|
||||
Service d’Appui aux Politiques d’Aménagement / Pôle Laboratoire Routier (SAPA/PLR)
|
||||
|
||||
115, rue du commerce – 56000 VANNES
|
||||
|
||||
**tél : 02 97 54 71 14 - mobile : 06 98 32 88 30 –
|
||||
|
||||
**attachment_ids**:
|
||||
- image004.jpg (image/jpeg) [ID: 144794]
|
||||
- image003.png (image/png) [ID: 144792]
|
||||
|
||||
---
|
||||
|
||||
### Message 2
|
||||
**author_id**: Romuald GRUSON
|
||||
**date**: 18/03/2025 14:18:51
|
||||
**message_type**: E-mail
|
||||
**subject**: Re: [T11067] - changement nom centrale d'enrobage
|
||||
**id**: 227731
|
||||
Bonjour,
|
||||
|
||||
Effectivement, il y a une anomalie lors du changement du nom d'un poste de production. Les mises à jour déployées ce soir et demain devraient vous permettre d’effectuer cette modification.
|
||||
|
||||
Pour cela, il faut éditer le nom du poste de production d’enrobée, l’enregistrer dans la fiche générale, puis cliquer sur la petite flèche à droite du nom et le modifier.
|
||||
|
||||
Je reste à votre entière disposition pour toute information complémentaire.
|
||||
|
||||
Cordialement,
|
||||
|
||||
\---
|
||||
|
||||
**attachment_ids**:
|
||||
- image.png (image/png) [ID: 144796]
|
||||
|
||||
---
|
||||
|
||||
## Informations sur l'extraction
|
||||
|
||||
- **Date d'extraction**: 04/04/2025 15:17:13
|
||||
- **Répertoire**: output/ticket_T11067/T11067_20250404_151710
|
||||
272
output/ticket_T11067/T11067_20250404_151710/all_messages.json
Normal file
272
output/ticket_T11067/T11067_20250404_151710/all_messages.json
Normal file
File diff suppressed because one or more lines are too long
148
output/ticket_T11067/T11067_20250404_151710/all_messages.txt
Normal file
148
output/ticket_T11067/T11067_20250404_151710/all_messages.txt
Normal file
File diff suppressed because one or more lines are too long
Binary file not shown.
|
After Width: | Height: | Size: 45 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 5.3 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 62 KiB |
@ -0,0 +1,56 @@
|
||||
[
|
||||
{
|
||||
"id": 144796,
|
||||
"name": "image.png",
|
||||
"mimetype": "image/png",
|
||||
"file_size": 45686,
|
||||
"create_date": "2025-03-18 14:18:51",
|
||||
"create_uid": [
|
||||
32,
|
||||
"Romuald GRUSON"
|
||||
],
|
||||
"description": false,
|
||||
"res_name": "[T11067] changement nom centrale d'enrobage",
|
||||
"creator_name": "Romuald GRUSON",
|
||||
"creator_id": 32,
|
||||
"download_status": "success",
|
||||
"local_path": "output/ticket_T11067/T11067_20250404_151710/attachments/image.png",
|
||||
"error": ""
|
||||
},
|
||||
{
|
||||
"id": 144794,
|
||||
"name": "image004.jpg",
|
||||
"mimetype": "image/jpeg",
|
||||
"file_size": 63295,
|
||||
"create_date": "2025-03-18 13:22:27",
|
||||
"create_uid": [
|
||||
1,
|
||||
"OdooBot"
|
||||
],
|
||||
"description": "image004.jpg",
|
||||
"res_name": "[T11067] changement nom centrale d'enrobage",
|
||||
"creator_name": "OdooBot",
|
||||
"creator_id": 1,
|
||||
"download_status": "success",
|
||||
"local_path": "output/ticket_T11067/T11067_20250404_151710/attachments/image004.jpg",
|
||||
"error": ""
|
||||
},
|
||||
{
|
||||
"id": 144792,
|
||||
"name": "image003.png",
|
||||
"mimetype": "image/png",
|
||||
"file_size": 5417,
|
||||
"create_date": "2025-03-18 13:22:27",
|
||||
"create_uid": [
|
||||
1,
|
||||
"OdooBot"
|
||||
],
|
||||
"description": "image003.png",
|
||||
"res_name": "[T11067] changement nom centrale d'enrobage",
|
||||
"creator_name": "OdooBot",
|
||||
"creator_id": 1,
|
||||
"download_status": "success",
|
||||
"local_path": "output/ticket_T11067/T11067_20250404_151710/attachments/image003.png",
|
||||
"error": ""
|
||||
}
|
||||
]
|
||||
23
output/ticket_T11067/T11067_20250404_151710/followers.json
Normal file
23
output/ticket_T11067/T11067_20250404_151710/followers.json
Normal file
@ -0,0 +1,23 @@
|
||||
[
|
||||
{
|
||||
"id": 89590,
|
||||
"partner_id": [
|
||||
28961,
|
||||
"Fabien LAFAY"
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": 89592,
|
||||
"partner_id": [
|
||||
32165,
|
||||
"Romuald GRUSON"
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": 89593,
|
||||
"partner_id": [
|
||||
5144,
|
||||
"CONSEIL DEPARTEMENTAL DU MORBIHAN (56), Dominique CARVAL"
|
||||
]
|
||||
}
|
||||
]
|
||||
275
output/ticket_T11067/T11067_20250404_151710/messages_raw.json
Normal file
275
output/ticket_T11067/T11067_20250404_151710/messages_raw.json
Normal file
File diff suppressed because one or more lines are too long
@ -1,9 +1,9 @@
|
||||
{
|
||||
"date_extraction": "2025-04-04T11:49:08.507801",
|
||||
"ticket_id": 179,
|
||||
"ticket_code": "T0167",
|
||||
"ticket_name": "Pb d'affaire/chantier/partie dans un programme d'essai",
|
||||
"output_dir": "output/ticket_T0167/T0167_20250404_114905",
|
||||
"date_extraction": "2025-04-04T15:17:13.313765",
|
||||
"ticket_id": 11046,
|
||||
"ticket_code": "T11067",
|
||||
"ticket_name": "changement nom centrale d'enrobage",
|
||||
"output_dir": "output/ticket_T11067/T11067_20250404_151710",
|
||||
"files": {
|
||||
"ticket_info": "ticket_info.json",
|
||||
"ticket_summary": "ticket_summary.json",
|
||||
@ -14,7 +14,7 @@
|
||||
"followers": "followers.json"
|
||||
},
|
||||
"stats": {
|
||||
"messages_count": 5,
|
||||
"attachments_count": 2
|
||||
"messages_count": 6,
|
||||
"attachments_count": 3
|
||||
}
|
||||
}
|
||||
57
output/ticket_T11067/T11067_20250404_151710/ticket_info.json
Normal file
57
output/ticket_T11067/T11067_20250404_151710/ticket_info.json
Normal file
@ -0,0 +1,57 @@
|
||||
{
|
||||
"id": 11046,
|
||||
"name": "changement nom centrale d'enrobage",
|
||||
"description": "<p><br></p>",
|
||||
"stage_id": [
|
||||
8,
|
||||
"Clôturé"
|
||||
],
|
||||
"project_id": [
|
||||
3,
|
||||
"Demandes"
|
||||
],
|
||||
"partner_id": [
|
||||
5144,
|
||||
"CONSEIL DEPARTEMENTAL DU MORBIHAN (56), Dominique CARVAL"
|
||||
],
|
||||
"user_id": [
|
||||
32,
|
||||
"Romuald GRUSON"
|
||||
],
|
||||
"date_start": "2025-03-18 13:22:28",
|
||||
"date_end": false,
|
||||
"date_deadline": "2025-04-02",
|
||||
"create_date": "2025-03-18 13:22:27",
|
||||
"write_date": "2025-04-02 07:16:48",
|
||||
"tag_ids": [
|
||||
15
|
||||
],
|
||||
"priority": "0",
|
||||
"email_from": "CARVAL Dominique <dominique.carval@morbihan.fr>",
|
||||
"email_cc": "",
|
||||
"message_ids": [
|
||||
228803,
|
||||
227733,
|
||||
227732,
|
||||
227731,
|
||||
227730,
|
||||
227728,
|
||||
227726,
|
||||
227725,
|
||||
227724
|
||||
],
|
||||
"message_follower_ids": [
|
||||
89590,
|
||||
89592,
|
||||
89593
|
||||
],
|
||||
"timesheet_ids": [],
|
||||
"attachment_ids": [],
|
||||
"stage_id_name": "Clôturé",
|
||||
"project_id_name": "Demandes",
|
||||
"partner_id_name": "CONSEIL DEPARTEMENTAL DU MORBIHAN (56), Dominique CARVAL",
|
||||
"user_id_name": "Romuald GRUSON",
|
||||
"tag_names": [
|
||||
"BRG-LAB WEB"
|
||||
]
|
||||
}
|
||||
@ -0,0 +1,16 @@
|
||||
{
|
||||
"id": 11046,
|
||||
"code": "T11067",
|
||||
"name": "changement nom centrale d'enrobage",
|
||||
"description": "<p><br></p>",
|
||||
"stage": "Clôturé",
|
||||
"project": "Demandes",
|
||||
"partner": "CONSEIL DEPARTEMENTAL DU MORBIHAN (56), Dominique CARVAL",
|
||||
"assigned_to": "Romuald GRUSON",
|
||||
"tags": [
|
||||
"BRG-LAB WEB"
|
||||
],
|
||||
"create_date": "2025-03-18 13:22:27",
|
||||
"write_date": "2025-04-02 07:16:48",
|
||||
"deadline": "2025-04-02"
|
||||
}
|
||||
Binary file not shown.
Binary file not shown.
@ -18,6 +18,14 @@ def clean_html(html_content, is_description=False):
|
||||
if not html_content:
|
||||
return ""
|
||||
|
||||
# NOUVEAU: Supprimer directement tout le texte après un crochet isolé suivi d'une ligne vide
|
||||
# Cette méthode plus directe devrait capturer le cas du ticket T0282
|
||||
isolated_bracket_pattern = r'\n\s*\[\s*\n\s*\n'
|
||||
bracket_match = re.search(isolated_bracket_pattern, html_content)
|
||||
if bracket_match:
|
||||
# Prendre uniquement la partie avant le crochet isolé
|
||||
html_content = html_content[:bracket_match.start()].strip()
|
||||
|
||||
# Traitement spécifique pour les descriptions
|
||||
if is_description:
|
||||
# Suppression complète des balises font et autres balises de formatage
|
||||
@ -42,16 +50,58 @@ def clean_html(html_content, is_description=False):
|
||||
|
||||
# Traitement spécifique pour les messages transférés
|
||||
if "\\-------- Message transféré --------" in html_content:
|
||||
# Essayer d'extraire le contenu principal entre "Bonjour" et le disclaimer
|
||||
# Le code existant reste inchangé
|
||||
match = re.search(r'Bonjour.*?(?=\n\s*_+Ce message)', html_content, re.DOTALL)
|
||||
if match:
|
||||
html_content = match.group(0).strip()
|
||||
else:
|
||||
# Si ce pattern ne fonctionne pas, essayer une approche plus générale
|
||||
match = re.search(r'Copie à :.*?\n\s*\n(.*?)(?=\n\s*_+|\Z)', html_content, re.DOTALL)
|
||||
if match:
|
||||
html_content = match.group(1).strip()
|
||||
|
||||
# Traitement spécifique pour les notifications d'appel
|
||||
if "Notification d'appel" in html_content:
|
||||
# Le code existant reste inchangé
|
||||
match = re.search(r'(?:Sujet d\'appel:[^\n]*\n[^\n]*\n[^\n]*\n[^\n]*\n)[^\n]*\n[^\n]*([^|]+)', html_content, re.DOTALL)
|
||||
if match:
|
||||
message_content = match.group(1).strip()
|
||||
# Construire un message formaté avec les informations essentielles
|
||||
infos = {}
|
||||
date_match = re.search(r'Date:.*?\|(.*?)(?:\n|$)', html_content)
|
||||
appelant_match = re.search(r'\*\*Appel de:\*\*.*?\|(.*?)(?:\n|$)', html_content)
|
||||
telephone_match = re.search(r'Téléphone principal:.*?\|(.*?)(?:\n|$)', html_content)
|
||||
mobile_match = re.search(r'Mobile:.*?\|(.*?)(?:\n|$)', html_content)
|
||||
sujet_match = re.search(r'Sujet d\'appel:.*?\|(.*?)(?:\n|$)', html_content)
|
||||
|
||||
if date_match:
|
||||
infos["date"] = date_match.group(1).strip()
|
||||
if appelant_match:
|
||||
infos["appelant"] = appelant_match.group(1).strip()
|
||||
if telephone_match:
|
||||
infos["telephone"] = telephone_match.group(1).strip()
|
||||
if mobile_match:
|
||||
infos["mobile"] = mobile_match.group(1).strip()
|
||||
if sujet_match:
|
||||
infos["sujet"] = sujet_match.group(1).strip()
|
||||
|
||||
# Construire le message formaté
|
||||
formatted_message = f"**Notification d'appel**\n\n"
|
||||
if "appelant" in infos:
|
||||
formatted_message += f"De: {infos['appelant']}\n"
|
||||
if "date" in infos:
|
||||
formatted_message += f"Date: {infos['date']}\n"
|
||||
if "telephone" in infos:
|
||||
formatted_message += f"Téléphone: {infos['telephone']}\n"
|
||||
if "mobile" in infos:
|
||||
formatted_message += f"Mobile: {infos['mobile']}\n"
|
||||
if "sujet" in infos:
|
||||
formatted_message += f"Sujet: {infos['sujet']}\n\n"
|
||||
|
||||
formatted_message += f"Message: {message_content}"
|
||||
|
||||
html_content = formatted_message
|
||||
|
||||
# Le reste du code reste inchangé
|
||||
# Transformer les balises h1 en titres Markdown
|
||||
html_content = re.sub(r'<h1>(.*?)</h1>', r'### \1', html_content)
|
||||
|
||||
@ -67,7 +117,8 @@ def clean_html(html_content, is_description=False):
|
||||
html_content = re.sub(r'Droit à la déconnexion :.*?(?=\n\n|\Z)', '', html_content, flags=re.DOTALL)
|
||||
html_content = re.sub(r'\*\s*\*\s*\*.*?(?=\n\n|\Z)', '', html_content, flags=re.DOTALL)
|
||||
html_content = re.sub(r'Ce message électronique et tous les fichiers.*?(?=\n\n|\Z)', '', html_content, flags=re.DOTALL)
|
||||
html_content = re.sub(r'Afin d\'assurer une meilleure traçabilité.*?(?=\n\n|\Z)', '', html_content, flags=re.DOTALL)
|
||||
html_content = re.sub(r'Afin d\'assurer une meilleure traçabilité.*?(?=\n\n|\Z)', '', html_content, flags=re.IGNORECASE | re.DOTALL)
|
||||
html_content = re.sub(r'Affin d\'assurer une meilleure traçabilité.*?(?=\n\n|\Z)', '', html_content, flags=re.IGNORECASE | re.DOTALL)
|
||||
html_content = re.sub(r'_Confidentialité :.*?(?=\n\n|\Z)', '', html_content, flags=re.DOTALL)
|
||||
html_content = re.sub(r'Support technique.*?(?=\n\n|\Z)', '', html_content, flags=re.DOTALL)
|
||||
|
||||
@ -95,6 +146,7 @@ def clean_html(html_content, is_description=False):
|
||||
|
||||
# Supprimer les crochets isolés
|
||||
html_content = re.sub(r'\[\s*$', '', html_content)
|
||||
html_content = re.sub(r'^\s*\[\s*$', '', html_content, flags=re.MULTILINE)
|
||||
|
||||
# Supprimer les lignes vides multiples
|
||||
html_content = re.sub(r'\n\s*\n', '\n\n', html_content)
|
||||
@ -112,6 +164,7 @@ def format_date(date_str):
|
||||
"""
|
||||
Formate une date ISO en format lisible.
|
||||
"""
|
||||
# Code inchangé
|
||||
if not date_str:
|
||||
return ""
|
||||
|
||||
@ -122,7 +175,7 @@ def format_date(date_str):
|
||||
return date_str
|
||||
|
||||
if __name__ == "__main__":
|
||||
# Test simple
|
||||
# Tests
|
||||
html = """<p>Bonjour,</p>
|
||||
<p>Voici un message avec <b>du HTML</b> et une signature.</p>
|
||||
<p>Cordialement,</p>
|
||||
@ -154,4 +207,22 @@ Test User
|
||||
__________________________________________________________________ Ce message et toutes les pièces jointes sont confidentiels et établis à l'intention exclusive de ses destinataires. __________________________________________________________________"""
|
||||
|
||||
cleaned_forwarded = clean_html(forwarded)
|
||||
print("\nMessage transféré nettoyé :\n", cleaned_forwarded)
|
||||
print("\nMessage transféré nettoyé :\n", cleaned_forwarded)
|
||||
|
||||
# Test avec le cas problématique du ticket T0282
|
||||
test_t0282 = """Bonjour,
|
||||
|
||||
Je reviens vers vous pour savoir si vous souhaitez toujours renommer le numéro d'identification de certaines formules dans BCN ou si vous avez trouvé une solution alternative ?
|
||||
|
||||
En vous remerciant par avance, je reste à votre disposition pour tout complément d'information.
|
||||
|
||||
Cordialement.
|
||||
|
||||
**Youness BENDEQ**
|
||||
|
||||
[
|
||||
|
||||
Affin d'assurer une meilleure traçabilité et vous garantir une prise en charge optimale, nous vous invitons à envoyer vos demandes d'assistance technique à support@cbao.fr Notre service est ouvert du lundi au vendredi de 9h à 12h et de 14h à 18h. Dès réception, un technicien prendra en charge votre demande et au besoin vous rappellera."""
|
||||
|
||||
cleaned_t0282 = clean_html(test_t0282)
|
||||
print("\nTest ticket T0282 nettoyé :\n", cleaned_t0282)
|
||||
@ -9,6 +9,7 @@ import sys
|
||||
import json
|
||||
import argparse
|
||||
import html
|
||||
import subprocess
|
||||
from datetime import datetime
|
||||
import importlib
|
||||
import utils.clean_html
|
||||
@ -23,15 +24,26 @@ def create_markdown_from_json(json_file, output_file):
|
||||
json_file: Chemin vers le fichier JSON contenant les messages
|
||||
output_file: Chemin du fichier Markdown à créer
|
||||
"""
|
||||
# Obtenir le répertoire du ticket pour accéder aux autres fichiers
|
||||
ticket_dir = os.path.dirname(json_file)
|
||||
|
||||
ticket_summary = {}
|
||||
try:
|
||||
with open(json_file, 'r', encoding='utf-8') as f:
|
||||
data = json.load(f)
|
||||
ticket_summary = data.get("ticket_summary", {})
|
||||
except Exception as e:
|
||||
print(f"Erreur : {e}")
|
||||
return False
|
||||
|
||||
# Obtenir le répertoire du ticket pour accéder aux autres fichiers
|
||||
ticket_dir = os.path.dirname(json_file)
|
||||
ticket_code = ticket_summary.get("code", "inconnu")
|
||||
|
||||
# Créer le dossier rapports si il n'existe pas
|
||||
reports_dir = os.path.join(ticket_dir, f"{ticket_code}_rapports")
|
||||
os.makedirs(reports_dir, exist_ok=True)
|
||||
|
||||
output_file = os.path.join(reports_dir, f"{ticket_code}_rapport.md")
|
||||
json_output_file = os.path.join(reports_dir, f"{ticket_code}_rapport.json")
|
||||
|
||||
# Essayer de lire le fichier ticket_info.json si disponible
|
||||
ticket_info = {}
|
||||
@ -55,8 +67,6 @@ def create_markdown_from_json(json_file, output_file):
|
||||
ticket_summary = json.load(f)
|
||||
except Exception as e:
|
||||
print(f"Avertissement: Impossible de lire ticket_summary.json: {e}")
|
||||
|
||||
output_file = f"{ticket_dir}/{ticket_summary.get('code', 'rapport')}_rapport.md"
|
||||
|
||||
# Tenter de lire le fichier structure.json
|
||||
structure = {}
|
||||
@ -327,6 +337,9 @@ def create_markdown_from_json(json_file, output_file):
|
||||
with open(output_file, 'w', encoding='utf-8') as f:
|
||||
f.write("\n".join(md_content))
|
||||
print(f"Rapport Markdown créé : {output_file}")
|
||||
# Appeler le script markdown_to_json.py
|
||||
subprocess.run(['python', 'utils/markdown_to_json.py', output_file, json_output_file], check=True)
|
||||
print(f"Fichier JSON créé : {json_output_file}")
|
||||
return True
|
||||
except Exception as e:
|
||||
print(f"Erreur lors de l'écriture du fichier Markdown: {e}")
|
||||
|
||||
161
utils/markdown_to_json.py
Normal file
161
utils/markdown_to_json.py
Normal file
@ -0,0 +1,161 @@
|
||||
import os
|
||||
import re
|
||||
import json
|
||||
import sys
|
||||
|
||||
def parse_markdown(md_content):
|
||||
data = {}
|
||||
|
||||
# Diviser le contenu en sections
|
||||
sections = re.split(r"\n## ", md_content)
|
||||
|
||||
# Traiter chaque section
|
||||
for section in sections:
|
||||
if section.startswith("Informations du ticket"):
|
||||
ticket_info = parse_ticket_info(section)
|
||||
data.update(ticket_info)
|
||||
elif section.startswith("Messages"):
|
||||
messages = parse_messages(section)
|
||||
data["messages"] = messages
|
||||
elif section.startswith("Informations sur l'extraction"):
|
||||
extraction_info = parse_extraction_info(section)
|
||||
data.update(extraction_info)
|
||||
|
||||
# Réorganiser les champs pour que la description soit après "name"
|
||||
ordered_fields = ["id", "code", "name", "description"]
|
||||
ordered_data = {}
|
||||
|
||||
# D'abord ajouter les champs dans l'ordre spécifié
|
||||
for field in ordered_fields:
|
||||
if field in data:
|
||||
ordered_data[field] = data[field]
|
||||
|
||||
# Ensuite ajouter les autres champs
|
||||
for key, value in data.items():
|
||||
if key not in ordered_data:
|
||||
ordered_data[key] = value
|
||||
|
||||
return ordered_data
|
||||
|
||||
def parse_ticket_info(section):
|
||||
info = {}
|
||||
description = []
|
||||
capturing_description = False
|
||||
|
||||
lines = section.strip().split("\n")
|
||||
i = 0
|
||||
while i < len(lines):
|
||||
line = lines[i]
|
||||
|
||||
# Si on est déjà en train de capturer la description
|
||||
if capturing_description:
|
||||
# Vérifie si on atteint une nouvelle section ou un nouveau champ
|
||||
if i + 1 < len(lines) and (lines[i + 1].startswith("## ") or lines[i + 1].startswith("- **")):
|
||||
capturing_description = False
|
||||
info["description"] = "\n".join(description).strip()
|
||||
else:
|
||||
description.append(line)
|
||||
i += 1
|
||||
continue
|
||||
|
||||
# Détecte le début de la description
|
||||
desc_match = re.match(r"- \*\*description\*\*:", line)
|
||||
if desc_match:
|
||||
capturing_description = True
|
||||
i += 1 # Passe à la ligne suivante
|
||||
continue
|
||||
|
||||
# Traite les autres champs normalement
|
||||
match = re.match(r"- \*\*(.*?)\*\*: (.*)", line)
|
||||
if match:
|
||||
key, value = match.groups()
|
||||
key = key.lower().replace("/", "_").replace(" ", "_")
|
||||
info[key] = value.strip()
|
||||
|
||||
i += 1
|
||||
|
||||
# Si on finit en capturant la description, l'ajouter au dictionnaire
|
||||
if capturing_description and description:
|
||||
info["description"] = "\n".join(description).strip()
|
||||
elif "description" not in info:
|
||||
info["description"] = ""
|
||||
|
||||
return info
|
||||
|
||||
def parse_messages(section):
|
||||
messages = []
|
||||
current_message = {}
|
||||
in_message = False
|
||||
|
||||
lines = section.strip().split("\n")
|
||||
|
||||
for line in lines:
|
||||
if line.startswith("### Message"):
|
||||
if current_message:
|
||||
messages.append(current_message)
|
||||
current_message = {}
|
||||
in_message = True
|
||||
|
||||
elif line.startswith("**") and in_message:
|
||||
match = re.match(r"\*\*(.*?)\*\*: (.*)", line)
|
||||
if match:
|
||||
key, value = match.groups()
|
||||
key = key.lower().replace("/", "_").replace(" ", "_")
|
||||
current_message[key] = value.strip()
|
||||
else:
|
||||
if in_message:
|
||||
current_message["content"] = current_message.get("content", "") + line + "\n"
|
||||
|
||||
if current_message:
|
||||
messages.append(current_message)
|
||||
|
||||
return messages
|
||||
|
||||
|
||||
def parse_extraction_info(section):
|
||||
extraction_info = {}
|
||||
|
||||
lines = section.strip().split("\n")
|
||||
for line in lines:
|
||||
match = re.match(r"- \*\*(.*?)\*\*: (.*)", line)
|
||||
if match:
|
||||
key, value = match.groups()
|
||||
key = key.lower().replace("/", "_").replace(" ", "_")
|
||||
extraction_info[key] = value.strip()
|
||||
|
||||
return extraction_info
|
||||
|
||||
|
||||
def convert_markdown_to_json(md_file_path, output_file_path):
|
||||
with open(md_file_path, 'r', encoding='utf-8') as f:
|
||||
md_content = f.read()
|
||||
|
||||
data = parse_markdown(md_content)
|
||||
|
||||
# S'assurer que la description est présente
|
||||
if "description" not in data:
|
||||
# Trouver l'index de "name" pour insérer la description après
|
||||
if "name" in data:
|
||||
ordered_data = {}
|
||||
for key, value in data.items():
|
||||
ordered_data[key] = value
|
||||
if key == "name":
|
||||
ordered_data["description"] = ""
|
||||
data = ordered_data
|
||||
else:
|
||||
data["description"] = ""
|
||||
|
||||
with open(output_file_path, 'w', encoding='utf-8') as f:
|
||||
json.dump(data, f, indent=4, ensure_ascii=False)
|
||||
|
||||
print(f"Conversion terminée. Fichier JSON créé : {output_file_path}")
|
||||
|
||||
if __name__ == "__main__":
|
||||
if len(sys.argv) < 3:
|
||||
print("Utilisation : python markdown_to_json.py <fichier_markdown.md> <fichier_sortie.json>")
|
||||
sys.exit(1)
|
||||
|
||||
md_file = sys.argv[1]
|
||||
output_file = sys.argv[2]
|
||||
|
||||
convert_markdown_to_json(md_file, output_file)
|
||||
Loading…
x
Reference in New Issue
Block a user