| Line 1207... |
Line 1207... |
| 1207 |
inventory.availability = amazoninventorysnapshot.availability
|
1207 |
inventory.availability = amazoninventorysnapshot.availability
|
| 1208 |
inventory.reserved = amazoninventorysnapshot.reserved
|
1208 |
inventory.reserved = amazoninventorysnapshot.reserved
|
| 1209 |
session.commit()
|
1209 |
session.commit()
|
| 1210 |
|
1210 |
|
| 1211 |
def add_update_hold_inventory(itemId, warehouseId, holdQuantity, source):
|
1211 |
def add_update_hold_inventory(itemId, warehouseId, holdQuantity, source):
|
| - |
|
1212 |
if holdQuantity <0:
|
| - |
|
1213 |
print "Negative holdQuantity : " + str(holdQuantity) + " is not allowed"
|
| - |
|
1214 |
raise InventoryServiceException(108, "Negative heldQuantity is not allowed")
|
| 1212 |
hold_inventory_detail = HoldInventoryDetail.get_by(item_id = itemId, warehouse_id=warehouseId, source = source)
|
1215 |
hold_inventory_detail = HoldInventoryDetail.get_by(item_id = itemId, warehouse_id=warehouseId, source = source)
|
| 1213 |
if hold_inventory_detail is None:
|
1216 |
if hold_inventory_detail is None:
|
| 1214 |
diffTobeAddedInCIS = holdQuantity
|
1217 |
diffTobeAddedInCIS = holdQuantity
|
| 1215 |
hold_inventory_detail = HoldInventoryDetail()
|
1218 |
hold_inventory_detail = HoldInventoryDetail()
|
| 1216 |
hold_inventory_detail.item_id = itemId
|
1219 |
hold_inventory_detail.item_id = itemId
|