File tree 1 file changed +3
-1
lines changed
Apps/W1/Shopify/app/src/Inventory/Codeunits
1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -33,6 +33,7 @@ codeunit 30195 "Shpfy Inventory API"
33
33
ShopifyVariant: Record "Shpfy Variant";
34
34
StockCalculation: Interface "Shpfy Stock Calculation";
35
35
UOM: Code [10 ];
36
+ SalesUOM: Code [10 ];
36
37
begin
37
38
SetShop( ShopInventory. "Shop Code") ;
38
39
if ShopifyProduct. Get( ShopInventory. "Product Id") and ShopifyVariant. Get( ShopInventory. "Variant Id") then begin
@@ -48,6 +49,7 @@ codeunit 30195 "Shpfy Inventory API"
48
49
end ;
49
50
50
51
StockCalculationFactory( StockCalculation, ShopLocation. "Stock Calculation") ;
52
+ SalesUOM := Item. "Sales Unit of Measure";
51
53
Stock := StockCalculation. GetStock( Item) ;
52
54
53
55
case ShopifyVariant. "UoM Option Id" of
@@ -58,7 +60,7 @@ codeunit 30195 "Shpfy Inventory API"
58
60
3 :
59
61
UOM := CopyStr( ShopifyVariant. "Option 3 Value", 1 , MaxStrLen( UOM)) ;
60
62
else
61
- UOM := Item . "Sales Unit of Measure" ;
63
+ UOM := SalesUOM ;
62
64
end ;
63
65
if ( UOM <> ' ' ) and ( UOM <> Item. "Base Unit of Measure") then
64
66
if ItemUnitofMeasure. Get( Item. "No.", UOM) then
You can’t perform that action at this time.
0 commit comments