diff --git a/bom_structure_in_excel_odoo/README.rst b/bom_structure_in_excel_odoo/README.rst new file mode 100644 index 000000000..93e0f1b07 --- /dev/null +++ b/bom_structure_in_excel_odoo/README.rst @@ -0,0 +1,42 @@ +.. image:: https://img.shields.io/badge/license-AGPL--3-blue.svg + :target: https://www.gnu.org/licenses/agpl-3.0-standalone.html + :alt: License: AGPL-3 + +BOM Structure & Cost Report in Excel +==================================== +* Effortlessly export BOM Structure & Cost Reports to Excel format. + +License +------- +General Public License, Version 3 (AGPL v3). +(https://www.odoo.com/documentation/user/16.0/legal/licenses/licenses.html) + +Company +------- +* `Cybrosys Techno Solutions `__ + +Credits +------- +* Developer: (V16)Anfas Faisal K, Contact: odoo@cybrosys.com + +Contacts +-------- +* Mail Contact : odoo@cybrosys.com +* Website : https://cybrosys.com + +Bug Tracker +----------- +Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. + +Maintainer +========== +.. image:: https://cybrosys.com/images/logo.png + :target: https://cybrosys.com + +This module is maintained by Cybrosys Technologies. + +For support and more information, please visit https://www.cybrosys.com + +Further information +=================== +HTML Description: ``__ diff --git a/bom_structure_in_excel_odoo/__init__.py b/bom_structure_in_excel_odoo/__init__.py new file mode 100644 index 000000000..b2cc6599c --- /dev/null +++ b/bom_structure_in_excel_odoo/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +################################################################################ +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies(). +# Author: Anfas Faisal K (odoo@cybrosys.info) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +################################################################################ +from . import controllers +from . import models diff --git a/bom_structure_in_excel_odoo/__manifest__.py b/bom_structure_in_excel_odoo/__manifest__.py new file mode 100644 index 000000000..fbce85f7e --- /dev/null +++ b/bom_structure_in_excel_odoo/__manifest__.py @@ -0,0 +1,52 @@ +# -*- coding: utf-8 -*- +################################################################################ +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies(). +# Author: Anfas Faisal K (odoo@cybrosys.info) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +################################################################################ +{ + 'name': "BOM Structure & Cost Report in Excel", + 'version': "16.0.1.0.0", + 'category': 'Manufacturing,Inventory', + 'summary': 'Effortlessly export BOM Structure & Cost Reports to Excel ' + 'format', + 'description': 'This app enhances your Odoo experience by enabling the ' + 'export of "BOM Structure & Cost Reports" to Excel format. ' + 'It provides a seamless transition from the standard Odoo ' + 'PDF report to an Excel file, offering flexibility in data ' + 'analysis and presentation.Simply export and analyze your ' + 'BOM reports in Excel with ease.', + 'author': 'Cybrosys Techno Solutions', + 'company': 'Cybrosys Techno Solutions', + 'maintainer': 'Cybrosys Techno Solutions', + 'images': ['static/description/banner.png'], + 'website': 'https://www.cybrosys.com', + 'depends': ['stock', 'mrp'], + 'data': [ + 'data/mrp_bom_data.xml', + ], + 'assets': { + 'web.assets_backend': [ + 'bom_structure_in_excel_odoo/static/src/js/action_manager.js', + ] + }, + 'license': 'AGPL-3', + 'installable': True, + 'auto_install': False, + 'application': False, +} diff --git a/bom_structure_in_excel_odoo/controllers/__init__.py b/bom_structure_in_excel_odoo/controllers/__init__.py new file mode 100644 index 000000000..15a869243 --- /dev/null +++ b/bom_structure_in_excel_odoo/controllers/__init__.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +################################################################################ +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies(). +# Author: Anfas Faisal K (odoo@cybrosys.info) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +################################################################################ +from . import bom_structure_in_excel_odoo diff --git a/bom_structure_in_excel_odoo/controllers/bom_structure_in_excel_odoo.py b/bom_structure_in_excel_odoo/controllers/bom_structure_in_excel_odoo.py new file mode 100644 index 000000000..352056bbf --- /dev/null +++ b/bom_structure_in_excel_odoo/controllers/bom_structure_in_excel_odoo.py @@ -0,0 +1,57 @@ +# -*- coding: utf-8 -*- +################################################################################ +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies(). +# Author: Anfas Faisal K (odoo@cybrosys.info) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +################################################################################ +import json +from odoo import http +from odoo.http import content_disposition, request, serialize_exception +from odoo.tools import html_escape + + +class XLSXReportController(http.Controller): + """Xlsx Report controller""" + @http.route('/xlsx_reports', type='http', auth='user', methods=['POST'], + csrf=False) + def get_report_xlsx(self, model, options, output_format, report_name): + """xlsx report""" + uid = request.session.uid + report_obj = request.env[model].with_user(uid) + options = json.loads(options) + token = 'dummy-because-api-expects-one' + try: + if output_format == 'xlsx': + response = request.make_response( + None, + headers=[ + ('Content-Type', 'application/vnd.ms-excel'), + ('Content-Disposition', content_disposition(report_name + '.xlsx')) + ] + ) + report_obj.get_xlsx_report(options, response) + response.set_cookie('fileToken', token) + return response + except Exception as e: + se = serialize_exception(e) + error = { + 'code': 200, + 'message': 'Odoo Server Error', + 'data': se + } + return request.make_response(html_escape(json.dumps(error))) diff --git a/bom_structure_in_excel_odoo/data/mrp_bom_data.xml b/bom_structure_in_excel_odoo/data/mrp_bom_data.xml new file mode 100644 index 000000000..50a3c9313 --- /dev/null +++ b/bom_structure_in_excel_odoo/data/mrp_bom_data.xml @@ -0,0 +1,13 @@ + + + + + BOM Structure EXCEL + + + form + report + code + action = records.action_print_bom_structure() + + \ No newline at end of file diff --git a/bom_structure_in_excel_odoo/doc/RELEASE_NOTES.md b/bom_structure_in_excel_odoo/doc/RELEASE_NOTES.md new file mode 100644 index 000000000..339a54b86 --- /dev/null +++ b/bom_structure_in_excel_odoo/doc/RELEASE_NOTES.md @@ -0,0 +1,5 @@ +## Module +#### 17.01.2024 +#### Version 16.0.1.0.0 +#### ADD +- Initial commit for BOM Structure & Cost Report in Excel diff --git a/bom_structure_in_excel_odoo/models/__init__.py b/bom_structure_in_excel_odoo/models/__init__.py new file mode 100644 index 000000000..f86a1572e --- /dev/null +++ b/bom_structure_in_excel_odoo/models/__init__.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +################################################################################ +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies(). +# Author: Anfas Faisal K (odoo@cybrosys.info) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +################################################################################ +from . import mrp_bom diff --git a/bom_structure_in_excel_odoo/models/mrp_bom.py b/bom_structure_in_excel_odoo/models/mrp_bom.py new file mode 100644 index 000000000..aa144e87b --- /dev/null +++ b/bom_structure_in_excel_odoo/models/mrp_bom.py @@ -0,0 +1,171 @@ +# -*- coding: utf-8 -*- +################################################################################ +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies(). +# Author: Anfas Faisal K (odoo@cybrosys.info) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +################################################################################ +import io +import json +import xlsxwriter +from odoo import models +from odoo.tools import date_utils + + +class AccountMove(models.Model): + """Inherits the account move model""" + _inherit = 'mrp.bom' + + def action_print_bom_structure(self): + """Generate and export the BOM Structure Report in Excel format.""" + bom = self.env['mrp.bom'].browse(self.id) + candidates = bom.product_id or bom.product_tmpl_id.product_variant_ids + quantity = bom.product_qty + for product_variant_id in candidates.ids: + doc = self.env['report.mrp.report_bom_structure']._get_pdf_line( + bom.id, product_id=product_variant_id, + qty=quantity, unfolded=True) + return { + 'type': 'ir.actions.report', + 'data': {'model': 'mrp.bom', + 'options': json.dumps(doc, + default=date_utils.json_default), + 'output_format': 'xlsx', + 'report_name': 'BoM Structure', + }, + 'report_type': 'xlsx', + } + + def get_xlsx_report(self, data, response): + """ Generate an Excel report with BOM structure and cost.""" + output = io.BytesIO() + workbook = xlsxwriter.Workbook(output, {'in_memory': True}) + sheet = workbook.add_worksheet() + # Define cell formats + head = workbook.add_format( + {'align': 'left', 'bold': True, 'font_size': '20px'}) + format3 = workbook.add_format({'font_size': '15px', 'bold': True}) + format4 = workbook.add_format({'font_size': 10}) + format6 = workbook.add_format({'font_size': 10, 'bold': True}) + format7 = workbook.add_format({'font_size': 10, 'font_color': 'green'}) + format8 = workbook.add_format({'font_size': 10, 'font_color': 'red'}) + format9 = workbook.add_format({'font_size': 10, 'font_color': 'yellow'}) + # Check if there are components or lines in the data + if data and data.get('components') or data.get('lines'): + # Merge and format header cells + sheet.merge_range('A1:F2', 'BoM Structure & Cost', head) + sheet.merge_range('A4:Z5', data['name'], format3) + # Merge and format cells for product information + sheet.merge_range('A7:C7', 'Products', format6) + sheet.merge_range('D7:E7', 'Quantity', format6) + sheet.merge_range('F7:G7', 'Unit of Measure', format6) + sheet.merge_range('H7:I7', 'Ready to Produce', format6) + sheet.merge_range('J7:K7', 'Free to Use / On Hand', format6) + sheet.merge_range('L7:M7', 'Availability', format6) + sheet.merge_range('N7:O7', 'Lead Time', format6) + sheet.merge_range('P7:Q7', 'Route', format6) + sheet.merge_range('R7:S7', 'BOM Cost', format6) + sheet.merge_range('T7:U7', 'Product Cost', format6) + row_start = 9 # Starting row for data + currency_symbol = self.env.user.company_id.currency_id.symbol + # Iterate through lines in the data + for index, value in enumerate(data.get('lines')): + # Calculate leading spaces based on the level + if value['level'] != 0: + space_td = ' ' * value['level'] + else: + space_td = ' ' + # Merge and format cells for product name + sheet.merge_range('A8:C8', data['name'], format6) + sheet.merge_range('D8:E8', data['quantity'], format4) + sheet.merge_range(f'A{index + row_start}:C{index + row_start}', + space_td + value['name'], format4) + # Merge and format cells for quantity + sheet.merge_range(f'D{index + row_start}:E{index + row_start}', + value['quantity'], format4) + # Merge and format cells for unit of measure + if 'uom' in value: + sheet.merge_range( + f'F{index + row_start}:G{index + row_start}', + value['uom'], format4) + # Merge and format cells for 'Ready to Produce' + if 'producible_qty' in value: + sheet.merge_range('H8:I8', data['producible_qty'], format4) + sheet.merge_range( + f'H{index + row_start}:I{index + row_start}', + value['producible_qty'], format4) + # Merge and format cells for 'Quantity Available / On Hand' + if 'quantity_available' in value: + quantity_available_on_hand = \ + f"{value['quantity_available']} / {value['quantity_on_hand']}" + sheet.merge_range( + 'J8:K8', f"{data['quantity_available']} / " + f"{data['quantity_on_hand']}", format4) + sheet.merge_range( + f'J{index + row_start}:K{index + row_start}', + quantity_available_on_hand, format4) + # Merge and format cells for 'Availability' + if 'availability_display' in value: + availability_main_text = data['availability_display'] + availability_text = value['availability_display'] + color_format_main = format7 if ( + availability_main_text == 'Available') \ + else ( + format8 if availability_main_text == 'Not Available' + else format9) + color_format = format7 if availability_text == 'Available' \ + else (format8 if availability_text == 'Not Available' + else format9) + sheet.merge_range( + 'L8:M8', availability_main_text, color_format_main) + sheet.merge_range( + f'L{index + row_start}:M{index + row_start}', + availability_text, color_format) + # Merge and format cells for 'Product Cost' + if 'prod_cost' in value: + prod_cost_with_symbol = f"{currency_symbol} {data['prod_cost']} " + sheet.merge_range( + 'R8:S8', prod_cost_with_symbol, format4) + sheet.merge_range( + f'R{index + row_start}:S{index + row_start}', + f"{currency_symbol} {value['prod_cost']}", format4) + # Merge and format cells for 'BOM Cost' + if 'bom_cost' in value: + bom_cost_with_symbol = f" {currency_symbol} {data['bom_cost']}" + sheet.merge_range( + 'T8:U8', bom_cost_with_symbol, format4) + sheet.merge_range( + f'T{index + row_start}:U{index + row_start}', + f" {currency_symbol} {value['bom_cost']}", format4) + # Merge and format cells for 'Route Info' + if 'route_name' in value: + route_info = f"{value['route_name']} {value['route_detail']}" + sheet.merge_range( + f'P{index + row_start}:Q{index + row_start}', + route_info, format4) + # Merge and format cells for 'Lead Time' + if 'lead_time' in value: + lead_time = value['lead_time'] + lead_time_days = f"{int(lead_time)} days" if lead_time != 0.0 else "0 days" + sheet.merge_range( + f'N{index + row_start}:O{index + row_start}', + lead_time_days, format4) + # Close the workbook, seek to the beginning, and stream the output + workbook.close() + output.seek(0) + response.stream.write(output.read()) + output.close() diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/check.png b/bom_structure_in_excel_odoo/static/description/assets/icons/check.png new file mode 100644 index 000000000..c8e85f51d Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/check.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/chevron.png b/bom_structure_in_excel_odoo/static/description/assets/icons/chevron.png new file mode 100644 index 000000000..2089293d6 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/chevron.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/cogs.png b/bom_structure_in_excel_odoo/static/description/assets/icons/cogs.png new file mode 100644 index 000000000..95d0bad62 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/cogs.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/consultation.png b/bom_structure_in_excel_odoo/static/description/assets/icons/consultation.png new file mode 100644 index 000000000..8319d4baa Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/consultation.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/ecom-black.png b/bom_structure_in_excel_odoo/static/description/assets/icons/ecom-black.png new file mode 100644 index 000000000..a9385ff13 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/ecom-black.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/education-black.png b/bom_structure_in_excel_odoo/static/description/assets/icons/education-black.png new file mode 100644 index 000000000..3eb09b27b Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/education-black.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/hotel-black.png b/bom_structure_in_excel_odoo/static/description/assets/icons/hotel-black.png new file mode 100644 index 000000000..130f613be Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/hotel-black.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/license.png b/bom_structure_in_excel_odoo/static/description/assets/icons/license.png new file mode 100644 index 000000000..a5869797e Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/license.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/lifebuoy.png b/bom_structure_in_excel_odoo/static/description/assets/icons/lifebuoy.png new file mode 100644 index 000000000..658d56ccc Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/lifebuoy.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/manufacturing-black.png b/bom_structure_in_excel_odoo/static/description/assets/icons/manufacturing-black.png new file mode 100644 index 000000000..697eb0e9f Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/manufacturing-black.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/pos-black.png b/bom_structure_in_excel_odoo/static/description/assets/icons/pos-black.png new file mode 100644 index 000000000..97c0f90c1 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/pos-black.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/puzzle.png b/bom_structure_in_excel_odoo/static/description/assets/icons/puzzle.png new file mode 100644 index 000000000..65cf854e7 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/puzzle.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/restaurant-black.png b/bom_structure_in_excel_odoo/static/description/assets/icons/restaurant-black.png new file mode 100644 index 000000000..4a35eb939 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/restaurant-black.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/service-black.png b/bom_structure_in_excel_odoo/static/description/assets/icons/service-black.png new file mode 100644 index 000000000..301ab51cb Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/service-black.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/trading-black.png b/bom_structure_in_excel_odoo/static/description/assets/icons/trading-black.png new file mode 100644 index 000000000..9398ba2f1 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/trading-black.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/training.png b/bom_structure_in_excel_odoo/static/description/assets/icons/training.png new file mode 100644 index 000000000..884ca024d Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/training.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/update.png b/bom_structure_in_excel_odoo/static/description/assets/icons/update.png new file mode 100644 index 000000000..ecbc5a01a Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/update.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/user.png b/bom_structure_in_excel_odoo/static/description/assets/icons/user.png new file mode 100644 index 000000000..6ffb23d9f Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/user.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/icons/wrench.png b/bom_structure_in_excel_odoo/static/description/assets/icons/wrench.png new file mode 100644 index 000000000..6c04dea0f Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/icons/wrench.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/categories.png b/bom_structure_in_excel_odoo/static/description/assets/misc/categories.png new file mode 100644 index 000000000..bedf1e0b1 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/categories.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/check-box.png b/bom_structure_in_excel_odoo/static/description/assets/misc/check-box.png new file mode 100644 index 000000000..42caf24b9 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/check-box.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/compass.png b/bom_structure_in_excel_odoo/static/description/assets/misc/compass.png new file mode 100644 index 000000000..d5fed8faa Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/compass.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/corporate.png b/bom_structure_in_excel_odoo/static/description/assets/misc/corporate.png new file mode 100644 index 000000000..2eb13edbf Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/corporate.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/customer-support.png b/bom_structure_in_excel_odoo/static/description/assets/misc/customer-support.png new file mode 100644 index 000000000..79efc72ed Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/customer-support.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/cybrosys-logo.png b/bom_structure_in_excel_odoo/static/description/assets/misc/cybrosys-logo.png new file mode 100644 index 000000000..cc3cc0ccf Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/cybrosys-logo.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/features.png b/bom_structure_in_excel_odoo/static/description/assets/misc/features.png new file mode 100644 index 000000000..b41769f77 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/features.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/logo.png b/bom_structure_in_excel_odoo/static/description/assets/misc/logo.png new file mode 100644 index 000000000..478462d3e Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/logo.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/pictures.png b/bom_structure_in_excel_odoo/static/description/assets/misc/pictures.png new file mode 100644 index 000000000..56d255fe9 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/pictures.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/pie-chart.png b/bom_structure_in_excel_odoo/static/description/assets/misc/pie-chart.png new file mode 100644 index 000000000..426e05244 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/pie-chart.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/right-arrow.png b/bom_structure_in_excel_odoo/static/description/assets/misc/right-arrow.png new file mode 100644 index 000000000..730984a06 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/right-arrow.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/star.png b/bom_structure_in_excel_odoo/static/description/assets/misc/star.png new file mode 100644 index 000000000..2eb9ab29f Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/star.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/support.png b/bom_structure_in_excel_odoo/static/description/assets/misc/support.png new file mode 100644 index 000000000..4f18b8b82 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/support.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/misc/whatsapp.png b/bom_structure_in_excel_odoo/static/description/assets/misc/whatsapp.png new file mode 100644 index 000000000..d513a5356 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/misc/whatsapp.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/modules/1.jpg b/bom_structure_in_excel_odoo/static/description/assets/modules/1.jpg new file mode 100644 index 000000000..18f9f453d Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/modules/1.jpg differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/modules/2.png b/bom_structure_in_excel_odoo/static/description/assets/modules/2.png new file mode 100644 index 000000000..df3f6836d Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/modules/2.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/modules/3.png b/bom_structure_in_excel_odoo/static/description/assets/modules/3.png new file mode 100644 index 000000000..ac15216fb Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/modules/3.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/modules/4.png b/bom_structure_in_excel_odoo/static/description/assets/modules/4.png new file mode 100644 index 000000000..5c56f0bcd Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/modules/4.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/modules/5.png b/bom_structure_in_excel_odoo/static/description/assets/modules/5.png new file mode 100644 index 000000000..e78427938 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/modules/5.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/modules/6.png b/bom_structure_in_excel_odoo/static/description/assets/modules/6.png new file mode 100644 index 000000000..6949185dd Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/modules/6.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/screenshots/1.png b/bom_structure_in_excel_odoo/static/description/assets/screenshots/1.png new file mode 100644 index 000000000..a9330ab8e Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/screenshots/1.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/screenshots/2.png b/bom_structure_in_excel_odoo/static/description/assets/screenshots/2.png new file mode 100644 index 000000000..02854c8d3 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/screenshots/2.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/screenshots/3.png b/bom_structure_in_excel_odoo/static/description/assets/screenshots/3.png new file mode 100644 index 000000000..7df1c515a Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/screenshots/3.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/screenshots/4.png b/bom_structure_in_excel_odoo/static/description/assets/screenshots/4.png new file mode 100644 index 000000000..09bb9821d Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/screenshots/4.png differ diff --git a/bom_structure_in_excel_odoo/static/description/assets/screenshots/v16-hero.gif b/bom_structure_in_excel_odoo/static/description/assets/screenshots/v16-hero.gif new file mode 100644 index 000000000..cd2fad88d Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/assets/screenshots/v16-hero.gif differ diff --git a/bom_structure_in_excel_odoo/static/description/banner.png b/bom_structure_in_excel_odoo/static/description/banner.png new file mode 100644 index 000000000..0ac60ca64 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/banner.png differ diff --git a/bom_structure_in_excel_odoo/static/description/icon.png b/bom_structure_in_excel_odoo/static/description/icon.png new file mode 100644 index 000000000..bb1f49943 Binary files /dev/null and b/bom_structure_in_excel_odoo/static/description/icon.png differ diff --git a/bom_structure_in_excel_odoo/static/description/index.html b/bom_structure_in_excel_odoo/static/description/index.html new file mode 100644 index 000000000..81bfc3eb2 --- /dev/null +++ b/bom_structure_in_excel_odoo/static/description/index.html @@ -0,0 +1,643 @@ +
+ +
+ +
+
+ Community +
+
+ Enterprise +
+
+ Odoo.sh +
+
+
+ + + +

