-
Notifications
You must be signed in to change notification settings - Fork 74
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ADD] stock_report_delivery_document_lot_id: Add lot in all pickings
- Loading branch information
Showing
6 changed files
with
131 additions
and
0 deletions.
There are no files selected for viewing
1 change: 1 addition & 0 deletions
1
...p/stock_report_delivery_document_lot_id/odoo/addons/stock_report_delivery_document_lot_id
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../../../stock_report_delivery_document_lot_id |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
.. image:: https://img.shields.io/badge/license-LGPL--3-blue.svg | ||
:target: https://opensource.org/licenses/LGPL-3.0 | ||
:alt: License: LGPL-3 | ||
|
||
============================================================== | ||
Stock Report Delivery Document Lot ID | ||
============================================================== | ||
|
||
Overview | ||
======== | ||
|
||
The **Stock Report Delivery Document Lot ID** module enhances the **Delivery Document Report** by adding the ability to display lot or serial numbers for stock moves. This provides more detailed traceability for your delivery operations. | ||
|
||
Features | ||
======== | ||
|
||
- **Display Lot/Serial Numbers**: | ||
|
||
- Adds a new column to the **Delivery Document Report** to show the lot or serial number of stock moves. | ||
|
||
- **Barcode Support**: | ||
|
||
- Displays barcodes for the lot/serial numbers, improving operational efficiency. | ||
|
||
- **Dynamic Visibility**: | ||
|
||
- Automatically shows the column only when lot or serial numbers are present in the stock move lines. | ||
|
||
Usage | ||
===== | ||
|
||
1. **Install the Module**: | ||
|
||
- Install the **Stock Report Delivery Document Lot ID** module via the Apps menu. | ||
|
||
2. **Check Delivery Documents**: | ||
|
||
- Open any delivery document and verify the presence of the `Lot/Serial Number` column. | ||
|
||
3. **Barcodes for Lot/Serial Numbers**: | ||
|
||
- Confirm that barcodes for lot or serial numbers appear in the new column. | ||
|
||
Configuration | ||
============= | ||
|
||
No additional configuration is needed. The module works out of the box once installed. | ||
|
||
Testing | ||
======= | ||
|
||
Perform the following tests to ensure the module is working correctly: | ||
|
||
- Verify that the `Lot/Serial Number` column appears in the **Delivery Document Report** only when there are lot or serial numbers. | ||
|
||
- Confirm that the barcodes are correctly generated and displayed in the column. | ||
|
||
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 or support, please contact the contributors. | ||
|
||
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.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"name": "Stock Report Delivery Document Lot ID", | ||
"version": "16.0.1.0.0", | ||
"category": "Stock", | ||
"author": "Avanzosc", | ||
"license": "LGPL-3", | ||
"depends": ["stock"], | ||
"data": [ | ||
"views/stock_report_delivery_document_lot_id_view.xml", | ||
], | ||
"installable": True, | ||
"application": False, | ||
"website": "https://github.com/avanzosc/odoo-addons", | ||
} |
32 changes: 32 additions & 0 deletions
32
stock_report_delivery_document_lot_id/views/stock_report_delivery_document_lot_id_view.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
<?xml version="1.0" encoding="UTF-8" ?> | ||
<odoo> | ||
<template | ||
id="stock_report_delivery_document_lot_id_inherit" | ||
inherit_id="stock.report_delivery_document" | ||
> | ||
<xpath expr="//th[@name='th_sm_quantity']" position="after"> | ||
<th name="lot_serial" t-if="has_serial_number"> | ||
<strong>Lot/Serial Number</strong> | ||
</th> | ||
</xpath> | ||
|
||
<xpath expr="//table[@name='stock_move_table']" position="after"> | ||
<t | ||
t-set="has_serial_number" | ||
t-value="any(move_line.lot_id or move_line.lot_name for move_line in o.move_line_ids)" | ||
/> | ||
</xpath> | ||
|
||
<xpath expr="//table[@name='stock_move_table']/tbody/tr/td[3]" position="after"> | ||
<td t-if="has_serial_number"> | ||
<t t-foreach="move.move_line_ids" t-as="line"> | ||
<div | ||
t-if="line.lot_id or line.lot_name" | ||
t-esc="line.lot_id.name or line.lot_name" | ||
t-options="{'widget': 'barcode', 'humanreadable': 1, 'width': 400, 'height': 100, 'img_style': 'width:100%;height:35px;'}" | ||
/> | ||
</t> | ||
</td> | ||
</xpath> | ||
</template> | ||
</odoo> |