| Line 1369... |
Line 1369... |
| 1369 |
item = Item.query.filter_by(id=itemId).first()
|
1369 |
item = Item.query.filter_by(id=itemId).first()
|
| 1370 |
if item is None:
|
1370 |
if item is None:
|
| 1371 |
raise CatalogServiceException(itemId, "Could not find item in catalog")
|
1371 |
raise CatalogServiceException(itemId, "Could not find item in catalog")
|
| 1372 |
vatMaster = CategoryVatMaster.query.filter(and_(CategoryVatMaster.categoryId==item.category, CategoryVatMaster.minVal<=price, CategoryVatMaster.maxVal>=price, CategoryVatMaster.stateId == stateId)).first()
|
1372 |
vatMaster = CategoryVatMaster.query.filter(and_(CategoryVatMaster.categoryId==item.category, CategoryVatMaster.minVal<=price, CategoryVatMaster.maxVal>=price, CategoryVatMaster.stateId == stateId)).first()
|
| 1373 |
if vatMaster is None:
|
1373 |
if vatMaster is None:
|
| 1374 |
raise CatalogServiceException(stateId, "Could not find vat rate for this state.")
|
1374 |
raise CatalogServiceException(stateId, "Could not find vat rate for this state." + str(stateId) + " for " + str(itemId))
|
| 1375 |
return vatMaster.vatPercent
|
1375 |
return vatMaster.vatPercent
|
| 1376 |
else:
|
1376 |
else:
|
| 1377 |
return itemVatMaster.vatPercentage
|
1377 |
return itemVatMaster.vatPercentage
|
| 1378 |
|
1378 |
|
| 1379 |
def get_all_ignored_inventoryupdate_items_list(offset,limit):
|
1379 |
def get_all_ignored_inventoryupdate_items_list(offset,limit):
|