Paraguay - Maquila MRP
l10n_py_maquila_mrp · OCA/l10n-paraguay
-
Security25/25No findings
-
Activity25/25Human commit this month
-
Required by15/251 module depends on it
-
Maturity12/25In 2 Odoo series since 18.0
Heuristic over the facts below, not an audit · How it's computed
Description
Manufacturing (MRP) integration for Paraguay's Maquila regime (Ley 7547/2025):
- BOM INTN coefficients: gross quantity (requirement factor), net quantity
and loss percentage, plus the origin type of each component (temporary
admission, national, Mercosur, imported). The net-quantity fields are derived
from GRAP's
mrp_bom_line_net_qty. - Maquila program on manufacturing orders (computed from the BOM) with BOM, production and waste counters.
- Waste management (scrap, byproduct, defective) with destruction / nationalization / re-export destinations; destruction drafts a stock scrap.
- VAN wizard: national added value for a period, computed from the program's analytic cost minus foreign-origin inputs; it requires completed production to determine the origin split.
Known gap (Phase 2): Ley 7547/2025 Art. 37 defines the national added value as the sum of (a) goods acquired in the national territory, (b) services hired in the country, (c) salaries and social security paid in the country, (d) depreciation of the capital goods owned by the maquiladora and (e) the remuneration received for the maquila or sub-maquila services. The VAN wizard does not compute these five components: it takes the cost booked to the program's analytic account and subtracts the inputs of imported and Mercosur origin. It is only as complete as the analytic bookings (depreciation and the remuneration of the maquila service, items (d) and (e), are not identified) and must be checked against the Art. 37 components before filing the sworn statement.
Dependencies
- Odoo dependencies
- Python dependencies
- python-stdnum
- System dependencies
- None
- Required by
- l10n_py_maquila_report
Code analysis
Extracted from the source by best-effort static analysis (no code is executed); details may be incomplete.
Views touched 8
| XML ID | Name | Model | Type | Status |
|---|---|---|---|---|
mrp_bom_form_view_inherit_maquila |
mrp.bom.form.inherit.maquila | mrp.bom | form | Inherits mrp.mrp_bom_form_view |
mrp_production_form_view_inherit_maquila |
mrp.production.form.inherit.maquila | mrp.production | form | Inherits mrp.mrp_production_form_view |
view_maquila_program_form_inherit_mrp |
l10n_py.maquila.program.form.inherit.mrp | l10n_py.maquila.program | form | Inherits l10n_py_maquila_base.view_maquila_program_form |
view_maquila_program_form_inherit_mrp_stats |
l10n_py.maquila.program.form.inherit.mrp.stats | l10n_py.maquila.program | form | Inherits l10n_py_maquila_base.view_maquila_program_form |
view_maquila_van_wizard_form |
l10n_py.maquila.van.wizard.form | l10n_py.maquila.van.wizard | form | New |
view_maquila_waste_form |
l10n_py.maquila.waste.form | l10n_py.maquila.waste | form | New |
view_maquila_waste_search |
l10n_py.maquila.waste.search | l10n_py.maquila.waste | search | New |
view_maquila_waste_tree |
l10n_py.maquila.waste.tree | l10n_py.maquila.waste | list | New |
HTTP endpoints 0
No HTTP endpoints found for this module.
Models touched 7
-
bom_countIntegercompute='_compute_bom_count' -
bom_idsOne2many → mrp.bomstring='Bills of Materials' args: 'mrp.bom', 'l10n_py_maquila_program_id' -
production_countIntegercompute='_compute_production_count' -
production_idsOne2many → mrp.productionstring='Productions' args: 'mrp.production', 'l10n_py_maquila_program_id' -
waste_countIntegercompute='_compute_waste_count' -
waste_idsOne2many → l10n_py.maquila.wastestring='Waste Records' args: 'l10n_py.maquila.waste', 'program_id'
-
action_view_boms(self) -
action_view_productions(self) -
action_view_waste(self)
-
bom_idMany2one → mrp.bomstring='Bill of Materials' args: 'mrp.bom'
No public methods.
-
currency_idMany2one → res.currencydefault=<expr> args: 'res.currency' -
imported_costMonetaryreadonly=True -
mercosul_contentFloatcompute='_compute_van'string='Mercosul Content %' -
mercosul_costMonetaryreadonly=True -
national_costMonetaryreadonly=Truestring='National Cost (PY)' -
period_endDaterequired=True -
period_startDaterequired=True -
program_idMany2one → l10n_py.maquila.programdomain="[('state', '=', 'active')]"required=True args: 'l10n_py.maquila.program' -
total_costMonetaryreadonly=True -
van_amountMonetarycompute='_compute_van'string='VAN Amount' -
van_percentageFloatcompute='_compute_van'string='VAN %'
-
action_compute(self)Compute the VAN via the shared program method so the wizard and the CNIME report always report the same figure.
-
company_idMany2onerelated='program_id.company_id'store=True -
dateDatedefault=fields.Date.todayrequired=True -
destinationSelectionrequired=True args: [('destruction', 'Destruction'), ('nationalization', 'Nationalization'), ('reexport', 'Re-export')] -
destruction_certificateCharstring='INTN Destruction Certificate' -
justificationText -
lot_idMany2one → stock.lotstring='Lot/Serial' args: 'stock.lot' -
nameCharcompute='_compute_name'store=True -
nationalization_move_idMany2one → account.movestring='Nationalization Entry' args: 'account.move' -
product_idMany2one → product.productrequired=Truestring='Waste Product' args: 'product.product' -
production_idMany2one → mrp.productionargs: 'mrp.production' -
program_idMany2one → l10n_py.maquila.programrequired=True args: 'l10n_py.maquila.program' -
quantityFloatdigits='Product Unit of Measure'required=True -
scrap_idMany2one → stock.scrapargs: 'stock.scrap' -
seam_approvalCharhelp='Environmental clearance (MADES, ex-SEAM per Ley 6123/2018)'string='MADES Dictamen' -
stateSelectiondefault='pending'required=Truetracking=True args: [('pending', 'Pending'), ('in_process', 'In Process'), ('completed', 'Completed')] -
waste_typeSelectionrequired=True args: [('scrap', 'Scrap'), ('byproduct', 'Byproduct'), ('defective', 'Defective')]
-
action_complete(self)Complete the waste disposal. For destruction, draft a stock scrap so the physical write-off is traceable; nationalization and re-export keep their own document references (entry / dispatch). -
action_pending(self) -
action_process(self)
-
l10n_py_intn_certificateCharstring='INTN Certificate Number' -
l10n_py_intn_certifiedBooleanstring='INTN Certified' -
l10n_py_intn_dateDatestring='INTN Certification Date' -
l10n_py_maquila_program_idMany2one → l10n_py.maquila.programstring='Maquila Program' args: 'l10n_py.maquila.program'
No public methods.
-
diff_product_qty_gross_netFloatcompute='_compute_diff_product_qty_gross_net'digits='Product Price'string='Gross/Net Difference' -
l10n_py_origin_countryMany2one → res.countrystring='Origin Country' args: 'res.country' -
l10n_py_origin_typeSelectionstring='Origin Type' args: [('temporary_admission', 'Temporary Admission'), ('national_py', 'National (Paraguay)'), ('national_mercosul', 'National (Mercosul)'), ('imported', 'Imported (Other)')] -
loss_percentageFloatdigits=(16, 2)help='Percentage loss during process (INTN waste coefficient)'string='Loss %' -
product_qty_netFloatdigits='Product Unit of Measure'help='Quantity after process (INTN net coefficient)'string='Net Quantity'
-
calculate_qty_net_theoretical(self, product_qty_gross, loss_percentage) -
set_product_qty_gross(self) -
set_product_qty_net(self)
-
l10n_py_maquila_program_idMany2one → l10n_py.maquila.programcompute='_compute_maquila_program'help='Defaults to the program of the bill of materials; can be set by hand for productions without a BoM.'precompute=Truereadonly=Falsestore=Truestring='Maquila Program' args: 'l10n_py.maquila.program'
No public methods.
Loading…
- Status
- Open migration PR — not merged yet for this version
- CI status
- checks failing
- Open since
- 7 days ago
- Last activity
- 7 days ago
- Repository
- OCA/l10n-paraguay
- Pull request
- [20.0][MIG] l10n_py_maquila_mrp: Migration to 20.0 (#81)