we are so back

This commit is contained in:
2025-05-05 14:05:12 -04:00
parent 11aa4cda16
commit 5c85411c69
20 changed files with 2417 additions and 33 deletions

View File

@ -772,7 +772,7 @@ class DataInitializationService(BaseService):
transaction = await inventory_service.create_purchase_transaction(db, PurchaseTransactionCreate(
vendor_id=vendor.id,
transaction_date=datetime.now(),
items=[PurchaseItem(product_id=619645, unit_price=100, quantity=1, is_case=False)],
items=[PurchaseItem(product_id=619645, unit_price=100, quantity=1, item_type="box")],
transaction_notes="tdm real box test"
#PurchaseItem(product_id=562119, unit_price=800.01, quantity=2, is_case=True, num_boxes=6)],
#transaction_notes="Test Transaction: 1 case and 2 boxes of foundations"
@ -784,7 +784,7 @@ class DataInitializationService(BaseService):
if item.inventory_item.physical_item.item_type == "box":
manabox_service = self.get_service("manabox")
#file_path = 'app/data/test_data/manabox_test_file.csv'
file_path = 'app/data/test_data/tdmtest.csv'
file_path = 'app/data/test_data/dragon.csv'
file_bytes = open(file_path, 'rb').read()
manabox_file = await manabox_service.process_manabox_csv(db, file_bytes, {"source": "test", "description": "test"}, wait=True)
# Ensure manabox_file is a list before passing it