feat: standardise customer name as PT. PRIMAFOOD INTERNATIONAL and update report

This commit is contained in:
Rafhan Mazaya Fathurrahman committed 2026-07-02 16:48:09 +07:00
1 parent 6666ecd599
commit acd8fb4295
3 files changed
+16 -4

No files matched your search

+13 -1
View File
@@ -12,6 +12,7 @@ def main():
target_store = "PX HEAD OFFICE ANCOL"
target_alamat = "JL. ANCOL BARAT VIII/1 KEL. ANCOL, KEC. PADEMANGAN JAKARTA UTARA, DKI JAKARTA"
target_customer = "PT. PRIMAFOOD INTERNATIONAL"
fixed_count = 0
for mf in manual_files:
@@ -19,15 +20,26 @@ def main():
with open(mf, "r") as f:
data = json.load(f)
is_modified = False
# Fix customer
current_customer = data.get("customer", "")
if current_customer != target_customer:
data["customer"] = target_customer
is_modified = True
# Fix store
store = data.get("store", "")
if store == "DKI AREA":
data["store"] = target_store
data["alamat"] = target_alamat
is_modified = True
if is_modified:
with open(mf, "w", encoding="utf-8") as f:
json.dump(data, f, indent=2, ensure_ascii=False)
print(f"Fixed store & address in manual label: {mf}")
print(f"Updated manual label: {mf}")
fixed_count += 1
except Exception as e:
print(f"Error updating {mf}: {e}")
Binary file not shown.
+3 -3
View File
@@ -5,7 +5,7 @@
"noSO": "1691960321",
"noDO": "1659980277",
"tanggal": "23 June 2026",
"customer": "",
"customer": "PT. PRIMAFOOD INTERNATIONAL",
"store": "PX HEAD OFFICE ANCOL",
"alamat": "JL. ANCOL BARAT VIII/1 KEL. ANCOL, KEC. PADEMANGAN JAKARTA UTARA, DKI JAKARTA",
"plat": "B 9427 UXT",
@@ -157,7 +157,7 @@
"kodeBarang": "21002601",
"namaBarang": "Prima Nasi Spicy Chick Sambal Geprek COPY",
"banyak": "1 80X",
"jumlah": "6 PAC✓"
"jumlah": "6 PAC✓"
}
]
},
@@ -443,7 +443,7 @@
"kodeBarang": "11048000",
"namaBarang": "BEBEK PARTING-NEW(*)",
"banyak": "2 BOX",
"jumlah": "30 PAC ✓"
"jumlah": "30 PAC ✓"
}
]
},