diff --git a/edi_867_to_table.py b/edi_867_to_table.py index fad8b5d..815467e 100644 --- a/edi_867_to_table.py +++ b/edi_867_to_table.py @@ -193,6 +193,16 @@ X3_CUSTOMER_MAPPING = { 'SOBE1000_SB0029' : 'SOBE0010', 'SOBE1000_SB0024' : 'SOBE0011', 'SOBE1000_SB0092' : 'SOBE0012', + 'GTWH1000_GTJOHN' : 'GIAN0004', + 'AVRI1000_0000' : 'AVRI0003', + 'SOBE1000_SB0002' :'SOBE0014', + 'SOBE1000_SB0023' : 'SOBE0013', + 'SAMP1000_WELL1' : 'YARI0001', + 'SAMP1000_WELL2' : 'YARI0001', + 'LOND1000_0000' : 'LOND0001', + 'VEND1000_VENDAB' : 'VEND0002', + 'ISLA1000_190132' : 'ISLA0005', + 'PURI1000_0000' : 'PURI0002', } def main(): @@ -203,7 +213,7 @@ def main(): if SOURCE_867_FILENAME_RE.match(edi_filename.name): process_file(edi_filename) shutil.copy(edi_filename, EDI_997_DIRECTORY / edi_filename.name) - shutil.move(edi_filename, THIS_DIRECTORY / "processed_867s" / edi_filename.name) #They go in here so we can use them in the dashboard script + shutil.move(edi_filename, THIS_DIRECTORY / "processed_867s" / edi_filename.name) #They go in here so we can use them in the dashboard script, 2024-08 dashboard no longer needed def missing_customer_alert(customer_key): diff --git a/edi_947.py b/edi_947.py index 7f281a8..b748f95 100644 --- a/edi_947.py +++ b/edi_947.py @@ -139,7 +139,7 @@ def gtin_lookup(gtin): on [ITM].[ITMREF_0] = [ITF].[ITMREF_0] and [ITF].[STOFCY_0] = 'WON' where - [ITM].[ZCASEUPC_0] = :zcaseupc + replace([ITM].[ZCASEUPC_0],' ','') = :zcaseupc """, zcaseupc=gtin, ).first()["ITMREF_0"]