diff --git a/dl_version b/dl_version index d60a5ce..8384664 100644 --- a/dl_version +++ b/dl_version @@ -1 +1 @@ -20230124-1547 \ No newline at end of file +20230124-1611 \ No newline at end of file diff --git a/main.py b/main.py index 80f0c9f..1ef4da9 100644 --- a/main.py +++ b/main.py @@ -1,4 +1,5 @@ import csv +import re import json import os import logging @@ -354,7 +355,8 @@ class ClercAttrib2Biz(): if data.data["comments"] is not None: data.data["comments"] = data.data["comments"].strip().replace("\n",'') if data.Debtor["code"] is not None: - data.Debtor["code"] = data.Debtor["code"].strip().replace("'","").replace("*","") + data.Debtor["code"] = data.Debtor["code"].strip() + data.Debtor["code"] = re.sub(r'[^0-9]', '', data.Debtor["code"]) if "name" in data.Debtor.keys() and data.Debtor["name"] is not None: data.Debtor["name"] = data.Debtor["name"].replace("(facturation)","") diff --git a/version.py b/version.py index 5c92898..b5bf805 100644 --- a/version.py +++ b/version.py @@ -1 +1 @@ -VERSION = "20230124-1547" \ No newline at end of file +VERSION = "20230124-1611" \ No newline at end of file