Skip to content

Commit fbf9393

Browse files
committed
model method for change batch qty now raise commands hmmm
1 parent 27c2e48 commit fbf9393

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎src/allocation/domain/model.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
from dataclasses import dataclass
33
from datetime import date
44
from typing import Optional, List, Set
5-
from . import events
5+
from . import commands, events
66

77

88
class Product:
@@ -31,7 +31,7 @@ def change_batch_quantity(self, ref: str, qty: int):
3131
while batch.available_quantity < 0:
3232
line = batch.deallocate_one()
3333
self.events.append(
34-
events.AllocationRequired(line.orderid, line.sku, line.qty)
34+
commands.Allocate(line.orderid, line.sku, line.qty)
3535
)
3636

3737
@dataclass(unsafe_hash=True)

0 commit comments

Comments
 (0)