private Price GetLatestPurchPrice(ItemId _item)
{
InventItemPrice invItemprice;
;
select firstOnly invItemprice order by RecId desc
where invItemprice.ItemId == _item
&& invItemprice.PriceType == CostingVersionPriceType::Purch
&& invItemprice.CostingType == InventItemCostingType::Last;
return invItemprice.Price;
}
{
InventItemPrice invItemprice;
;
select firstOnly invItemprice order by RecId desc
where invItemprice.ItemId == _item
&& invItemprice.PriceType == CostingVersionPriceType::Purch
&& invItemprice.CostingType == InventItemCostingType::Last;
return invItemprice.Price;
}
No comments:
Post a Comment