-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NEW : allow stock management by product #26200
NEW : allow stock management by product #26200
Conversation
@@ -2300,6 +2339,7 @@ | |||
$product_static->surface_units = $lines[$i]->surface_units; | |||
$product_static->volume = $lines[$i]->volume; | |||
$product_static->volume_units = $lines[$i]->volume_units; | |||
$product_static->stockable_product = $lines[$i]->stockable_product; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @thomas-Ngr
I believe this line does not work as $lines[$i]->stockable_product does not exist.
if ($lines[$i]->product_type == Product::TYPE_SERVICE && !empty($conf->global->SHIPMENT_SUPPORTS_SERVICES)) { | ||
print '<span class="opacitymedium">('.$langs->trans("Service").')</span>'; | ||
} elseif ($lines[$i]->entrepot_id > 0) { | ||
} elseif ($lines[$i]->entrepot_id > 0 && $lines[$i]->product->stockable_product == Product::ENABLED_STOCK) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @thomas-Ngr
Same here; this $lines[$i]->product->stockable_product does not exist in the object $lines[$i]
NEW : allow stock management by product
When using product stocks, users may want to have some products for which they don't want to manage stocks, for example in case of subcontracting.
This PR:
Discussion started on #26184
SQL Part : #26190