added export button
This commit is contained in:
1
odoo/addons/mrp_order_xlsx_export/models/__init__.py
Normal file
1
odoo/addons/mrp_order_xlsx_export/models/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
from . import mrp_production
|
||||
Binary file not shown.
Binary file not shown.
13
odoo/addons/mrp_order_xlsx_export/models/mrp_production.py
Normal file
13
odoo/addons/mrp_order_xlsx_export/models/mrp_production.py
Normal file
@@ -0,0 +1,13 @@
|
||||
from odoo import models
|
||||
|
||||
|
||||
class MrpProduction(models.Model):
|
||||
_inherit = "mrp.production"
|
||||
|
||||
def action_export_xlsx(self):
|
||||
self.ensure_one()
|
||||
return {
|
||||
"type": "ir.actions.act_url",
|
||||
"url": f"/mrp/production/{self.id}/export_xlsx",
|
||||
"target": "self",
|
||||
}
|
||||
Reference in New Issue
Block a user