[FIX] purchase_stock: no destination address
- Create a product sold by Dropshipping
- Create a SO, validate
- Validate the corresponding PO
- On the picking, print the 'Picking Operations' or the 'Delivery Slip'
There is no delivery address printed.
The root cause of the issue is that the field `dest_address_id` of the
PO is empty. This is because `partner_dest_id` is not used anymore since
1e160dffd3.
opw-1892990
closes odoo/odoo#27850
This commit is contained in:
@@ -169,7 +169,7 @@ class StockRule(models.Model):
|
||||
'picking_type_id': self.picking_type_id.id,
|
||||
'company_id': values['company_id'].id,
|
||||
'currency_id': partner.with_context(force_company=values['company_id'].id).property_purchase_currency_id.id or self.env.user.company_id.currency_id.id,
|
||||
'dest_address_id': values.get('partner_dest_id', False) and values['partner_dest_id'].id,
|
||||
'dest_address_id': values.get('partner_id', False),
|
||||
'origin': origin,
|
||||
'payment_term_id': partner.with_context(force_company=values['company_id'].id).property_supplier_payment_term_id.id,
|
||||
'date_order': purchase_date.strftime(DEFAULT_SERVER_DATETIME_FORMAT),
|
||||
|
||||
Reference in New Issue
Block a user