简体   繁体   English

如何对超过5万种产品进行库存调整?

[英]How to do inventory adjustments for more than 50k products?

I want to do inventory adjustment for more then 50k > products. 我想对超过5万种产品进行库存调整。 But odoo not able to do. 但是odoo无法做到。 Every time show error time exceeds. 每次显示错误时间超过。 It take too much time, any way to do speedy. 花太多时间,要快速完成任何事情。

Thanks for help 感谢帮助

In this case, it might be best to develop a queue process to process pieces of this in a batch. 在这种情况下,最好开发一个队列处理程序来批量处理其中的各个部分。 The linked modules are from OCA and are a base for others to develop their specific queues. 链接的模块来自OCA,是其他人开发其特定队列的基础。

In your case, it may require manual or automated splitting of the Inventory Adjustments into smaller batches or (ideally) you can process x lines at a time, such as: 在您的情况下,可能需要手动或自动将“库存调整”拆分为较小的批处理,或者(理想情况下)您可以一次处理x行,例如:

 stock_inventory.line_ids.filtered(lambda r: r.state == 'draft')

Note: It doesn't look like the above code will actually work because all stock.inventory.line "Status" are just related to the stock.inventory . 注意:由于所有stock.inventory.line “ Status”都与stock.inventory相关,因此上面的代码看起来并不实际stock.inventory You'll probably need to override this to be manually updated or take a different approach. 您可能需要覆盖它以手动更新或采用其他方法。

Documentation on filtered filtered文档

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM