Subcontract Productions

mrp_subcontracting
REPOSITORY
REPOSITORYOCA/manufacture
GIT
GIThttps://github.com/OCA/manufacture.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/manufacture/tree/12.0/mrp_subcontracting
VERSION
VERSION 1.0.6
CATEGORY
CATEGORYManufacturing Orders & BOMs
LICENSE
LICENSELGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSTecnativa, Odoo Community Association (OCA), Odoo S.A.
MAINTAINERS
MAINTAINERSTecnativa, Odoo Community Association (OCA), Odoo S.A.
COMMITTERS
COMMITTERSHolger Brunn, Pedro M. Baeza, OCA Transbot, oca-travis, Weblate, OCA-git-bot, oca-ci, tslai
WEBSITE
WEBSITEhttps://github.com/OCA/manufacture
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:29:20
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - mrp
    - product
    - base
    - decimal_precision
    - mail
    - base_setup
    - web
    - bus
    - web_tour
    - uom
    - stock
    - barcodes
    - resource
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION

Code Analysis

Views touched (7)
XML IDNameModelTypeStatus
mrp_bom_form_view mrp.bom.form.view mrp.bom xpath Inherits mrp.mrp_bom_form_view
mrp_subcontracting_move_form_view mrp.subcontracting.move.form.view stock.move form New
mrp_subcontracting_move_tree_view mrp.subcontracting.move.tree.view stock.move tree New
product_supplierinfo_subcontractor_tree_view product.supplierinfo.subcontractor.tree.view product.supplierinfo xpath Inherits product.product_supplierinfo_tree_view
stock_picking_form_view stock.picking.form.view stock.picking xpath Inherits stock.view_picking_form
view_partner_mrp_subcontracting_form res.partner.mrp_subcontracting.property.form.inherit res.partner xpath Inherits stock.view_partner_stock_form
view_warehouse_inherit_mrp_subcontracting Stock Warehouse Inherit Subcontracting stock.warehouse xpath Inherits mrp.view_warehouse_inherit_mrp
Models touched (14)

New fields (2)
  • subcontractor_ids Many2many → res.partner
    string='Subcontractors' args: 'res.partner', 'mrp_bom_subcontractor'
  • type Selection
    selection_add=[('subcontract', 'Subcontracting')]
Public methods (0)

No public methods.

New fields (1)
  • subcontract_move_id Many2one → stock.move
    args: 'stock.move', 'stock move from the subcontract picking'
Public methods (1)
  • do_produce(self)
    After producing, set the move line on the subcontract picking.

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (1)
  • is_subcontractor Boolean
    compute='_compute_is_subcontractor' help='Choose a vendor of type subcontractor if you want to subcontract the product' args: 'Subcontracted'
Public methods (0)

No public methods.

New fields (1)
  • subcontracting_location_id Many2one → stock.location
    args: 'stock.location'
Public methods (2)
  • create_missing_subcontracting_location(self)
    @api.model
  • create_transit_location(self)
    As there's no standard method for creating locations and we must create the subcontracting location before the warehouse creation, we inherit this method for performing the subcontracting location creation as well.

New fields (1)
  • property_stock_subcontractor Many2one → stock.location
    company_dependent=True help='The stock location used as source and destination when sending goods to this contact during a subcontracting process.' string='Subcontractor Location' args: 'stock.location'
Public methods (0)

No public methods.

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (0)

No new fields.

Public methods (1)
  • should_bypass_reservation(self)

New fields (2)
  • is_subcontract Boolean
    args: 'The move is a subcontract receipt'
  • show_subcontracting_details_visible Boolean
    compute='_compute_show_subcontracting_details_visible'
Public methods (4)
  • action_show_details(self)
    Open the produce wizard in order to register tracked components for subcontracted product. Otherwise use standard behavior.
  • action_show_subcontract_details(self)
    Display moves raw for subcontracted product self.
  • copy(self, default=None)
    @api.multi
  • write(self, values)
    If the initial demand is updated then also update the linked subcontract order to the new quantity.

New fields (0)

No new fields.

Public methods (3)
  • create(self, vals_list)
    @api.model_create_multi
  • unlink(self)
  • write(self, values)

New fields (1)
  • display_action_record_components Boolean
    compute='_compute_display_action_record_components'
Public methods (2)
  • action_done(self)
  • action_record_components(self)

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (5)
  • subcontracting_mto_pull_id Many2one → stock.rule
    args: 'stock.rule', 'Subcontracting MTO Rule'
  • subcontracting_pull_id Many2one → stock.rule
    args: 'stock.rule', 'Subcontracting MTS Rule'
  • subcontracting_route_id Many2one → stock.location.route
    ondelete='restrict' args: 'stock.location.route', 'Resupply Subcontractor'
  • subcontracting_to_resupply Boolean
    default=True help='Resupply subcontractors with components' args: 'Resupply Subcontractors'
  • subcontracting_type_id Many2one → stock.picking.type
    domain=[('code', '=', 'mrp_operation')] args: 'stock.picking.type', 'Subcontracting Operation Type'
Public methods (1)
  • get_rules_dict(self)
STATUS
STATUSOpen migration PR - not merged yet for this version
REPOSITORY
REPOSITORYOCA/manufacture
PULL REQUEST
PULL REQUEST[11.0] [mig] mrp subcontracting (#1721)