Skip to content
View in the app

A better way to browse. Learn more.

thirty bees forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Bug in stock to add product in backoffice

Featured Replies

I try to add product in backoffice, in a order but when i add the item....they reduct the stock two times. example: stock before add: 10 add in order: 2 expected stock result: 8 result in TB: 6

I solved here in controller/admin/AdminOrderController.php Line 2429 (comment the line): // StockAvailable::updateQuantity($orderDetail->product_id, $orderDetail->product_attribute_id, ($orderDetail->product_quantity * -1), $order->id_shop);

Line 2775: Before: // Update product available quantity StockAvailable::updateQuantity($orderDetail->product_id, $orderDetail->product_attribute_id, ($oldQuantity - $orderDetail->product_quantity), $order->id_shop); After: StockAvailable::updateQuantity($orderDetail->product_id, $orderDetail->product_attribute_id, ($oldQuantity - $productQuantity), $order->id_shop);

I dont right if this will impact in more places.... Thanks Mauro

hi interesting found. just to clarify, are you using advance stock management? and is this bug always occurs or just occasionally?

  • Author

@dosbiner I don't use advanced stock, and i migrate from PS 1.6.0.14 to TB 1.0.7 Thanks Mauro

  • Author

@traumflug said in Bug in stock to add product in backoffice:

Let's track this: https://github.com/thirtybees/thirtybees/issues/622

I put here, in production, to test more the solution and working fine with the sugestions. I think this is important to test and patch, about the impact in stock is big if use admin to make orders or update it. Thanks... Mauro

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.