| Line 555... |
Line 555... |
| 555 |
raise InventoryServiceException(108, "Bad Warehouse")
|
555 |
raise InventoryServiceException(108, "Bad Warehouse")
|
| 556 |
vendor = warehouse.vendor
|
556 |
vendor = warehouse.vendor
|
| 557 |
|
557 |
|
| 558 |
try:
|
558 |
try:
|
| 559 |
item_pricing = VendorItemPricing.query.filter_by(vendor=vendor, item=item).one()
|
559 |
item_pricing = VendorItemPricing.query.filter_by(vendor=vendor, item=item).one()
|
| 560 |
return item_pricing
|
560 |
return item_pricing
|
| 561 |
except sqlalchemy.orm.exc.MultipleResultsFound:
|
561 |
except sqlalchemy.orm.exc.MultipleResultsFound:
|
| 562 |
raise InventoryServiceException(110, "Multiple pricing information present for Vendor: " + vendor.name + " and Item: " + str(item_id))
|
562 |
raise InventoryServiceException(110, "Multiple pricing information present for Vendor: " + vendor.name + " and Item: " + str(item_id))
|
| 563 |
except sqlalchemy.orm.exc.NoResultFound:
|
563 |
except sqlalchemy.orm.exc.NoResultFound:
|
| 564 |
raise InventoryServiceException(111, "Missing pricing information for Vendor: " + vendor.name + " and Item: " + str(item_id))
|
564 |
raise InventoryServiceException(111, "Missing pricing information for Vendor: " + vendor.name + " and Item: " + str(item_id))
|
| 565 |
|
565 |
|