+ BOM Structure & Cost Report in Excel

+

+ Excel Output for BOM Structure and BOM Cost Report. +

+ + + +
+ + +
+
+ +
+

+ Explore This + Module

+
+ + + + +
+
+ +
+

+ Overview +

+
+
+
+ This application facilitates the export of a "BOM Structure & Cost Report" in Excel format. It replicates the report generated by Odoo in PDF format, providing users with the ability to obtain the same data in an Excel spreadsheet, as illustrated in the screenshots below. + +
+
+ + + +
+
+ +
+

+ Features +

+
+
+
+
+ + Allow you to export BoM Structure & Cost Report in Excel format +
+ +
+ + This gives the same output which the PDF report of Odoo standard gives +
+
+
+ + + +
+
+ +
+

+ Screenshots +

+
+
+
+ +
+

+ Open Bills of Materials +

+ +
+ +
+

+ Select any one of the records +

+

+ +
+ + +
+

+ Click on the Print Button and Click BOM Structure Excel to print the Excel Report +

+

+

+ +
+ +
+

+ Excel Report View +

+

+ +
+ + +
+
+ + + +
+
+ +
+

+ Related + Products +

+
+
+
+ +
+
+ + + + +
+
+ +
+

+ Our Services +

+
+ +
+
+
+
+ +
+
+ Odoo + Customization
+
+ +
+
+ +
+
+ Odoo + Implementation
+
+ +
+
+ +
+
+ Odoo + Support
+
+ + +
+
+ +
+
+ Hire + Odoo + Developer
+
+ +
+
+ +
+
+ Odoo + Integration
+
+ +
+
+ +
+
+ Odoo + Migration
+
+ + +
+
+ +
+
+ Odoo + Consultancy
+
+ +
+
+ +
+
+ Odoo + Implementation
+
+ +
+
+ +
+
+ Odoo + Licensing Consultancy
+
+
+ +
+ + + + +
+
+ +
+

