Stock level is not correctly showing on the edit variation form

Created on 19 March 2025, about 1 month ago

Our product variation stock level is not correctly showing on the product variation edit form. It displays 0 all the time, while the stock is correctly shown if we show the stock level field in a view.

Correct

Wrong

In `StockLevelWidgetBase.php` the current level is retrieved with `$level = $field->get('available_stock')->getValue();`. I think we can better use the `StockServiceManager` here to get the actual stock level of the variation?

🐛 Bug report
Status

Active

Version

1.0

Component

Code

Created by

🇧🇪Belgium dtrdewaele

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024