With this commit: ======================== - Added a new field `forecasted_qty` in replenishment to display the forecasted qty based on a selected warehouse in the wizard - Changed the `route_ids`(m2m) field to `route_id`(m2o) so that we can apply a specific route for the replenishment instead of the product's default routes - Reduced the width of all the fields - Remove the time from the scheduled date and make the unit field not editable. - Can see vendor information with info icon field when buy is selected - Hide the Dropship route from the Route TaskId : 2579425 closes odoo/odoo#96948 Related: odoo/upgrade#3796 Signed-off-by: William Henrotin (whe) <whe@odoo.com>
14 lines
491 B
Python
14 lines
491 B
Python
# -*- coding: utf-8 -*-
|
|
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
|
|
|
from odoo import models
|
|
from odoo.osv import expression
|
|
|
|
|
|
class ProductReplenish(models.TransientModel):
|
|
_inherit = 'product.replenish'
|
|
|
|
def _get_allowed_route_domain(self):
|
|
domains = super()._get_allowed_route_domain()
|
|
return expression.AND([domains, [('id', '!=', self.env.ref('mrp_subcontracting.route_resupply_subcontractor_mto', raise_if_not_found=False).id)]])
|