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!
Sign up| Related Posts | Replies | Views | Activity | |
|---|---|---|---|---|
| 
            
                Invoice Stock Move
            
            
                    Solved
            
         |  | 1 सित॰ 23  | 4323 | |
|  | 0 मार्च 23  | 2364 | ||
|  | 0 मार्च 18  | 3428 | ||
|  | 3 फ़र॰ 20  | 4254 | ||
|  | 0 अक्तू॰ 17  | 3580 |