+ Our + Industries +

+
+ +
+
+
+
+ +
+ Trading +
+

+ Easily procure + and + sell your products

+
+
+ +
+
+ +
+ POS +
+

+ Easy + configuration + and convivial experience

+
+
+ +
+
+ +
+ Education +
+

+ A platform for + educational management

+
+
+ +
+
+ +
+ Manufacturing +
+

+ Plan, track and + schedule your operations

+
+
+ +
+
+ +
+ E-commerce & Website +
+

+ Mobile + friendly, + awe-inspiring product pages

+
+
+ +
+
+ +
+ Service Management +
+

+ Keep track of + services and invoice

+
+
+ +
+
+ +
+ Restaurant +
+

+ Run your bar or + restaurant methodically

+
+
+ +
+
+ +
+ Hotel Management +
+

+ An + all-inclusive + hotel management application

+
+
+
+
+ + + + +
+
+ +
+

+ Support +

+
+
+
+
+
+
+ +
+
+

Need Help?

+

Got questions or need help? + Get in touch.

+ +

+ odoo@cybrosys.com

+
+
+
+
+
+
+
+ +
+
+

WhatsApp

+

Say hi to us on WhatsApp!

+ +

+ +91 86068 + 27707

+
+
+
+
+
+
+
+ +
+
+
+ \ No newline at end of file diff --git a/bom_structure_in_excel_odoo/static/src/js/action_manager.js b/bom_structure_in_excel_odoo/static/src/js/action_manager.js new file mode 100644 index 000000000..2503b9eed --- /dev/null +++ b/bom_structure_in_excel_odoo/static/src/js/action_manager.js @@ -0,0 +1,23 @@ +/** @odoo-module */ +import { registry } from "@web/core/registry"; +import { download } from "@web/core/network/download"; +import framework from 'web.framework'; +import session from 'web.session'; +/** + * @override + * Add 'xlsx' report type to the report handler + */ +registry.category("ir.actions.report handlers").add("xlsx", async (action) => { + if (action.report_type === 'xlsx') { + framework.blockUI(); + var def = $.Deferred(); + session.get_file({ + url: '/xlsx_reports', + data: action.data, + success: def.resolve.bind(def), + error: (error) => this.call('crash_manager', 'rpc_error', error), + complete: framework.unblockUI, + }); + return def; + } +}); \ No newline at end of file