Some refinements for #501

This commit is contained in:
Bernd Bestel
2020-01-21 20:45:34 +01:00
parent 3a36bdaf45
commit 0816359867
9 changed files with 52 additions and 55 deletions

View File

@@ -12,6 +12,7 @@ class StockService extends BaseService
const TRANSACTION_TYPE_STOCK_EDIT_NEW = 'stock-edit-new';
const TRANSACTION_TYPE_STOCK_EDIT_OLD = 'stock-edit-old';
const TRANSACTION_TYPE_PRODUCT_OPENED = 'product-opened';
const TRANSACTION_TYPE_SELF_PRODUCTION = 'self-production';
public function GetCurrentStock($includeNotInStockButMissingProducts = false)
{
@@ -242,7 +243,7 @@ class StockService extends BaseService
}
}
if ($transactionType === self::TRANSACTION_TYPE_PURCHASE || $transactionType === self::TRANSACTION_TYPE_INVENTORY_CORRECTION)
if ($transactionType === self::TRANSACTION_TYPE_PURCHASE || $transactionType === self::TRANSACTION_TYPE_INVENTORY_CORRECTION || $transactionType == self::TRANSACTION_TYPE_SELF_PRODUCTION)
{
if ($transactionId === null)
{