Skip to content

Commit

Permalink
[ADD] delivery_package_number_report: Add number_of_packages field in…
Browse files Browse the repository at this point in the history
… report
  • Loading branch information
unaiberis authored and anajuaristi committed Jan 21, 2025
1 parent 0c8a2f8 commit fea1f23
Show file tree
Hide file tree
Showing 8 changed files with 144 additions and 0 deletions.
68 changes: 68 additions & 0 deletions delivery_package_number_report/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
.. image:: https://img.shields.io/badge/license-LGPL--3-blue.svg
:target: https://opensource.org/licenses/LGPL-3.0
:alt: License: LGPL-3

========================================================
Delivery Package Number Report
========================================================

Overview
========

The **Delivery Package Number Report** module enhances the existing **Stock Report Delivery Document** view by adding a new field to display the number of packages in the report. This is useful for tracking and reporting the number of packages associated with delivery moves.

Features
========

- **Add Number of Packages**:
- Modifies the `stock.report_delivery_document` view to include a field showing the number of packages associated with a stock move line.

- **Integration with Delivery Package Number**:
- Leverages the **Delivery Package Number** module for the `number_of_packages` field.

Usage
=====

1. **Install the Module**:
- Install the **Delivery Package Number Report** module via the Apps menu.

2. **View the Report**:
- Navigate to the stock report view for delivery documents.
- The new `Number of Packages` field will be visible in the report.

3. **Use Case**:
- This module is particularly useful for organizations that need to track the number of packages involved in their stock moves, especially when dealing with deliveries.

Configuration
=============

No specific configuration is required for this module. It will automatically modify the `stock.report_delivery_document` view to include the new `number_of_packages` field.

Testing
=======

Test the following to ensure the module works as intended:

- Verify that the `number_of_packages` field appears correctly in the stock delivery document report.
- Ensure the field reflects the correct data from the **Delivery Package Number** module.

Bug Tracker
===========

If you encounter any issues, please report them on the GitHub repository at `GitHub Issues <https://github.com/avanzosc/odoo-addons/issues>`_.

Credits
=======

Contributors
------------

* Ana Juaristi <[email protected]>
* Unai Beristain <[email protected]>

For specific questions regarding this module, please contact the contributors. For support, please use the official issue tracker.

License
=======

This project is licensed under the LGPL-3 License. For more details, refer to the LICENSE file or visit <https://opensource.org/licenses/LGPL-3.0>.
Empty file.
14 changes: 14 additions & 0 deletions delivery_package_number_report/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"name": "Delivery Package Number Report",
"version": "16.0.1.0.0",
"category": "Stock",
"author": "Avanzosc",
"license": "LGPL-3",
"depends": ["stock", "delivery_package_number"],
"data": [
"views/delivery_package_number_report_view.xml",
],
"installable": True,
"application": False,
"website": "https://github.com/avanzosc/odoo-addons",
}
21 changes: 21 additions & 0 deletions delivery_package_number_report/i18n/ca_ES.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * delivery_package_number_report
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2025-01-20 16:36+0000\n"
"PO-Revision-Date: 2025-01-20 16:36+0000\n"
"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: \n"

#. module: delivery_package_number_report
#: model_terms:ir.ui.view,arch_db:delivery_package_number_report.delivery_package_number_report_inherit
msgid "Packages:"
msgstr "Paquets:"
21 changes: 21 additions & 0 deletions delivery_package_number_report/i18n/es.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * delivery_package_number_report
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2025-01-20 14:17+0000\n"
"PO-Revision-Date: 2025-01-20 14:17+0000\n"
"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: \n"

#. module: delivery_package_number_report
#: model_terms:ir.ui.view,arch_db:delivery_package_number_report.delivery_package_number_report_inherit
msgid "Packages:"
msgstr "Bultos:"
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="UTF-8" ?>
<odoo>
<template
id="delivery_package_number_report_inherit"
inherit_id="stock.report_delivery_document"
>
<xpath expr="//table[@name='stock_move_line_table']" position="after">
<div t-if="o.number_of_packages">
Packages: <span t-field="o.number_of_packages" />
</div>
</xpath>
</template>
</odoo>
6 changes: 6 additions & 0 deletions setup/delivery_package_number_report/setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import setuptools

setuptools.setup(
setup_requires=['setuptools-odoo'],
odoo_addon=True,
)

0 comments on commit fea1f23

Please sign in to comment.