mirror of
https://gitlab.com/hibou-io/hibou-odoo/suite.git
synced 2025-01-20 12:37:31 +02:00
[MIG] stock_delivery_route: for Odoo 13.0
This commit is contained in:
committed by
Jared Kipe
parent
f0824c6821
commit
c2c4a8a11b
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
'name': 'Warehouse Delivery Routes',
|
'name': 'Warehouse Delivery Routes',
|
||||||
'summary': 'Assign a delivery route to a sale order or picking.',
|
'summary': 'Assign a delivery route to a sale order or picking.',
|
||||||
'version': '12.0.1.0.0',
|
'version': '13.0.1.0.0',
|
||||||
'author': "Hibou Corp. <hello@hibou.io>",
|
'author': "Hibou Corp. <hello@hibou.io>",
|
||||||
'category': 'Warehouse',
|
'category': 'Warehouse',
|
||||||
'license': 'AGPL-3',
|
'license': 'AGPL-3',
|
||||||
|
|||||||
@@ -7,7 +7,6 @@ class SaleOrder(models.Model):
|
|||||||
delivery_route_id = fields.Many2one('stock.warehouse.delivery.route', string='Delivery Route')
|
delivery_route_id = fields.Many2one('stock.warehouse.delivery.route', string='Delivery Route')
|
||||||
|
|
||||||
@api.onchange('partner_id', 'partner_shipping_id', 'warehouse_id')
|
@api.onchange('partner_id', 'partner_shipping_id', 'warehouse_id')
|
||||||
@api.multi
|
|
||||||
def _prefill_delivery_route(self):
|
def _prefill_delivery_route(self):
|
||||||
for so in self:
|
for so in self:
|
||||||
if so.warehouse_id:
|
if so.warehouse_id:
|
||||||
@@ -23,7 +22,6 @@ class SaleOrder(models.Model):
|
|||||||
else:
|
else:
|
||||||
so.delivery_route_id = False
|
so.delivery_route_id = False
|
||||||
|
|
||||||
@api.multi
|
|
||||||
def action_confirm(self):
|
def action_confirm(self):
|
||||||
val = super(SaleOrder, self).action_confirm()
|
val = super(SaleOrder, self).action_confirm()
|
||||||
for so in self:
|
for so in self:
|
||||||
|
|||||||
@@ -16,7 +16,6 @@ class Picking(models.Model):
|
|||||||
delivery_route_id = fields.Many2one('stock.warehouse.delivery.route', string='Delivery Route')
|
delivery_route_id = fields.Many2one('stock.warehouse.delivery.route', string='Delivery Route')
|
||||||
partner_address = fields.Char(string='Address', compute='_compute_partner_address')
|
partner_address = fields.Char(string='Address', compute='_compute_partner_address')
|
||||||
|
|
||||||
@api.multi
|
|
||||||
def _compute_partner_address(self):
|
def _compute_partner_address(self):
|
||||||
for pick in self:
|
for pick in self:
|
||||||
if pick.partner_id:
|
if pick.partner_id:
|
||||||
@@ -32,7 +31,6 @@ class WarehouseDeliveryRoute(models.Model):
|
|||||||
warehouse_id = fields.Many2one('stock.warehouse', string='Warehouse')
|
warehouse_id = fields.Many2one('stock.warehouse', string='Warehouse')
|
||||||
note = fields.Text(string='Note')
|
note = fields.Text(string='Note')
|
||||||
|
|
||||||
@api.multi
|
|
||||||
def name_get(self):
|
def name_get(self):
|
||||||
res = []
|
res = []
|
||||||
for route in self:
|
for route in self:
|
||||||
|
|||||||
Reference in New Issue
Block a user