Hello!
I'm trying to figure out a way to know if a stock_picking (Transfer) is IN or OUT via code. (v17)
Anybody knows how?
Thanks in advance.
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
Hello!
I'm trying to figure out a way to know if a stock_picking (Transfer) is IN or OUT via code. (v17)
Anybody knows how?
Thanks in advance.
Use the field picking_type_code
'incoming' = Receipt (IN)
'outgoing' = Delivery (OUT)
'internal' = Internal Transfer (INT)
'mrp_operation' = Manufacturing (MO)
'repair_operation' = Repair (RO)
'dropship' = Dropship (DS)
See:
https://github.com/odoo/odoo/blob/17.0/addons/stock/models/stock_picking.py#L474
https://github.com/odoo/odoo/blob/17.0/addons/stock/models/stock_picking.py#L45
https://github.com/odoo/odoo/blob/17.0/addons/mrp/models/stock_picking.py#L10
https://github.com/odoo/odoo/blob/17.0/addons/repair/models/stock_picking.py#L14
https://github.com/odoo/odoo/blob/17.0/addons/stock_dropshipping/models/stock.py#L46
Create an account today to enjoy exclusive features and engage with our awesome community!
RegistráciaRelated Posts | Replies | Zobrazenia | Aktivita | |
---|---|---|---|---|
Invoice Stock Move
Solved
|
|
1
sep 23
|
3234 | |
|
0
mar 23
|
1850 | ||
|
0
mar 18
|
2799 | ||
|
3
feb 20
|
3507 | ||
|
0
okt 17
|
3080 |